-
Notifications
You must be signed in to change notification settings - Fork 40
Closed
Labels
bugSomething isn't workingSomething isn't workingdiscussionIt's not clear yetIt's not clear yetsdkSomething to do with the `sdk` packageSomething to do with the `sdk` package
Milestone
Description
Currently, we're using datetime.UTC, a constant defined in the built-in datetime module.
However, this constant was only introduced in Python version 3.11, as you can see in the documentation:
- Does not exist in datetime Python 3.10
- Exists in datetime python 3.11
We did not catch this, as we most likely programmed the module with Python >= 3.11 and our CI also runs mypy with Python 3.12.
Now, we have two ways forward, in my opinion:
- Deprecate Python < 3.11 (which I'm against since Python 3.10 has its EoL in 2026-10)
- Adapt the code to use
datetime.timezones.utcinstead (which existed beforehand) and furthermore adapt our CI to always test with the minimal supported Python version, as we can reasonably assume that Python is properly backward compatible between minor versions
If we decide for the latter, I'm for deprecating Python 3.8 in the same step, considering it reached its EoL 2024-10-07.
We should also note somehwere that we always support the currently active Python versions (so atm 3.9 - 3.13) and probably need a recurring task that checks the EoL of Python versions (Python 3.9 reaches EoL on 2025-10).
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingdiscussionIt's not clear yetIt's not clear yetsdkSomething to do with the `sdk` packageSomething to do with the `sdk` package