Add comprehensive missing attribution test suite#915
Open
Conversation
There was a problem hiding this comment.
CodeQL found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.
f315e33 to
4dbbd4b
Compare
Document 18 failure hypotheses (H1-H18) covering every identified scenario where AI attribution can be silently lost: JSONL corruption, SHA mismatches, partial checkpoints, binary files, merge commits, INITIAL file corruption, and multi-agent conflicts. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
27 integration tests covering 18 failure hypotheses for silent AI attribution loss. Tests exercise JSONL corruption, SHA mismatches, partial checkpoints, binary files, merge commits, INITIAL file corruption, multi-agent conflicts, and forward-compatibility edge cases. All tests pass (26 ok, 1 ignored observational). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Three missing_attribution tests (H6d, H7a, H18) intentionally create corrupt checkpoint data to document failure modes. In daemon mode, the daemon reports errors when processing these, causing wait_for_daemon_completion_sessions to panic before the test can check the outcome. Add allow_daemon_errors flag to TestRepo so these tests can indicate that daemon errors are expected. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
dd94f99 to
b274ec6
Compare
The allow_daemon_errors flag was only checked in wait_for_daemon_completion_sessions but not in the structurally identical wait_for_daemon_completion_count or wait_for_daemon_total_completion_count. This could cause tests that set allow_daemon_errors(true) to still panic if their execution path went through the other wait functions. Co-Authored-By: Claude Opus 4.6 <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.
Summary
Test plan
cargo test --test integration missing_attribution -- --test-threads=1passes (26 ok, 1 ignored)cargo fmt -- --checkpassescargo clippy --all-targets -- -D warningspasses🤖 Generated with Claude Code