Skip to content

Update encryptor.py: remove deprecation warning unaware datetimes #4

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

Open
dario-br opened this issue Apr 25, 2025 · 1 comment
Open

Comments

@dario-br
Copy link

Since Python 3.13 unaware timezone timestamps are deprecated. See deprecation warning:

encryptor.py:360: DeprecationWarning: datetime.datetime.utcfromtimestamp() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.fromtimestamp(timestamp, datetime.UTC).

  meta['created'] = datetime.utcfromtimestamp(source.stat().st_ctime).isoformat()

@dario-br
Copy link
Author

PR #3 fixes the deprecation warning

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant