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

Support older pythons #109

Open
manfredsc opened this issue Aug 6, 2024 · 2 comments
Open

Support older pythons #109

manfredsc opened this issue Aug 6, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@manfredsc
Copy link

What happened?

So far cdsapi was happily running on python 3.6. However, for the new platform cds-beta,
a new module is required, cads-api-client. This module does not work with python 3.6:

[   22s]   File "/usr/lib/python3.6/site-packages/cads_api_client/catalogue.py", line 1
[   22s] SyntaxError: future feature annotations is not defined
[   22s] 
[   22s]   File "/usr/lib/python3.6/site-packages/cads_api_client/legacy_api_client.py", line 1
[   22s] SyntaxError: future feature annotations is not defined
[   22s] 
[   22s]   File "/usr/lib/python3.6/site-packages/cads_api_client/processing.py", line 95
[   22s]     if not (content := message.get("content")):

It seems it would be not a lot of effort to make cads-api-client run on python 3.6. On some older Linux
distributions, including enterprise distributions, python 3.6 is all one can get, and doing a local, private installation of
the whole python stack is not really attractive.

Please keep cdsapi as generic as possible, it is the only possibility to do automated requests from CDS.

I will also post this request on the cads-api-client project page to increase awareness.
Thanks for consideration!

What are the steps to reproduce the bug?

.

Version

0.7.0

Platform (OS and architecture)

Linux

Relevant log output

No response

Accompanying data

No response

Organisation

No response

@manfredsc manfredsc added the bug Something isn't working label Aug 6, 2024
@veenstrajelmer
Copy link

veenstrajelmer commented Aug 9, 2024

The security support for Python 3.6 was already dropped over two years ago, as can be seen in this overview: https://devguide.python.org/versions/. This is independent of cdsapi, but actively maintained packages also should drop support for Python versions that are not security patched anymore. This is good practice. Not in the last place since some newer Python features do not work in all versions, so it is not doable maintaining support for old versions indefinately.

The oldest Python version that is still supported is Python 3.8, but security support will end in October this year. Many well known packages like numpy and xarray already dropped support for Python 3.8 a few months ago. I have an overview here if you are interested. Therfore, it is advisable to at least use Python 3.9 these days, but I would suggest moving to Python 3.11 or 3.12 immediately while you are at it.

@manfredsc
Copy link
Author

Linux distributions do their own packporting, your arguments are not really helpful for mere users. I do know that
support for version 3.6 has expired long time ago.

But the point remains, that Copernicus wants to drop the old API for the Climate Data Store with a
very tight time schedule, and the new API can't be accessed with python 3.6 anymore. So there are people
which will have problems beginning of September. There are already quite some Reports at the Copernicus Forum having troubles accessing the new cds-beta store.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants