Repository navigation
fix: read 1904 date system XLSX dates correctly in the web engine - #1092
Merged
Merged
Conversation
Signed-off-by: minutechreview <141821420+minutechreview@users.noreply.github.com>
Contributor
|
@minutechreview is attempting to deploy a commit to the yashkewlani2020-gmailcom's projects Team on Vercel. A member of the Team first needs to authorize it. |
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.
Summary
A workbook saved with the 1904 date system now gets the same date labels in the web engine as in pandas, instead of dates four years and a day early.
Type
Details
parseXLSXreadsworkbook.Workbook.WBProps.date1904afterXLSX.readand passes it throughstringifyXlsxDateCellstoformatXlsxDateCell, which callsXLSX.SSF.parse_date_code(serial, { date1904 }).test_xlsx_date_cells_get_the_same_labels_in_both_enginesis now parametrized over both date systems (with the existing three time zones), using openpyxl'sCALENDAR_MAC_1904epoch for the 1904 workbook.Checks:
tests/test_xlsx_edge_cases.py14 passed; the three new 1904 cases fail without the JS change.ruff check,check_em_dash.pyandcheck_generated_files_current.pypass. The full suite (withouttests/browser) has the same 10 failures before and after this change, all intest_cli.pyand two JS parity tests, which look like a local environment issue rather than this change.Linked issue
Fixes #1076