You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
issue_105
#105
Problem:
datetime: datetime.datetime’s utcnow() and utcfromtimestamp() are deprecated and will be removed in a future version. Instead, use timezone-aware objects to represent datetimes in UTC: respectively, call now() and fromtimestamp() with the tz parameter set to datetime.UTC. (Contributed by Paul Ganssle in gh-103857.)
Solution:
To add new function to get actual datetime_now with timezone and remove timezone to save the datebase models unchanged (to use postgresql and sqlite).
Conclusion:
All timestamps converts to utc timezone and stores without timezone in the database
Reviewed-by: Aloento
Reviewed-by: Vladimir Hasko <[email protected]>
Reviewed-by: Ilia Bakhterev
Reason
We use naive datetime, but from "#101" began to add a time zone in the interface.
Better to use aware datetime in the future
Additional information:
Python 3.12:
datetime.datetime’s utcnow() and utcfromtimestamp() are deprecated and will be removed in a future version.
Changes:
Changed all datetime objects and related methods to use the UTC time zone.
The text was updated successfully, but these errors were encountered: