From d32c055ce94d41249ce23432b84d573a7096db47 Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 13:27:24 +0700 Subject: [PATCH 01/12] wip --- .circleci/config.yml | 144 +++---------------------------------------- 1 file changed, 8 insertions(+), 136 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 02b286f..1590f15 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -32,144 +32,16 @@ commands: - "/usr/local/lib/site-python" when: always jobs: - tests-python: - parameters: - python-image: - type: string - default: &default-python "cimg/python:3.8" - pytest-marker: - type: string - default: "not integration" - docker: - - image: << parameters.python-image >> - environment: - PIPENV_VENV_IN_PROJECT: true - - image: influxdb:3-core - environment: - - INFLUXDB3_NODE_IDENTIFIER_PREFIX=node01 - - INFLUXDB3_OBJECT_STORE=file - - INFLUXDB3_DB_DIR=/var/lib/influxdb3/data - steps: - - checkout - - run: - name: Setup InfluxDB service - command: | - ./scripts/influxdb-setup.sh \ - --export-url-as TESTING_INFLUXDB_URL \ - --export-db-as TESTING_INFLUXDB_DATABASE \ - --export-token-as TESTING_INFLUXDB_TOKEN - - client-test: - python-image: << parameters.python-image >> - pytest-marker: << parameters.pytest-marker >> - - store_test_results: - path: test-reports - - run: - name: Collecting coverage reports - command: | - curl -Os https://uploader.codecov.io/latest/linux/codecov - curl -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM - curl -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM.sig - curl -s https://keybase.io/codecovsecurity/pgp_keys.asc | gpg --no-default-keyring --keyring trustedkeys.gpg --import - gpgv codecov.SHA256SUM.sig codecov.SHA256SUM - shasum -a 256 -c codecov.SHA256SUM - chmod +x ./codecov - ./codecov - check-code-style: - docker: - - image: *default-python - environment: - PIPENV_VENV_IN_PROJECT: true + tests-vm: + machine: + image: ubuntu-2404:2024.11.1 + resource_class: arm.medium steps: - - checkout - - run: - name: Checks style consistency of setup.py. - command: | - pip install flake8 --user - flake8 setup.py - - run: - name: Checks style consistency across sources. - command: | - pip install flake8 --user - flake8 influxdb_client_3/ - - run: - name: Checks style consistency across tests. - command: | - pip install flake8 --user - flake8 tests/ - - run: - name: Checks style consistency across examples. - command: | - pip install flake8 --user - flake8 Examples/ - check-twine: - docker: - - image: *default-python - environment: - PIPENV_VENV_IN_PROJECT: true - steps: - - checkout - - run: - name: Checks that the description will render correctly on PyPI. - command: | - pip install --upgrade pip - pip install 'twine>=5.1,<6.1' --user - python setup.py sdist bdist_wheel - twine check dist/* - check-docstyle: - docker: - - image: *default-python - environment: - PIPENV_VENV_IN_PROJECT: true - steps: - - checkout - - run: - name: Checks compliance with Python docstring convention. - command: | - pip install pydocstyle --user - pydocstyle --count influxdb_client_3 - + - run: "apt update" + - run: "apt -y upgrade" + - run: "python3 -v" workflows: version: 2 build: - when: - not: - equal: [ scheduled_pipeline, << pipeline.trigger_source >> ] - jobs: - - check-code-style -# - check-docstyle - - check-twine - - tests-python: - name: test-3.8 - python-image: "cimg/python:3.8" - - tests-python: - name: test-3.9 - python-image: "cimg/python:3.9" - - tests-python: - name: test-3.10 - python-image: "cimg/python:3.10" - - tests-python: - name: test-3.11 - python-image: "cimg/python:3.11" - - tests-python: - name: test-3.12 - python-image: "cimg/python:3.12" - - tests-python: - name: test-3.13 - python-image: "cimg/python:3.13" - - tests-python: - requires: - - test-3.8 - - test-3.9 - - test-3.10 - - test-3.11 - - test-3.12 - - test-3.13 - name: test-integration - python-image: *default-python - pytest-marker: "integration" - - nightly: - when: - equal: [ scheduled_pipeline, << pipeline.trigger_source >> ] jobs: - - tests-python + - tests-vm From d233786c9630f28841705c62bd24633ca15467ba Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 13:28:36 +0700 Subject: [PATCH 02/12] wip --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 1590f15..be37ef4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -37,8 +37,8 @@ jobs: image: ubuntu-2404:2024.11.1 resource_class: arm.medium steps: - - run: "apt update" - - run: "apt -y upgrade" + - run: "sudo apt update" + - run: "sudo apt -y upgrade" - run: "python3 -v" workflows: version: 2 From 379e434b316489efb7f311f0ea019759a83e137b Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 13:46:15 +0700 Subject: [PATCH 03/12] wip --- .circleci/config.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index be37ef4..6fa9ea7 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -38,8 +38,11 @@ jobs: resource_class: arm.medium steps: - run: "sudo apt update" - - run: "sudo apt -y upgrade" +# - run: "sudo apt -y upgrade" - run: "python3 -v" + - run: "sudo apt install -y python3-pip" + - run: "sudo apt install python3-venv -y" + - run: "sudo python3 -m venv home/my_env" workflows: version: 2 build: From d2238d5da5e69d302d5f20a475c6523e7390dbe2 Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 14:00:27 +0700 Subject: [PATCH 04/12] wip --- .circleci/config.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 6fa9ea7..84cc581 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -39,7 +39,8 @@ jobs: steps: - run: "sudo apt update" # - run: "sudo apt -y upgrade" - - run: "python3 -v" +# - run: "python3 -v" + - run: "sudo apt install python3 -y" - run: "sudo apt install -y python3-pip" - run: "sudo apt install python3-venv -y" - run: "sudo python3 -m venv home/my_env" From a64a2f9ad1e033d0cc3c4a3d4abe2a91b3dae628 Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 14:08:40 +0700 Subject: [PATCH 05/12] wip --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 84cc581..6f5fce9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -43,7 +43,7 @@ jobs: - run: "sudo apt install python3 -y" - run: "sudo apt install -y python3-pip" - run: "sudo apt install python3-venv -y" - - run: "sudo python3 -m venv home/my_env" + - run: "sudo python3 -m venv home/my_env && source home/my_env/bin/activate && sudo pip3 install influxdb3-client" workflows: version: 2 build: From 268c7b5690994b613c6bf4ed0f10146a11c25ea0 Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 14:18:47 +0700 Subject: [PATCH 06/12] wip --- .circleci/config.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 6f5fce9..9f9520f 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -43,7 +43,15 @@ jobs: - run: "sudo apt install python3 -y" - run: "sudo apt install -y python3-pip" - run: "sudo apt install python3-venv -y" - - run: "sudo python3 -m venv home/my_env && source home/my_env/bin/activate && sudo pip3 install influxdb3-client" + - run: "sudo python3 -m venv home/my_env" + - run: + name: "Running tests" + command: | + cd home/my_env + source bin/activate + pip3 install influxdb3-python + python3 + from influxdb_client_3 import InfluxDBClient3 workflows: version: 2 build: From eb4b58b7d2676a66a995b43919d419443a56b154 Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 14:24:47 +0700 Subject: [PATCH 07/12] wip --- .circleci/config.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 9f9520f..3458f79 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -48,9 +48,9 @@ jobs: name: "Running tests" command: | cd home/my_env - source bin/activate - pip3 install influxdb3-python - python3 + sudo source bin/activate + sudo pip3 install influxdb3-python + sudo python3 from influxdb_client_3 import InfluxDBClient3 workflows: version: 2 From d60a2ae863cd8503b7946c63b6d51bb6018f6634 Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 14:38:48 +0700 Subject: [PATCH 08/12] wip --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 3458f79..71a5a3d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -48,7 +48,7 @@ jobs: name: "Running tests" command: | cd home/my_env - sudo source bin/activate + source bin/activate sudo pip3 install influxdb3-python sudo python3 from influxdb_client_3 import InfluxDBClient3 From 611795f9c19c536b7a122a6794bbae9de17f78dd Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 14:49:15 +0700 Subject: [PATCH 09/12] wip --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 71a5a3d..9f9520f 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -49,8 +49,8 @@ jobs: command: | cd home/my_env source bin/activate - sudo pip3 install influxdb3-python - sudo python3 + pip3 install influxdb3-python + python3 from influxdb_client_3 import InfluxDBClient3 workflows: version: 2 From 3f17de354ebd15c45ac2b491a8a66e0883148f63 Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 14:52:56 +0700 Subject: [PATCH 10/12] wip --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 9f9520f..c8f44a0 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -49,7 +49,7 @@ jobs: command: | cd home/my_env source bin/activate - pip3 install influxdb3-python + sudo pip3 install influxdb3-python python3 from influxdb_client_3 import InfluxDBClient3 workflows: From a2ed1b3c47422027cb463f84f2e57172ae63d78e Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 15:09:15 +0700 Subject: [PATCH 11/12] wip --- .circleci/config.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c8f44a0..012ceba 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -47,8 +47,7 @@ jobs: - run: name: "Running tests" command: | - cd home/my_env - source bin/activate + source home/my_env/bin/activate sudo pip3 install influxdb3-python python3 from influxdb_client_3 import InfluxDBClient3 From 40dd2730aeb39908fe0270948b8bdf3f5dea3977 Mon Sep 17 00:00:00 2001 From: NguyenHoangSon96 Date: Tue, 12 Aug 2025 15:21:06 +0700 Subject: [PATCH 12/12] wip --- .circleci/config.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 012ceba..cf83752 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -44,11 +44,12 @@ jobs: - run: "sudo apt install -y python3-pip" - run: "sudo apt install python3-venv -y" - run: "sudo python3 -m venv home/my_env" + - run: "sudo chmod -R a+rwx home/my_env" - run: name: "Running tests" command: | source home/my_env/bin/activate - sudo pip3 install influxdb3-python + pip3 install influxdb3-python python3 from influxdb_client_3 import InfluxDBClient3 workflows: