Skip to content

feat(ws): support DECIMAL data type (#388) #97

feat(ws): support DECIMAL data type (#388)

feat(ws): support DECIMAL data type (#388) #97

name: Build Enterprise
on:
push:
branches:
- "main"
- "3.0"
pull_request:
branches:
- "main"
- "3.0"
jobs:
test:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
run: sudo apt-get install -y python3 python3-pip python-is-python3
- name: Cache Poetry
id: cache-poetry
uses: actions/cache@v4
with:
path: ~/.poetry
key: ubuntu-22.04-poetry
- name: Install Poetry
uses: snok/install-poetry@v1
with:
version: 1.8.5
virtualenvs-create: true
virtualenvs-in-project: true
installer-parallel: true
- name: Load cached venv
id: cached-poetry-dependencies
uses: actions/cache@v4
with:
path: .venv
key: venv-${{ runner.os }}-${{ hashFiles('**/poetry.lock') }}
- name: Install dependencies
if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
run: |
poetry install --no-interaction --no-root
poetry run pip install "numpy<2.0.0"
- name: Install library
run: |
poetry install --no-interaction --with=test
poetry run pip install "numpy<2.0.0"
- name: Get TDengine
run: wget "${{ secrets.NIGHTLY_TDENGINE_ENTERPRISE_BASE_URL }}/tsdb-nightly-3.0.tar.gz?v=$(date +%s)" -O tsdb-nightly-3.0.tar.gz
- name: Install TDengine
run: |
tar -zxf tsdb-nightly-3.0.tar.gz
rm -rf tsdb-nightly-3.0.tar.gz
cd tsdb-nightly-3.0
sudo ./install.sh
- name: Copy taos.cfg
run: |
sudo mkdir -p /etc/taos
sudo cp ./.github/workflows/taos.cfg /etc/taos/taos.cfg
- name: Start TDengine
run: |
sudo mkdir -p /var/log/taos
taosd &
taosadapter &
- name: Run Tests
env:
TDENGINE_URL: localhost:6041
TDENGINE_TEST_USERNAME: ${{ secrets.TDENGINE_TEST_USERNAME }}
TDENGINE_TEST_PASSWORD: ${{ secrets.TDENGINE_TEST_PASSWORD }}
TEST_TD_ENTERPRISE: "true"
run: poetry run pytest --cov-report term --cov-report html --cov-report xml --cov=taos --cov=taosrest --cov-append tests
- name: Upload taosd logs
if: failure()
uses: actions/upload-artifact@v4
with:
name: log-v3-taosd
path: /tmp/taos/v3/log/
retention-days: 1
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
files: ./coverage.xml
token: ${{ secrets.CODECOV_TOKEN }}
- name: Build Artifacts
run: poetry build