Skip to content

Conversation

@PacificBird
Copy link

This pull request adds helper methods on Time, PrimitiveDateTime, and OffsetDateTime to obtain fractional time component representations for hours, minutes, and seconds.

For example, time!(01:30:00.0000).fractional_hour() == 1.5, time!(01:30:30.0000).fractional_hour() == 30.5, and so on.

@codecov
Copy link

codecov bot commented Jan 14, 2026

Codecov Report

❌ Patch coverage is 0% with 32 lines in your changes missing coverage. Please review.
✅ Project coverage is 95.1%. Comparing base (646dbe2) to head (a15aade).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
time/src/time.rs 0.0% 14 Missing ⚠️
time/src/offset_date_time.rs 0.0% 9 Missing ⚠️
time/src/primitive_date_time.rs 0.0% 9 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##            main    #763     +/-   ##
=======================================
- Coverage   95.4%   95.1%   -0.3%     
=======================================
  Files         95      95             
  Lines       9686    9718     +32     
=======================================
+ Hits        9242    9244      +2     
- Misses       444     474     +30     

☔ 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.

@jhpratt
Copy link
Member

jhpratt commented Jan 15, 2026

What's the use case here? Off-hand, I feel like this is best represented by a Duration constructed by subtracting Time::MIDNIGHT.

@jhpratt jhpratt added the C-needs-details Category: more details are needed to assess the situation label Jan 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C-needs-details Category: more details are needed to assess the situation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants