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

Fix datetime deprecation #106

Merged
merged 1 commit into from
Oct 27, 2023
Merged

Fix datetime deprecation #106

merged 1 commit into from
Oct 27, 2023

Conversation

JonZeolla
Copy link
Member

@JonZeolla JonZeolla commented Oct 25, 2023

Contributor Comments

This fixes a datetime deprecation.

On creation of new repos with cookiecutter-python we have recently started getting:

/var/folders/0z/bsq8pvz92rx6sxjh_h5d95fw0000gn/T/tmp7sh1faqb.py:39: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC).
timestamp = datetime.datetime.utcnow().isoformat(timespec="seconds")

Pull Request Checklist

Thank you for submitting a contribution to cookiecutter-python!

In order to streamline the review of your contribution we ask that you review and comply with the below requirements:

  • If you are adding a dependency, please explain how it was chosen.
  • If manual testing is needed in order to validate the changes, provide a testing plan and the expected results.
  • Validate that documentation is accurate and aligned to any project updates or additions.

Don't forget our more detailed contribution guidelines
here.

@JonZeolla JonZeolla requested a review from seanctech as a code owner October 25, 2023 14:10
@JonZeolla JonZeolla enabled auto-merge (squash) October 25, 2023 14:17
Copy link
Member

@seanctech seanctech left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 🚀

@JonZeolla JonZeolla merged commit 2efc5af into main Oct 27, 2023
@JonZeolla JonZeolla deleted the fix-deprecation branch October 27, 2023 17:22
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

Successfully merging this pull request may close these issues.

2 participants