Skip to content

Conversation

@Hatell
Copy link

@Hatell Hatell commented Oct 24, 2025

Fixes issue when DST is changed between calculation.

Fixes issue when DST is changed between calculation.
@auvipy auvipy requested review from auvipy and Copilot October 25, 2025 15:53
Copy link

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 fixes a DST (Daylight Saving Time) issue in the scheduler by ensuring time calculations use UTC instead of local time. This prevents incorrect time_since_last_sync calculations when DST transitions occur between sync operations.

Key Changes:

  • Modified current_time to use UTC timezone instead of naive local time

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

Copy link
Member

@auvipy auvipy left a comment

Choose a reason for hiding this comment

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

can you please also add test to verify the change? can you also link relevant issue as well?

@codecov
Copy link

codecov bot commented Oct 25, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 87.58%. Comparing base (ba33a9c) to head (6b726f5).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #964      +/-   ##
==========================================
- Coverage   88.18%   87.58%   -0.60%     
==========================================
  Files          32       32              
  Lines        1007     1007              
  Branches      105       81      -24     
==========================================
- Hits          888      882       -6     
- Misses        101      107       +6     
  Partials       18       18              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@auvipy auvipy marked this pull request as draft October 25, 2025 16:07
@auvipy
Copy link
Member

auvipy commented Oct 25, 2025

please also check the failing tests due to this change

@cclauss
Copy link
Contributor

cclauss commented Oct 25, 2025

https://docs.python.org/3/library/datetime.html#datetime.UTC was added in Python 3.11.

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.

3 participants