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

remove deprecated method in python3.12 #803

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Hukeqing
Copy link

@Hukeqing Hukeqing commented Dec 4, 2023

Because datetime.datetime.utcnow() was marked deprecated in 3.12, but datetime.UTC was only supported from 3.11. In order to ensure usability, I used sys.version_info to check the current version to apply to lower versions of python. I tested in python2.7, python 3.8, python3.11 and python3.12 respectively, and they were all in line with expectations.

@nuriddinislamov
Copy link

nuriddinislamov commented Apr 2, 2024

@sivel, Please merge this!

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