fix: TIMESTAMP/TIMESTAMP_TZ semantics (engine PR #723 covers this)#44
Closed
adsharma wants to merge 4 commits into
Closed
fix: TIMESTAMP/TIMESTAMP_TZ semantics (engine PR #723 covers this)#44adsharma wants to merge 4 commits into
adsharma wants to merge 4 commits into
Conversation
… conversion PyQueryResult::convertValueToPyObject (pybind path) and all interval conversion sites in _lbug_capi.py (C-API path) now use days = years * 365 + months * 30 + days instead of days = months * 30 + days This gives 365 days per whole year instead of 360, matching the engine's Interval::DAYS_PER_YEAR constant.
Interval months-to-days conversion now uses DAYS_PER_YEAR (365) for whole years instead of DAYS_PER_MONTH * 12 (360). Updated all test assertions: 3 years 2 days 13:02:00 -> 1097 days (was 1082) 10 years 5 months 13h -> 3800 days (was 3750) 26 years 52 days 48h -> 9544 days (was 9414)
…values" This reverts commit 1a13d9f.
…imedelta conversion" This reverts commit 01bbac6.
Contributor
Author
|
The TIMESTAMP/TIMESTAMP_TZ semantics fix is solely an engine change (LadybugDB/ladybug#723). The interval fix will be submitted separately once the engine change lands and a new prebuilt lib is available. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR has been reverted to empty — the interval fix requires the engine change to be merged first. The TIMESTAMP/TIMESTAMP_TZ semantics fix is in LadybugDB/ladybug#723.