ioos / erddapy

Python interface for ERDDAP
https://ioos.github.io/erddapy/
BSD 3-Clause "New" or "Revised" License
77 stars 30 forks source link

Support Python 3.10 and up #329

Closed ocefpaf closed 8 months ago

ocefpaf commented 10 months ago

Python 3.10 EOL is only in 2026-10 but this will allow us to move faster, drop some code, and avoid some deprecation warnings. I'm not in a hurry to merge this but #328 should only be merged after this one.

ocefpaf commented 8 months ago

@callumrollo and @abkfenris what do you think about this one? On one hand we will be able to move faster and adopt modern practices. However, this may be too premature b/c both 3.9 and 3.10 are still supported. What do you think?

callumrollo commented 8 months ago

I think it's reasonable to drop earlier python versions at this point. We have mature fully featured releases of erddapy that are compatible with older python versions if users still need to run <3.11

abkfenris commented 8 months ago

I guess my concern is if an ERDDAP release breaks erddapy, are we going to backport the changes, or ask that everyone move to 3.11 to get the fixes?

I know some of my other dependencies just added 3.11 support, and I'm pretty sure there are others that are lagging behind and keeping folks environments delayed with them.

abkfenris commented 8 months ago

And now I'm a little horrified by seeing that 3.8 and 2.7 release cycles overlapped.

How about we follow SPEC 0 and make the minimum version 3.10 to keep pace with the rest of the scientific ecosystem? I think that allows most of the typing updates in this PR.

ocefpaf commented 8 months ago

I guess my concern is if an ERDDAP release breaks erddapy, are we going to backport the changes, or ask that everyone move to 3.11 to get the fixes?

That is a good point and then my attempt to reduce the load will actually increase it. However, is a remote possibility and, if it happens, we can backport fixes.

And now I'm a little horrified by seeing that 3.8 and 2.7 release cycles overlapped.

😄

How about we follow SPEC 0 and make the minimum version 3.10 to keep pace with the rest of the scientific ecosystem? I think that allows most of the typing updates in this PR.

Let me see if this PR passes on 3.10. If not, I'll make it a draft and wait a bit more.

ocefpaf commented 8 months ago

OK. It is passing. I'll renamed the PR and check if I got all the py311 -> py310.

ocefpaf commented 8 months ago

Thanks @callumrollo and @abkfenris for the huge help here. The may be simple but the implications behind it aren't!