fix(agents): delegate refactor-assistant test execution to the caller#731
Merged
Merged
Conversation
The Safety Verification Protocol hard-required running the test suite, re-running after each change, comparing pass counts, and reverting on failure, but the agent's tool whitelist (Read, Edit, Glob, Grep) has no Bash, so none of it could execute. Reword the protocol so test execution, commits, and rollback are the calling session's responsibility, resolving the self-contradiction without changing tools or permissionMode.
3 tasks
This was referenced Jun 13, 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.
변경 내용
refactor-assistant에이전트 정의(plugin/agents/+project/.claude/agents/, 2개 파일)의## Safety Verification Protocol섹션을 재서술하여, 테스트 실행·커밋·revert 책임을 호출 세션(calling session)에 위임하도록 정직하게 표현했다.배경
이 에이전트의
tools는Read, Edit, Glob, Grep로Bash가 없다. 그런데 기존## Safety Verification Protocol은 다음을 hard requirement로 명시하고 있었다.Bash가 없으므로 테스트 실행·커밋·git revert중 어느 것도 수행할 수 없다. 즉 동작 보존(behavior-preserving) 안전 계약 전체가 실행 도구 없이 약속되어 있어, 검증 없는 "테스트 통과" 보고로 이어질 수 있는 자기모순이었다. 또한project레이어의permissionMode: acceptEdits와 결합되면 검증되지 않은 편집이 자동 수락된다.구현
## Safety Verification Protocol섹션을 재서술하여, 이 에이전트는 편집만 적용하고 테스트 실행·커밋·rollback은 호출 세션이 담당함을 명문화했다.Before / During / After / Hard Stops하위 항목을 "호출 세션에 테스트 baseline 확인 요청", "각 변경마다 호출 세션이 실행할 테스트 명령을 보고", "실패 보고 시 해당 변경 revert 권고" 형태로 조정했다.## Process의run baseline tests문구를confirm the test baseline with the calling session으로 수정했다.tools,permissionMode등 frontmatter는 변경하지 않았다(옵션 B). 따라서 후속permissionMode정렬 작업과 충돌하지 않는다.검증
scripts/check_agents.sh→check_agents: OK (8 agent pairs in sync)(sandbox OFF 기준 — CI 게이트와 일치)grep "Run existing test suite\|Re-run tests after each change\|Run full test suite"→ 2개 파일 모두 0건비고
옵션 (B) 단일 반환·호출자 위임 설계를 택했다. 별도의 테스트 실행 전담 노드(
test-runner) 신설은 epic #726의 P1 항목으로 분리되어 있다.Closes #728
Part of #726