Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
88107acd
T
TDengine
项目概览
taosdata
/
TDengine
大约 1 年 前同步成功
通知
1184
Star
22015
Fork
4786
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
88107acd
编写于
5月 14, 2021
作者:
H
Huo Linhe
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[TD-4160]<fix>: remove python connector soft links, fix tests and documents
上级
98487594
变更
21
隐藏空白更改
内联
并排
Showing
21 changed file
with
26 addition
and
78 deletion
+26
-78
Jenkinsfile
Jenkinsfile
+1
-1
documentation20/cn/08.connector/docs.md
documentation20/cn/08.connector/docs.md
+6
-11
packaging/tools/makeclient_power.sh
packaging/tools/makeclient_power.sh
+3
-12
packaging/tools/makepkg_power.sh
packaging/tools/makepkg_power.sh
+3
-12
src/connector/python/linux/python2
src/connector/python/linux/python2
+0
-1
src/connector/python/linux/python3/taos/__init__.py~origin_master
...ector/python/linux/python3/taos/__init__.py~origin_master
+0
-25
src/connector/python/osx/python3
src/connector/python/osx/python3
+0
-1
src/connector/python/windows/python2
src/connector/python/windows/python2
+0
-1
src/connector/python/windows/python3
src/connector/python/windows/python3
+0
-1
tests/How-To-Run-Test-And-How-To-Add-New-Test-Case.md
tests/How-To-Run-Test-And-How-To-Add-New-Test-Case.md
+2
-2
tests/Jenkinsfile
tests/Jenkinsfile
+1
-1
tests/pytest/concurrent_inquiry.sh
tests/pytest/concurrent_inquiry.sh
+1
-1
tests/pytest/crash_gen.sh
tests/pytest/crash_gen.sh
+1
-1
tests/pytest/hivemq-extension-test.py
tests/pytest/hivemq-extension-test.py
+1
-1
tests/pytest/perf_gen.sh
tests/pytest/perf_gen.sh
+1
-1
tests/pytest/simpletest_no_sudo.sh
tests/pytest/simpletest_no_sudo.sh
+1
-1
tests/pytest/test.py
tests/pytest/test.py
+1
-1
tests/pytest/test.sh
tests/pytest/test.sh
+1
-1
tests/pytest/testCompress.py
tests/pytest/testCompress.py
+1
-1
tests/pytest/testMinTablesPerVnode.py
tests/pytest/testMinTablesPerVnode.py
+1
-1
tests/pytest/testNoCompress.py
tests/pytest/testNoCompress.py
+1
-1
未找到文件。
Jenkinsfile
浏览文件 @
88107acd
...
...
@@ -94,7 +94,7 @@ def pre_test(){
make > /dev/null
make install > /dev/null
cd ${WKC}/tests
pip3 install ${WKC}/src/connector/python
/linux/python3/
pip3 install ${WKC}/src/connector/python
'''
return
1
}
...
...
documentation20/cn/08.connector/docs.md
浏览文件 @
88107acd
...
...
@@ -400,27 +400,22 @@ Python连接器的使用参见[视频教程](https://www.taosdata.com/blog/2020/
#### Linux
用户可以在源代码的src/connector/python(或者tar.gz的/connector/python)文件夹下找到
python2和python3的
connector安装包。用户可以通过pip命令安装:
用户可以在源代码的src/connector/python(或者tar.gz的/connector/python)文件夹下找到connector安装包。用户可以通过pip命令安装:
`pip install src/connector/python/
linux/python2/
`
`pip install src/connector/python/`
或
`pip3 install src/connector/python/
linux/python3/
`
`pip3 install src/connector/python/`
#### Windows
在已安装Windows TDengine 客户端的情况下, 将文件"C:
\T
Dengine
\d
river
\t
aos.dll" 拷贝到 "C:
\w
indows
\s
ystem32" 目录下, 然后进入Windwos
<em>
cmd
</em>
命令行界面
```
cmd
cd C:\TDengine\connector\python\windows
python -m pip install python2\
```
或
```
cmd
cd C:\TDengine\connector\python\windows
python -m pip install python3\
cd C:\TDengine\connector\python
python -m pip install .
```
*
如果机器上没有pip命令,用户可将src/connector/python
/python3或src/connector/python/python2
下的taos文件夹拷贝到应用程序的目录使用。
*
如果机器上没有pip命令,用户可将src/connector/python下的taos文件夹拷贝到应用程序的目录使用。
对于windows 客户端,安装TDengine windows 客户端后,将C:
\T
Dengine
\d
river
\t
aos.dll拷贝到C:
\w
indows
\s
ystem32目录下即可。
### 使用
...
...
packaging/tools/makeclient_power.sh
浏览文件 @
88107acd
...
...
@@ -148,20 +148,11 @@ if [[ "$pagMode" != "lite" ]] && [[ "$cpuType" != "aarch32" ]]; then
cp
-r
${
connector_dir
}
/python
${
install_dir
}
/connector/
cp
-r
${
connector_dir
}
/go
${
install_dir
}
/connector
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python2/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python3/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python2/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python3/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python2/taos/subscription.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python3/taos/subscription.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python2/taos/subscription.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python3/taos/subscription.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/taos/subscription.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python2/taos/connection.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python3/taos/connection.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python2/taos/connection.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python3/taos/connection.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/taos/connection.py
fi
# Copy release note
# cp ${script_dir}/release_note ${install_dir}
...
...
packaging/tools/makepkg_power.sh
浏览文件 @
88107acd
...
...
@@ -170,20 +170,11 @@ if [[ "$pagMode" != "lite" ]] && [[ "$cpuType" != "aarch32" ]]; then
cp
-r
${
connector_dir
}
/python
${
install_dir
}
/connector/
cp
-r
${
connector_dir
}
/go
${
install_dir
}
/connector
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python2/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python3/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python2/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python3/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/taos/cinterface.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python2/taos/subscription.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python3/taos/subscription.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python2/taos/subscription.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python3/taos/subscription.py
sed
-i
'/password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/taos/subscription.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python2/taos/connection.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/linux/python3/taos/connection.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python2/taos/connection.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/windows/python3/taos/connection.py
sed
-i
'/self._password/ {s/taosdata/powerdb/g}'
${
install_dir
}
/connector/python/taos/connection.py
fi
# Copy release note
# cp ${script_dir}/release_note ${install_dir}
...
...
src/connector/python/linux/python2
已删除
120000 → 0
浏览文件 @
98487594
../
\ No newline at end of file
src/connector/python/linux/python3/taos/__init__.py~origin_master
已删除
100644 → 0
浏览文件 @
98487594
from .connection import TDengineConnection
from .cursor import TDengineCursor
from .error import Error
# Globals
threadsafety = 0
paramstyle = 'pyformat'
__all__ = ['connection', 'cursor']
def connect(*args, **kwargs):
""" Function to return a TDengine connector object
Current supporting keyword parameters:
@dsn: Data source name as string
@user: Username as string(optional)
@password: Password as string(optional)
@host: Hostname(optional)
@database: Database name(optional)
@rtype: TDengineConnector
"""
return TDengineConnection(*args, **kwargs)
src/connector/python/osx/python3
已删除
120000 → 0
浏览文件 @
98487594
../
\ No newline at end of file
src/connector/python/windows/python2
已删除
120000 → 0
浏览文件 @
98487594
../
\ No newline at end of file
src/connector/python/windows/python3
已删除
120000 → 0
浏览文件 @
98487594
../
\ No newline at end of file
tests/How-To-Run-Test-And-How-To-Add-New-Test-Case.md
浏览文件 @
88107acd
...
...
@@ -8,8 +8,8 @@
3.
mkdir debug; cd debug; cmake ..; make ; sudo make install
4.
pip install ../src/connector/python
/linux/python2
; pip3 install
../src/connector/python
/linux/python3
4.
pip install ../src/connector/python ; pip3 install
../src/connector/python
5.
pip install numpy; pip3 install numpy (numpy is required only if you need to run querySort.py)
...
...
tests/Jenkinsfile
浏览文件 @
88107acd
...
...
@@ -21,7 +21,7 @@ def pre_test(){
cmake .. > /dev/null
make > /dev/null
make install > /dev/null
pip3 install ${WKC}/src/connector/python
/linux/python3/
pip3 install ${WKC}/src/connector/python
'''
return
1
}
...
...
tests/pytest/concurrent_inquiry.sh
浏览文件 @
88107acd
...
...
@@ -48,7 +48,7 @@ fi
PYTHON_EXEC
=
python3.8
# First we need to set up a path for Python to find our own TAOS modules, so that "import" can work.
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python
/linux/python3
:
$(
pwd
)
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python:
$(
pwd
)
# Then let us set up the library path so that our compiled SO file can be loaded by Python
export
LD_LIBRARY_PATH
=
$LD_LIBRARY_PATH
:
$LIB_DIR
...
...
tests/pytest/crash_gen.sh
浏览文件 @
88107acd
...
...
@@ -48,7 +48,7 @@ fi
PYTHON_EXEC
=
python3.8
# First we need to set up a path for Python to find our own TAOS modules, so that "import" can work.
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python
/linux/python3
:
$(
pwd
)
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python:
$(
pwd
)
# Then let us set up the library path so that our compiled SO file can be loaded by Python
export
LD_LIBRARY_PATH
=
$LD_LIBRARY_PATH
:
$LIB_DIR
...
...
tests/pytest/hivemq-extension-test.py
浏览文件 @
88107acd
...
...
@@ -10,7 +10,7 @@
#
###################################################################
# install pip
# pip install src/connector/python/
linux/python2/
# pip install src/connector/python/
import
sys
import
os
import
os.path
...
...
tests/pytest/perf_gen.sh
浏览文件 @
88107acd
...
...
@@ -48,7 +48,7 @@ fi
PYTHON_EXEC
=
python3.8
# First we need to set up a path for Python to find our own TAOS modules, so that "import" can work.
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python
/linux/python3
:
$(
pwd
)
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python:
$(
pwd
)
# Then let us set up the library path so that our compiled SO file can be loaded by Python
export
LD_LIBRARY_PATH
=
$LD_LIBRARY_PATH
:
$LIB_DIR
...
...
tests/pytest/simpletest_no_sudo.sh
浏览文件 @
88107acd
...
...
@@ -4,7 +4,7 @@
# 2. No files are needed outside the development tree, everything is done in the local source code directory
# First we need to set up a path for Python to find our own TAOS modules, so that "import" can work.
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python
/linux/python3
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python
# Then let us set up the library path so that our compiled SO file can be loaded by Python
export
LD_LIBRARY_PATH
=
$LD_LIBRARY_PATH
:
$(
pwd
)
/../../build/build/lib
...
...
tests/pytest/test.py
浏览文件 @
88107acd
...
...
@@ -10,7 +10,7 @@
#
###################################################################
# install pip
# pip install src/connector/python/
linux/python2/
# pip install src/connector/python/
# -*- coding: utf-8 -*-
import
sys
...
...
tests/pytest/test.sh
浏览文件 @
88107acd
...
...
@@ -13,7 +13,7 @@ else
fi
TAOSD_DIR
=
`
find
$TAOS_DIR
-name
"taosd"
|grep bin|head
-n1
`
LIB_DIR
=
`
echo
$TAOSD_DIR
|rev|cut
-d
'/'
-f
3,4,5,6|rev
`
/lib
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python
/linux/python3
export
PYTHONPATH
=
$(
pwd
)
/../../src/connector/python
export
LD_LIBRARY_PATH
=
$LD_LIBRARY_PATH
:
$LIB_DIR
if
[[
"
$1
"
==
*
"test.py"
*
]]
;
then
...
...
tests/pytest/testCompress.py
浏览文件 @
88107acd
...
...
@@ -10,7 +10,7 @@
#
###################################################################
# install pip
# pip install src/connector/python/
linux/python2/
# pip install src/connector/python/
# -*- coding: utf-8 -*-
import
sys
...
...
tests/pytest/testMinTablesPerVnode.py
浏览文件 @
88107acd
...
...
@@ -10,7 +10,7 @@
#
###################################################################
# install pip
# pip install src/connector/python/
linux/python2/
# pip install src/connector/python/
# -*- coding: utf-8 -*-
import
sys
...
...
tests/pytest/testNoCompress.py
浏览文件 @
88107acd
...
...
@@ -10,7 +10,7 @@
#
###################################################################
# install pip
# pip install src/connector/python/
linux/python2/
# pip install src/connector/python/
# -*- coding: utf-8 -*-
import
sys
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录