Fix attribution debug self-check timeouts#1944
Open
svarlamov wants to merge 1 commit into
Open
Conversation
svarlamov
marked this pull request as ready for review
July 21, 2026 15:21
svarlamov
force-pushed
the
fix/debug-attr-self-check-timeout
branch
from
July 21, 2026 18:53
757a14a to
3808e14
Compare
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
git-ai debugcheckpointsTestReporegression that validates the daemon-home path, both self-check targets, and every expected attribution classRoot cause
The attribution self-check shared its three-second deadline between repository setup, three checkpoints, commit processing, and result polling. A new two-second post-commit session-event recovery preflight consumed most of that budget, while the two self-check repositories competed concurrently. In installed debug builds, the synthetic
mock_aicheckpoint also opened the production metrics throttle database even though mock metrics are discarded.The remaining Windows failure exposed a split-home bug in the test harness: the debug subprocess created repositories beneath its isolated process home, while the shared daemon determined the self-check root from
GIT_AI_DAEMON_HOME. Because those paths differed, the daemon did not recognize the repositories as synthetic and still ran the recovery path. Windows latency then exhausted the fresh polling deadline.Impact
git-ai debugnow waits for attribution with its own bounded budget, creates diagnostic repositories beneath the active daemon's internal directory, and avoids production-only recovery and telemetry work that cannot affect the synthetic result. Normal checkpoint, recovery, and trace2 ingestion behavior is unchanged.Validation
task test TEST_FILTER=attribution_self_checks_do_not_timeouttask testtask buildtask linttask fmttask devgit-ai debugsmoke test: both attribution self-checks passed with untracked, known-human, and AI lines correctly classified