fix: tolerate invalid device timezones in Week Ahead (Closes #1177)
CI / lint (pull_request) Successful in 3m19s
CI / build-release (pull_request) Successful in 8s
CI / browser-journey (pull_request) Successful in 4m30s
CI / release-candidate (pull_request) Has been skipped

This commit is contained in:
timmy committed 2026-08-20 12:26:35 +00:00
1 parent 5a9cce4a08
commit 53c4340d76
2 files changed
+19 -1

No files matched your search

+12
View File
@@ -132,6 +132,18 @@ process.stdout.write(JSON.stringify({{date:rollover.localDate(),zone:rollover.ti
assert run_node(script) == {"date": "2026-11-01", "zone": "America/New_York"}
def test_invalid_runtime_timezone_falls_back_to_utc_without_breaking_planners():
script = f"""
const create = require({json.dumps(str(ROLLOVER))});
const rollover = create({{
now:()=>new Date('2026-08-20T23:30:00Z'),
resolvedTimeZone:()=> 'Etc/Unknown'
}});
process.stdout.write(JSON.stringify({{date:rollover.localDate(),zone:rollover.timeZone()}}));
"""
assert run_node(script) == {"date": "2026-08-20", "zone": "UTC"}
def test_rollover_is_one_durable_sync_operation_with_the_server_revision():
script = f"""
const createSync = require({json.dumps(str(SYNC))});