Skip to main content

The official TDengine Python WebSocket connector

Project description

The official TDengine Python websocket connector

GitHub Actions Workflow Status codecov GitHub commit activity PyPI GitHub License PyPI
Twitter Follow YouTube Channel Discord Community LinkedIn StackOverflow

Table of Contents

1. Introduction

taospy is the official Python Connector for TDengine, allowing Python developers to develop applications that access the TDengine database. It supports functions such as data writing, querying, subscription, schemaless writing, and parameter binding.

The API for taospy is compliant with the Python DB API 2.0 (PEP-249). It contains two modules:

  1. The taos module. It uses TDengine C client library for client server communications.
  2. The taosrest module. It wraps TDengine RESTful API to Python DB API 2.0 (PEP-249). With this module, you do not need to install the TDengine C client library.

2. Documentation

  • To use Python Connector, please check Developer Guide, which includes how an application can introduce the Python Connector , as well as examples of data writing, querying, schemaless writing, parameter binding, and data subscription.
  • For other reference information, please check Reference Manual, which includes version history, data types, example programs, API descriptions, and FAQs.
  • This quick guide is mainly for developers who like to contribute/build/test the Python Connector by themselves. To learn about TDengine, you can visit the official documentation.

3. Prerequisites

  • Python runtime environment (taospy: Python >= 3.6.2, taos-ws-py: Python >= 3.7)
  • TDengine has been deployed locally. For specific steps, please refer to Deploy TDengine, and taosd and taosAdapter have been started.

4. Build

Download the repository code and execute the following in root directory to build develop environment:

maturin build

5. Testing

5.1 Test Execution

The Python Connector testing framework is pytest.

The testing directory for taos-ws-py is located in the root directory: taos-ws-py/tests/ .

The test code has been written into one bash file. You can open and view the detailed testing process.

The following command runs all test cases on Linux platform:

# for taos-ws-py
bash ./test_taos-ws-py.sh

5.2 Test Case Addition

You can add new test files or add test cases in existing test files that comply with pytest standards

5.3 Performance Testing

Performance testing is in progress.

6. CI/CD

7. Submitting Issues

We welcome the submission of GitHub Issue. When submitting, please provide the following information:

  • Problem description, whether it always occurs, and it's best to include a detailed call stack.
  • Python Connector version.
  • Python Connection parameters (username and password not required).
  • TDengine server version.

8. Submitting PRs

We welcome developers to contribute to this project. When submitting PRs, please follow these steps:

  1. Fork this project, refer to (how to fork a repo).
  2. Create a new branch from the main branch with a meaningful branch name (git checkout -b my_branch). Do not modify the main branch directly.
  3. Modify the code, ensure all unit tests pass, and add new unit tests to verify the changes.
  4. Push the changes to the remote branch (git push origin my_branch).
  5. Create a Pull Request on GitHub (how to create a pull request).
  6. After submitting the PR, you can find your PR through the Pull Request. Click on the corresponding link to see if the CI for your PR has passed. If it has passed, it will display "All checks have passed". Regardless of whether the CI passes or not, you can click "Show all checks" -> "Details" to view the detailed test case logs.
  7. After submitting the PR, if CI passes, you can find your PR on the codecov page to check the test coverage.

9. References

10. License

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

taos_ws_py-0.6.9-cp37-abi3-win_amd64.whl (4.8 MB view details)

Uploaded CPython 3.7+Windows x86-64

taos_ws_py-0.6.9-cp37-abi3-manylinux_2_31_riscv64.whl (4.2 MB view details)

Uploaded CPython 3.7+manylinux: glibc 2.31+ riscv64

taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.5 MB view details)

Uploaded CPython 3.7+manylinux: glibc 2.17+ x86-64

taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (4.0 MB view details)

Uploaded CPython 3.7+manylinux: glibc 2.17+ ARMv7l

taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (4.3 MB view details)

Uploaded CPython 3.7+manylinux: glibc 2.17+ ARM64

taos_ws_py-0.6.9-cp37-abi3-macosx_10_12_x86_64.whl (4.1 MB view details)

Uploaded CPython 3.7+macOS 10.12+ x86-64

taos_ws_py-0.6.9-cp37-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl (8.1 MB view details)

Uploaded CPython 3.7+macOS 10.12+ universal2 (ARM64, x86-64)macOS 10.12+ x86-64macOS 11.0+ ARM64

File details

Details for the file taos_ws_py-0.6.9-cp37-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for taos_ws_py-0.6.9-cp37-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 8e020f7d8ba3b8c4c623d5189f63f9223b7a54f10fb8cba756defaec842e52b7
MD5 0572e5e6e395b194d291bf7261d90fe0
BLAKE2b-256 6af63a5ee3384636ca7ad303d774c725781073fcfd43728efa95299662907cf2

See more details on using hashes here.

File details

Details for the file taos_ws_py-0.6.9-cp37-abi3-manylinux_2_31_riscv64.whl.

File metadata

File hashes

Hashes for taos_ws_py-0.6.9-cp37-abi3-manylinux_2_31_riscv64.whl
Algorithm Hash digest
SHA256 68e85c16833691094555bc5dfea31743e11e3210a385767a3f11237c97b5fe63
MD5 ed725de0ee572297c87ecd676d204a43
BLAKE2b-256 4edb6212a878abc76bf8ecbda85d9030fa7fae0a16e7774c4692c8bb01dd3b1d

See more details on using hashes here.

File details

Details for the file taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 992e8fc0256b88e4f01a11dd52f9c9f9d4fd916f9bf9ebad2db59d610ed0312d
MD5 42f41c204fb3ab7a18aee3acfe65cd58
BLAKE2b-256 2d245d70ee3ddc84e0081111fe59b91bef62c948d1939919b2f5fbbfeb51f658

See more details on using hashes here.

File details

Details for the file taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 614dc810a21b9eda4b3d37a960ce900b0c97fd7e9b7fa8e549dccca21ea5e35e
MD5 553bfed00b1308b98d99ee701ac981f8
BLAKE2b-256 211180273b8eb0845a1992b923b645706fa2a674cfe1914a20756645f5b89c12

See more details on using hashes here.

File details

Details for the file taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for taos_ws_py-0.6.9-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 244ebb055dc22900fe93ef8bc9f0985dc2bbd33e8aae9eb7f827e2de133496d6
MD5 40f830d85383740008112c681f509632
BLAKE2b-256 b8fb0b8738f6818721769469848f6548d0f727d6fe7ef361ab534230eef09f81

See more details on using hashes here.

File details

Details for the file taos_ws_py-0.6.9-cp37-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for taos_ws_py-0.6.9-cp37-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 1d700a5fc9a60efead6a23f2685cd651539c51864195bc3f8b441ce94ff4cb52
MD5 d22bf546eaba412cc8eaeec67afbe494
BLAKE2b-256 f195c68cdca3cd31197c9fd2dafb5330ead18ddabdb42c38228cf2bef70e2cd1

See more details on using hashes here.

File details

Details for the file taos_ws_py-0.6.9-cp37-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl.

File metadata

File hashes

Hashes for taos_ws_py-0.6.9-cp37-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Algorithm Hash digest
SHA256 8b91c5f3b01aa68d841ea0d42afa6c9c9b1260505fe80a0070fbfad8578a0455
MD5 5d0f25bd5d396d8f662dc79c4c460e50
BLAKE2b-256 9bfe56cbd1ca6951e82adfc4e3acec62b92a4c7ed38bd8b4f510b89ac49860b3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page