push
github
datetime: refactored new() and set() - part 5 `datetime.new()` and `datetime_object:set()` code refactored for more clarity. - Deduplicated tzindex, tzoffset extract. - Deduplicated buggy epoch adjustment (see gh-10363). - Fixes `new()` with timestamp to use it as base_epoch to calculate tzoffset instead of `epoch_from_dt(dt)` with default `dt = DAYS_EPOCH_OFFSET` (gh-12412). - Make `set()` with tzoffset only to reset tzindex to zero (gh-12416, part of gh-7680). Fixes #12412 Closes #12416 Part of #7680 See also #10363 NO_DOC=bugfix (cherry picked from commit 2ae86783b)
70184 of 118103 branches covered (59.43%)
105492 of 120408 relevant lines covered (87.61%)
1398296.3 hits per line