Skip to content

Commit

Permalink
feat: merge databend driver
Browse files Browse the repository at this point in the history
  • Loading branch information
everpcpc committed Nov 22, 2023
1 parent 7960ae2 commit b160103
Show file tree
Hide file tree
Showing 3 changed files with 66 additions and 49 deletions.
1 change: 0 additions & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,3 @@ jobs:
echo "show user name:"
echo ${{ secrets.TWINE_USERNAME }}
twine upload -u ${{ secrets.TWINE_USERNAME }} -p ${{ secrets.TWINE_PASSWORD }} dist/*
29 changes: 28 additions & 1 deletion databend_py/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,31 @@
from .connection import Connection
from .datetypes import DatabendDataType

__all__ = ['Client', 'Connection', 'DatabendDataType']
from databend_driver import (
AsyncDatabendClient,
AsyncDatabendConnection,
BlockingDatabendClient,
BlockingDatabendConnection,
Row,
RowIterator,
Field,
Schema,
ServerStats,
ConnectionInfo,
)

__all__ = [
"Client",
"Connection",
"DatabendDataType",
"AsyncDatabendClient",
"AsyncDatabendConnection",
"BlockingDatabendClient",
"BlockingDatabendConnection",
"Row",
"RowIterator",
"Field",
"Schema",
"ServerStats",
"ConnectionInfo",
]
85 changes: 38 additions & 47 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,67 +7,58 @@


def read_version():
version_py = os.path.join(here, 'databend_py', 'VERSION')
with open(version_py, encoding='utf-8') as f:
version_py = os.path.join(here, "databend_py", "VERSION")
with open(version_py, encoding="utf-8") as f:
first_line = f.readline()
return first_line.strip()


github_url = 'https://github.com/databendcloud/databend-py'
github_url = "https://github.com/databendcloud/databend-py"

with open(os.path.join(here, 'README.md'), encoding='utf-8') as f:
with open(os.path.join(here, "README.md"), encoding="utf-8") as f:
long_description = f.read()

setup(
name='databend-py',
name="databend-py",
version=read_version(),
include_package_data=True,

description='Python driver with native interface for Databend',
description="Python driver with native interface for Databend",
long_description=long_description,

url=github_url,
packages=find_packages('.', exclude=['tests*']),
python_requires='>=3.4, <4',
packages=find_packages(".", exclude=["tests*"]),
python_requires=">=3.4, <4",
install_requires=[
'pytz',
'mysql.connector',
'environs',
'requests',
"pytz",
"mysql.connector",
"environs",
"requests",
"databend-driver",
],

author='Databend Cloud Team',
author_email='[email protected]',

license='Apache License',
author="Databend Cloud Team",
author_email="[email protected]",
license="Apache License",
classifiers=[
'Development Status :: 4 - Beta',

'Environment :: Console',

'Intended Audience :: Developers',
'Intended Audience :: Information Technology',

'Operating System :: OS Independent',

'Programming Language :: SQL',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: Implementation :: PyPy',

'Topic :: Database',
'Topic :: Software Development',
'Topic :: Software Development :: Libraries',
'Topic :: Software Development :: Libraries :: Application Frameworks',
'Topic :: Software Development :: Libraries :: Python Modules',
'Topic :: Scientific/Engineering :: Information Analysis'
"Development Status :: 4 - Beta",
"Environment :: Console",
"Intended Audience :: Developers",
"Intended Audience :: Information Technology",
"Operating System :: OS Independent",
"Programming Language :: SQL",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: Implementation :: PyPy",
"Topic :: Database",
"Topic :: Software Development",
"Topic :: Software Development :: Libraries",
"Topic :: Software Development :: Libraries :: Application Frameworks",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Scientific/Engineering :: Information Analysis",
],

keywords='databend db database cloud analytics',
test_suite='pytest'
keywords="databend db database cloud analytics",
test_suite="pytest",
)

0 comments on commit b160103

Please sign in to comment.