test(#260): regression test — validator-rejected ingest creates no table#279
Merged
Merged
Conversation
#260 (orphaned table on validator rejection) was fixed by deferring create_table until after validate_data passes (table_schema is stashed in __init__, the table created in _ingest_with_lock after validation). That fix shipped without the regression test its acceptance criteria called for. Adds tests/test_ingest_atomicity.py pinning the ordering: - a validator-rejected ingest raises and leaves NO table (database.create_table is never called), so a rejected ingest is idempotent and doesn't block the next attempt with the stale-table guard; - a clean validation still creates the table (the deferral didn't break the happy path). Closes #260. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Collaborator
Author
|
👋 Heads-up — Code review queue is at 17 / 8 Above the WIP limit. The team convention is to review existing PRs before opening new work. Open PRs currently in Code review (oldest first):
Pull from review before opening new work. (This is a nudge from the kanban WIP check, not a block.) |
divyasinghds
approved these changes
Jun 17, 2026
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
#260 (orphaned table on validator rejection) is already fixed on
develop—create_tablewas deferred out of__init__to aftervalidate_datapasses (_table_schemastashed in__init__, table created in_ingest_with_lock). That fix shipped without the regression test its acceptance criteria called for. This adds it.tests/test_ingest_atomicity.pypins the ordering:database.create_tableis never called, so a rejected ingest is idempotent and doesn't block the next attempt with the "table already exists … drop it" guard (the original bug: validator-rejected ingest leaves an orphaned table; no rollback blocks the next ingest #260 symptom);Both pass on
develop. Independent of the open P5 refactor stack (new file, no overlap).Closes #260.
🤖 Generated with Claude Code