Skip to content

Conversation

ptomato
Copy link
Collaborator

@ptomato ptomato commented Aug 11, 2025

largestUnit can be any unit, AUTO, or UNSET here. ValidateTemporalUnitValue just checks if it is any unit, AUTO, or UNSET, so it's a no-op.

largestUnit can be any unit, ~auto~, or ~unset~ here.
ValidateTemporalUnitValue just checks if it is any unit, ~auto~, or
~unset~, so it's a no-op.
@ptomato ptomato requested a review from sffc August 11, 2025 19:18
Copy link

codecov bot commented Aug 11, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 96.78%. Comparing base (6964def) to head (b576c46).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3143      +/-   ##
==========================================
- Coverage   96.78%   96.78%   -0.01%     
==========================================
  Files          21       21              
  Lines       10003    10002       -1     
  Branches     1830     1830              
==========================================
- Hits         9681     9680       -1     
  Misses        276      276              
  Partials       46       46              

☔ 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.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Collaborator

@sffc sffc left a comment

Choose a reason for hiding this comment

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

Suggestion: Simply this further by changing ValidateTemporalUnitValue to accept only ~date~ and ~time~, since this is the only call site for ~datetime~.

@ptomato
Copy link
Collaborator Author

ptomato commented Aug 12, 2025

Suggestion: Simply this further by changing ValidateTemporalUnitValue to accept only ~date~ and ~time~, since this is the only call site for ~datetime~.

It can still be called with DATETIME in GetDifferenceSettings so we still need to accept DATETIME to deal with the situation where all units are valid but "auto" is not.

@ptomato
Copy link
Collaborator Author

ptomato commented Aug 12, 2025

Thanks for the review!

@ptomato ptomato merged commit 07c924b into main Aug 12, 2025
10 checks passed
@ptomato ptomato deleted the editorial branch August 12, 2025 00:42
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