Skip to content

Populate allowed_to_edit_files in check_suite and review handlers#2318

Merged
hiroshinishio merged 1 commit intomainfrom
wes
Feb 24, 2026
Merged

Populate allowed_to_edit_files in check_suite and review handlers#2318
hiroshinishio merged 1 commit intomainfrom
wes

Conversation

@hiroshinishio
Copy link
Collaborator

@hiroshinishio hiroshinishio commented Feb 24, 2026

Summary

  • Populated allowed_to_edit_files in check_suite_handler with PR changed files, validation error files, and the impl file from the PR title - so the agent can fix impl bugs it discovers during CI retries
  • Applied the same pattern to review_run_handler - PR changed files and validation error files are now in the allow list
  • Fixed test PR titles in test_check_suite_handler.py to use realistic GitAuto titles (e.g., "Low Test Coverage: src/main.py") instead of "Test PR"

Social Media Post (GitAuto)

When GitAuto creates a test coverage PR and CI fails because the implementation has bugs, the agent reads the error logs, identifies the root cause - then gets blocked from fixing it. The permission model only allowed editing test files, not the buggy implementation. Now the check suite handler populates an allow list with the PR's changed files and the implementation file, so the agent can fix what it finds.

Social Media Post (Wes)

Debugging a customer's failing coverage PR. GitAuto wrote correct tests, CI failed, the agent retried - and the logs showed it correctly identified four bugs in the source file. But then it errored out trying to edit it. The safety guard that restricts edits to test files only was too strict for the retry scenario. The allow list mechanism was already there, just never populated in the retry handler. Seven lines fixed it.

When CI fails on a coverage PR, the agent discovers impl bugs but can't
fix them because allowed_to_edit_files was empty. Now both handlers
populate the allow list from PR changed files, validation errors, and
(for check_suite) the impl file from the PR title.
@hiroshinishio hiroshinishio self-assigned this Feb 24, 2026
@hiroshinishio hiroshinishio merged commit 8a781fc into main Feb 24, 2026
1 check passed
@hiroshinishio hiroshinishio deleted the wes branch February 24, 2026 04:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant