fix issues #1 and #3: safety trinity + strict date parsing#4
Merged
Conversation
Issue #3 — strict date parsing (SheetsClient): - Only YYYY-MM-DD is accepted; any other format throws IllegalArgumentException with the row number and sheet name so bad spreadsheet data fails loudly at startup, not silently mid-run. - The expiry instant is now the start of the *following* UTC day (date + 1 day at midnight UTC), making the disable-until boundary timezone-independent across all CI runners. - Removed the multi-format fallback parsers; added 9 unit tests in SheetsClientDateParsingTest. Issue #1 — safety trinity (SkipperResolver + SheetsWriter): - SKIPPER_FAIL_OPEN (default true): when the Sheets API is unreachable and no valid cache exists, all tests run instead of the process crashing. - SKIPPER_CACHE_FILE (default .skipper-cache.json) + SKIPPER_CACHE_TTL (default 300 s): successful fetches are persisted to disk and used as a fallback within the TTL window. - SKIPPER_SYNC_ALLOW_DELETE (default false): SheetsWriter.sync() now detects orphaned rows and warns about them; actual deletion requires opting in via the env var. Rows are deleted via a single batchUpdate call in reverse-index order to avoid shifting. - Added SkipperResolverCacheTest with 5 unit tests covering write/read round-trip, missing file, expired TTL, and fail-open semantics. https://claude.ai/code/session_016isAj14n4LxGLoSMYyRA6V
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.
Issue #3 — strict date parsing (SheetsClient):
IllegalArgumentException with the row number and sheet name so bad
spreadsheet data fails loudly at startup, not silently mid-run.
(date + 1 day at midnight UTC), making the disable-until boundary
timezone-independent across all CI runners.
SheetsClientDateParsingTest.
Issue #1 — safety trinity (SkipperResolver + SheetsWriter):
and no valid cache exists, all tests run instead of the process
crashing.
(default 300 s): successful fetches are persisted to disk and used as
a fallback within the TTL window.
detects orphaned rows and warns about them; actual deletion requires
opting in via the env var. Rows are deleted via a single batchUpdate
call in reverse-index order to avoid shifting.
round-trip, missing file, expired TTL, and fail-open semantics.
https://claude.ai/code/session_016isAj14n4LxGLoSMYyRA6V