Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SQLAlchemy versions supported (2.0?) #340

Open
MicaelJarniac opened this issue Oct 3, 2024 · 2 comments
Open

SQLAlchemy versions supported (2.0?) #340

MicaelJarniac opened this issue Oct 3, 2024 · 2 comments

Comments

@MicaelJarniac
Copy link

On the docs, it says:

Release 0.3.2.

Supported SQLAlchemy: 1.4.

Release |release|.
Supported SQLAlchemy: 1.4.

On the dependencies, however:

'sqlalchemy>=2.0.0,<2.1.0',

'sqlalchemy>=2.0.0,<2.1.0',

This confused me.

Which versions of SQLAlchemy are actually supported? Are the docs outdated?

@Kolliderrr
Copy link

Kolliderrr commented Oct 15, 2024

@MicaelJarniac, my guess the only way to install this - build from the source. Just before build - rewrite

    'sqlalchemy>=2.0.0,<2.1.0',

to

     'sqlalchemy>=1.4.24,<1.5',

as it was in version 0.2.6 in line 99 in setup.py

UPD:
Just tried to install from source, seems ok:

└─Δ git clone https://github.com/xzkostyan/clickhouse-sqlalchemy.git
Cloning into 'clickhouse-sqlalchemy'...
remote: Enumerating objects: 3446, done.
remote: Counting objects: 100% (1030/1030), done.
remote: Compressing objects: 100% (346/346), done.
remote: Total 3446 (delta 827), reused 761 (delta 684), pack-reused 2416 (from 1)
Receiving objects: 100% (3446/3446), 653.95 KiB | 2.08 MiB/s, done.
Resolving deltas: 100% (2425/2425), done.
─Δ cd clickhouse-sqlalchemy
└─Δ pip install . --force-reinstall
Processing /home/valievar/click/clickhouse_git/clickhouse-sqlalchemy
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Collecting sqlalchemy<1.5,>=1.4.24 (from clickhouse-sqlalchemy==0.3.2)
  Using cached SQLAlchemy-1.4.54-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (10 kB)
Collecting requests (from clickhouse-sqlalchemy==0.3.2)
  Using cached requests-2.32.3-py3-none-any.whl.metadata (4.6 kB)
Collecting clickhouse-driver>=0.1.2 (from clickhouse-sqlalchemy==0.3.2)
  Using cached clickhouse_driver-0.2.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (6.1 kB)
Collecting asynch>=0.2.2 (from clickhouse-sqlalchemy==0.3.2)
  Using cached asynch-0.2.4-py3-none-any.whl.metadata (5.5 kB)
Collecting ciso8601 (from asynch>=0.2.2->clickhouse-sqlalchemy==0.3.2)
  Using cached ciso8601-2.3.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (25 kB)
Collecting leb128 (from asynch>=0.2.2->clickhouse-sqlalchemy==0.3.2)
  Using cached leb128-1.0.8-py3-none-any.whl.metadata (2.5 kB)
Collecting lz4 (from asynch>=0.2.2->clickhouse-sqlalchemy==0.3.2)
  Using cached lz4-4.3.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (3.7 kB)
Collecting pytz (from asynch>=0.2.2->clickhouse-sqlalchemy==0.3.2)
  Using cached pytz-2024.2-py2.py3-none-any.whl.metadata (22 kB)
Collecting tzlocal (from asynch>=0.2.2->clickhouse-sqlalchemy==0.3.2)
  Using cached tzlocal-5.2-py3-none-any.whl.metadata (7.8 kB)
Collecting zstd (from asynch>=0.2.2->clickhouse-sqlalchemy==0.3.2)
  Using cached zstd-1.5.5.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (8.9 kB)
Collecting greenlet!=0.4.17 (from sqlalchemy<1.5,>=1.4.24->clickhouse-sqlalchemy==0.3.2)
  Using cached greenlet-3.1.1-cp310-cp310-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl.metadata (3.8 kB)
Collecting charset-normalizer<4,>=2 (from requests->clickhouse-sqlalchemy==0.3.2)
  Using cached charset_normalizer-3.4.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (34 kB)
Collecting idna<4,>=2.5 (from requests->clickhouse-sqlalchemy==0.3.2)
  Using cached idna-3.10-py3-none-any.whl.metadata (10 kB)
Collecting urllib3<3,>=1.21.1 (from requests->clickhouse-sqlalchemy==0.3.2)
  Using cached urllib3-2.2.3-py3-none-any.whl.metadata (6.5 kB)
Collecting certifi>=2017.4.17 (from requests->clickhouse-sqlalchemy==0.3.2)
  Using cached certifi-2024.8.30-py3-none-any.whl.metadata (2.2 kB)
