Skip to content

Commit

Permalink
Support python3.13, Update workflow (#55)
Browse files Browse the repository at this point in the history
  • Loading branch information
Yibo-Chen13 authored Oct 24, 2024
1 parent 8aad2aa commit f8cd537
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 22 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,19 +30,19 @@ jobs:
Write-Output $VERSION
Write-Output "tag_name=$VERSION" >> $env:GITHUB_OUTPUT
- name: Set up QEMU
uses: docker/setup-qemu-action@v1.2.0
uses: docker/setup-qemu-action@v3
if: ${{ startsWith( matrix.os, 'ubuntu' ) }}
with:
image: tonistiigi/binfmt:latest
platforms: all
- name: Build wheels
uses: pypa/cibuildwheel@v2.16.2
uses: pypa/cibuildwheel@v2.21.3
with:
package-dir: .
output-dir: wheelhouse
config-file: pyproject.toml
- name: Release wheels
uses: softprops/action-gh-release@v1
uses: softprops/action-gh-release@v2
with:
files: wheelhouse/*.whl
generate_release_notes: true
Expand Down
11 changes: 1 addition & 10 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,18 @@ jobs:
matrix:
use-numpy:
- 0
- 1
python-version:
# - "3.5" ,In this old version, example have a syntax error:E999
- "3.6"
- "3.7"
- "3.8"
- "3.9"
- "3.10"
- "3.11"
- "3.12"
- "3.13"
- "pypy-3.6"
- "pypy-3.7"
- "pypy-3.8"
- "pypy-3.9"
- "pypy-3.10"
proton-version:
- "latest"
include:
- proton-version: "latest"
python-version: "3.8"
use-numpy: 1

name: ${{ matrix.python-version }} PROTON=${{ matrix.proton-version }} NUMPY=${{ matrix.use-numpy }}
steps:
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ This project provides python driver to interact with Timeplus Proton or Timeplus

Installation
------------
Timeplus Python Driver currently supports the following versions of Python: 3.8, 3.9, 3.10, 3.11 and 3.12.
Timeplus Python Driver currently supports the following versions of Python: 3.8, 3.9, 3.10, 3.11, 3.12 and 3.13.

Installing with pip
We recommend creating a virtual environment when installing Python dependencies. For more information on setting up a virtual environment, see the `Python documentation <https://docs.python.org/3.9/tutorial/venv.html>`_.
Expand Down
2 changes: 1 addition & 1 deletion example/descriptive_pipeline/server/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@


class Pipeline(BaseModel):
name: str
name: str # noqa
sqls: list[str] # noqa


Expand Down
2 changes: 1 addition & 1 deletion proton_driver/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from .dbapi import connect


VERSION = (0, 2, 10)
VERSION = (0, 2, 11)
__version__ = '.'.join(str(x) for x in VERSION)

__all__ = ['Client', 'connect']
8 changes: 4 additions & 4 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,12 +95,12 @@ def read_version():

'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 :: 3.11',
'Programming Language :: Python :: 3.12',
'Programming Language :: Python :: 3.13',
'Programming Language :: Python :: Implementation :: PyPy',

'Topic :: Database',
Expand All @@ -114,7 +114,7 @@ def read_version():
keywords='Proton db database cloud analytics',

packages=find_packages('.', exclude=['tests*']),
python_requires='>=3.4, <4',
python_requires='>=3.8, <4',
install_requires=[
'pytz',
'tzlocal',
Expand Down
4 changes: 2 additions & 2 deletions tests/test_query_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,12 @@ def test_last_query_after_execute_with_progress(self):
self.assertEqual(last_query.elapsed, 0)

def test_last_query_progress_total_rows(self):
self.client.execute('SELECT max(number) FROM numbers(10) LIMIT 10')
self.client.execute('SELECT number FROM numbers(10) LIMIT 10')

last_query = self.client.last_query
self.assertIsNotNone(last_query)
self.assertIsNotNone(last_query.profile_info)
self.assertEqual(last_query.profile_info.rows_before_limit, 1)
self.assertEqual(last_query.profile_info.rows_before_limit, 10)

self.assertIsNotNone(last_query.progress)
self.assertEqual(last_query.progress.rows, 10)
Expand Down

0 comments on commit f8cd537

Please sign in to comment.