fix: resolve 16 code review bugs + 25 regression tests#12
Merged
Conversation
…l, agent Circuit breaker (#21-27): move lastFailure before throw, add recordSuccess(), rename open→healthy, increase cooldown to 30s, remove unused params, use bash -c for commands, mergeDeep for config. Refine tool (#28-31): build change summary from parent session messages, remove tools:{} blocking agent access, extract <evaluation> block before parsing + NaN guard, try/finally session cleanup. Scripts (#34-35): insert -- before user args, use :: separator for tool IDs. Skill (#33): add content cache in loadContent(), cleared on state reload. Agent (#36): remove bash from evaluator permissions. Command (#32): by design — added comment, no code change. Adds 25 new tests covering all fixed bugs.
e6qu
added a commit
that referenced
this pull request
Mar 18, 2026
…l, agent (#12) Circuit breaker (#21-27): move lastFailure before throw, add recordSuccess(), rename open→healthy, increase cooldown to 30s, remove unused params, use bash -c for commands, mergeDeep for config. Refine tool (#28-31): build change summary from parent session messages, remove tools:{} blocking agent access, extract <evaluation> block before parsing + NaN guard, try/finally session cleanup. Scripts (#34-35): insert -- before user args, use :: separator for tool IDs. Skill (#33): add content cache in loadContent(), cleared on state reload. Agent (#36): remove bash from evaluator permissions. Command (#32): by design — added comment, no code change. Adds 25 new tests covering all fixed bugs. Co-authored-by: Adrian Mârza <adi11235 at gmail dot com>
3 tasks
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
Fixes all 16 active bugs from the 2026-03-17 code review across 6 files, with 25 new regression tests.
lastFailurebefore throw,recordSuccess()on pass,open→healthyrename, cooldown 1s→30s, remove unusedscope/files/criteriaparams,bash -cinstead ofcommand.split(" "),mergeDeepfor nested configtools: {}blocking agent tool access, extract<evaluation>block before parsing + NaN guard, try/finally session cleanup--separator before user args to prevent injection,::separator for tool IDs to avoid collisionloadContent(), cleared on state reloadbash: "allow"from evaluator permissionsTest plan
bun typecheck— cleanbun test— 1401 pass, 0 fail (25 new tests)test/tool/verify.test.ts,test/tool/refine.test.ts,test/tool/scripts.test.ts,test/skill/skill-cache.test.tstest/agent/agent.test.tsfor evaluator/optimizer permissions