Using cached asynch-0.2.4-py3-none-any.whl (73 kB)
Using cached clickhouse_driver-0.2.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (935 kB)
Using cached SQLAlchemy-1.4.54-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.6 MB)
Using cached requests-2.32.3-py3-none-any.whl (64 kB)
Using cached certifi-2024.8.30-py3-none-any.whl (167 kB)
Using cached charset_normalizer-3.4.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (144 kB)
Using cached greenlet-3.1.1-cp310-cp310-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl (599 kB)
Using cached idna-3.10-py3-none-any.whl (70 kB)
Using cached urllib3-2.2.3-py3-none-any.whl (126 kB)
Using cached ciso8601-2.3.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (38 kB)
Using cached leb128-1.0.8-py3-none-any.whl (3.8 kB)
Using cached lz4-4.3.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB)
Using cached pytz-2024.2-py2.py3-none-any.whl (508 kB)
Using cached tzlocal-5.2-py3-none-any.whl (17 kB)
Using cached zstd-1.5.5.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.8 MB)
Building wheels for collected packages: clickhouse-sqlalchemy
  Building wheel for clickhouse-sqlalchemy (pyproject.toml) ... done
  Created wheel for clickhouse-sqlalchemy: filename=clickhouse_sqlalchemy-0.3.2-py3-none-any.whl size=53867 sha256=44c18d49000ee7c354becc305b04f4043c910053c6ac8252897a61d505dcedc1
  Stored in directory: /home/valievar/.cache/pip/wheels/85/62/b9/5cc665a18ffa38b73b3cfe196830f5ff62532450dc9fe5c092
Successfully built clickhouse-sqlalchemy
Installing collected packages: zstd, pytz, leb128, ciso8601, urllib3, tzlocal, lz4, idna, greenlet, charset-normalizer, certifi, sqlalchemy, requests, clickhouse-driver, asynch, clickhouse-sqlalchemy
  Attempting uninstall: zstd
    Found existing installation: zstd 1.5.5.1
    Uninstalling zstd-1.5.5.1:
      Successfully uninstalled zstd-1.5.5.1
  Attempting uninstall: pytz
    Found existing installation: pytz 2024.2
    Uninstalling pytz-2024.2:
      Successfully uninstalled pytz-2024.2
  Attempting uninstall: leb128
    Found existing installation: leb128 1.0.8
    Uninstalling leb128-1.0.8:
      Successfully uninstalled leb128-1.0.8
  Attempting uninstall: ciso8601
    Found existing installation: ciso8601 2.3.1
    Uninstalling ciso8601-2.3.1:
      Successfully uninstalled ciso8601-2.3.1
  Attempting uninstall: urllib3
    Found existing installation: urllib3 2.2.3
    Uninstalling urllib3-2.2.3:
      Successfully uninstalled urllib3-2.2.3
  Attempting uninstall: tzlocal
    Found existing installation: tzlocal 5.2
    Uninstalling tzlocal-5.2:
      Successfully uninstalled tzlocal-5.2
  Attempting uninstall: lz4
    Found existing installation: lz4 4.3.3
    Uninstalling lz4-4.3.3:
      Successfully uninstalled lz4-4.3.3
  Attempting uninstall: idna
    Found existing installation: idna 3.10
    Uninstalling idna-3.10:
      Successfully uninstalled idna-3.10
  Attempting uninstall: greenlet
    Found existing installation: greenlet 3.1.1
    Uninstalling greenlet-3.1.1:
      Successfully uninstalled greenlet-3.1.1
  Attempting uninstall: charset-normalizer
    Found existing installation: charset-normalizer 3.4.0
    Uninstalling charset-normalizer-3.4.0:
      Successfully uninstalled charset-normalizer-3.4.0
  Attempting uninstall: certifi
    Found existing installation: certifi 2024.8.30
    Uninstalling certifi-2024.8.30:
      Successfully uninstalled certifi-2024.8.30
  Attempting uninstall: sqlalchemy
    Found existing installation: SQLAlchemy 1.4.54
    Uninstalling SQLAlchemy-1.4.54:
      Successfully uninstalled SQLAlchemy-1.4.54
  Attempting uninstall: requests
    Found existing installation: requests 2.32.3
    Uninstalling requests-2.32.3:
      Successfully uninstalled requests-2.32.3
  Attempting uninstall: clickhouse-driver
    Found existing installation: clickhouse-driver 0.2.9
    Uninstalling clickhouse-driver-0.2.9:
      Successfully uninstalled clickhouse-driver-0.2.9
  Attempting uninstall: asynch
    Found existing installation: asynch 0.2.4
    Uninstalling asynch-0.2.4:
      Successfully uninstalled asynch-0.2.4
  Attempting uninstall: clickhouse-sqlalchemy
    Found existing installation: clickhouse-sqlalchemy 0.3.2
    Uninstalling clickhouse-sqlalchemy-0.3.2:
      Successfully uninstalled clickhouse-sqlalchemy-0.3.2
Successfully installed asynch-0.2.4 certifi-2024.8.30 charset-normalizer-3.4.0 ciso8601-2.3.1 clickhouse-driver-0.2.9 clickhouse-sqlalchemy-0.3.2 greenlet-3.1.1 idna-3.10 leb128-1.0.8 lz4-4.3.3 pytz-2024.2 requests-2.32.3 sqlalchemy-1.4.54 tzlocal-5.2 urllib3-2.2.3 zstd-1.5.5.1

@Kolliderrr
Copy link

Kolliderrr commented Oct 15, 2024

Which versions of SQLAlchemy are actually supported? Are the docs outdated?

In my code it worked at 1.4.54 Sqlalchemy. I think, it's only matter of time to rewrite some methodes for metadata to pass the tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants