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 OffsetDateTime conversion for pre-Gregorian dates #2568

Merged
merged 3 commits into from
Dec 24, 2024
Merged

Conversation

machavan
Copy link
Contributor

Fixed conversion of DateTimeOffset to OffsetDateTime to use Calendar class, to handle pre-Gregorian dates.

Testing:

  • All tests pass
  • Added a new test to test reported scenarios.

Copy link

codecov bot commented Dec 18, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 51.05%. Comparing base (6829848) to head (2c91546).
Report is 3 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #2568      +/-   ##
============================================
- Coverage     51.12%   51.05%   -0.08%     
+ Complexity     3940     3922      -18     
============================================
  Files           147      147              
  Lines         33456    33466      +10     
  Branches       5604     5604              
============================================
- Hits          17105    17086      -19     
- Misses        13963    13971       +8     
- Partials       2388     2409      +21     

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

@machavan machavan merged commit 74a5cb8 into main Dec 24, 2024
19 checks passed
@machavan machavan deleted the dev/machavan/2565 branch December 24, 2024 05:15
Ananya2 pushed a commit that referenced this pull request Jan 10, 2025
* Fix OffsetDateTime conversion for pre-Gregorian dates

* Formatting changes

* Removed unused import
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Closed/Merged PRs
Development

Successfully merging this pull request may close these issues.

DateTimeOffset incorrectly re-converted to Gregorian calendar for historical dates
3 participants