Repository navigation
test(wayback): pin the per-app route tests to the archive floor, not the calendar - #395
Merged
Merged
Conversation
…the calendar The two route tests cannot pass `today`, so their target grid steps back from the wall clock in whole months. Their 2021-06-01 capture sat 44 days from a target when the month's day was 15 and 45.4 days when it was 16, past the 45-day drift tolerance, so `imported` was 0 on the 16th of some months and the Docker publish on e6243d9 failed in `quality`. A capture on the floor is always a target and never drift-skipped. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
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.
What and why
The Docker publish run on
e6243d9(#394's merge) failed inqualityon one unit test,tests/app/historical-import-chain.test.ts"the per-app route accepts force and records it":importedwas 0, not 1. #394 is not the cause: the same test fails atd2cff0aand940a8c6today, and #394's own PR CI passed on the identical tree a day earlier.The test depends on the calendar. The two per-app route tests cannot pass
todayto the importer, so their quarterly target grid is anchored on the wall clock, stepping back from the current date in whole months (computeHistoricalTargets). Their mocked capture is dated 2021-06-01. With the realcomputeHistoricalTargets:skipped_drift, soimportedis 0.Across the next 120 days the test fails on exactly two of them (16 Oct, 16 Jan), which is why it has never failed in a PR before and why it will fail again every few months, on main and in the release's Docker job alike.
The fix is in the tests only: both route tests now mock a capture on the archive floor (2021-02-01). The floor is pushed as a target unconditionally, so a capture on it is never drift-skipped whatever the date. Nothing else in the file changes, and the importer and route are untouched.
How it was verified
Datepinned by a preload to 2026-10-15T05:17Z, 2026-10-16T14:50Z, 2027-01-16T12:00Z and 2026-11-30T23:59Z: 23 passed, 0 failed each time.e6243d9, pinned to 2026-10-16T14:50Z, reproduces the failure.🤖 Generated with Claude Code