crate / crate-python

Python DB API client library for CrateDB, using HTTP.
https://cratedb.com/docs/python/
Apache License 2.0
78 stars 31 forks source link

Chore: Adjust minimum Python version in project metadata #530

Closed fabaff closed 1 year ago

fabaff commented 1 year ago

Summary of the changes / Why this is an improvement

Align with classifiers and what's tested by CI.

Checklist

amotl commented 1 year ago

Dear Fabian,

thank you very much for submitting this adjustment. I've just verified the package will also install on Python 3.6, but will not work on earlier versions, because we started using f-strings already. While Python 3.6 is officially end-of-life already, we don't want to be too restrictive to prevent installation on older Python installations.

However, it still makes sense to stop announcing it within the classifiers list, or shall we bring it back? WDYT?

With kind regards, Andreas.

Appendix

Python 3.5

$ docker run --rm -it python:3.5 bash
$ pip install crate
$ python -c "import crate.client"
  File "/usr/local/lib/python3.5/site-packages/crate/client/cursor.py", line 311
    assert len(tz) == 5, f"Time zone '{tz}' is given in invalid UTC offset format"
                                                                                 ^
SyntaxError: invalid syntax

Python 3.6

$ docker run --rm -it python:3.6 bash
$ pip install crate[sqlalchemy]
$ python -c "import crate.client.sqlalchemy"
amotl commented 1 year ago

Dear Fabian,

I've just amended your patch a bit, and will bring it in now. Thank you again!

With kind regards, Andreas.