Skip to content

Addressed warnings about deprecated utcnow usage#53

Open
fbarreir wants to merge 5 commits into
masterfrom
housekeeping2
Open

Addressed warnings about deprecated utcnow usage#53
fbarreir wants to merge 5 commits into
masterfrom
housekeeping2

Conversation

@fbarreir
Copy link
Copy Markdown
Contributor

@fbarreir fbarreir commented Jun 5, 2026

No description provided.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates worker-node scripts to avoid deprecated datetime.datetime.utcnow() / utcfromtimestamp() usage by introducing helper functions that produce equivalent naive UTC datetime values without triggering deprecation warnings on newer Python versions.

Changes:

  • Added naive_utcnow() and naive_utcfromtimestamp() helpers in pandawnutil.wnmisc.misc_utils.
  • Replaced direct utcnow() calls in runGen.py and runAthena.py with naive_utcnow().
  • Updated checkpoint uploader file mtime handling to use naive_utcfromtimestamp() and checkpoint timestamps to use naive_utcnow().

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
src/rungen/runGen.py Switches build/result timestamp printing from deprecated utcnow() to naive_utcnow().
src/runathena/runAthena.py Switches build/result timestamp printing from deprecated utcnow() to naive_utcnow().
pandawnutil/wnmisc/misc_utils.py Introduces UTC helper functions and applies them to checkpoint uploader time comparisons.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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