You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Summary verdict: Medium correctness issues remain in agent-hook activation and daemon compatibility; no medium-or-higher security issues were found.
Medium
internal/agenthook/state.go:104
The hook skips unless .roborev.toml exists, but roborev init only creates that file when --agent is specified. Repos using the normal init/review flow can have open failed reviews and installed hooks, yet the agent hook will never query the daemon or prompt. Fix: Remove the local .roborev.toml gate and let the daemon job query determine whether the repo has actionable roborev reviews, or validate repo registration through the daemon instead.
internal/agenthook/state.go:357
The hook uses the current worktree root as the repo filter for /api/jobs. Existing daemon clients normalize worktrees to the main repo root because jobs are stored under that path, so linked worktree sessions will under-count failed reviews as zero and never trigger. Fix: Normalize the discovered repo path to the main repo root before calling countOpenFailedReviews, while still using the current worktree for branch/head detection if needed.
internal/agenthook/client.go:118
Agent-hook daemon discovery accepts any responsive roborev-agent-hook service regardless of version. After a roborev update, hooks can continue talking to an old daemon with stale request/state logic, contrary to the repo’s lockstep daemon/client model. Fix: Treat info.Version != version.Version as incompatible in discovery/probing and restart or replace the stale daemon/runtime record.
Summary verdict: Two medium-severity correctness issues need attention; no medium-or-higher security issues were found.
Medium
internal/agenthook/client.go:110: The agent-hook daemon compatibility check accepts any roborev-agent-hook service regardless of version. After a roborev update, the client may continue posting new request shapes to an old daemon even though daemon/client APIs are expected to move in lockstep.
Fix: Require info.Version == version.Version when discovering/probing the hook daemon, and ignore or restart stale runtimes. Update the wrong-version test accordingly.
internal/agenthook/state.go:277: FailedReviewTriggeredCount is session-global while failed-review counts are scoped to the current repo and branch. After triggering in one repo, switching to another repo with an equal or lower failed-review count can suppress prompts indefinitely because the comparison uses the previous repo’s count baseline.
Fix: Track failed-review trigger baselines per repo+branch, or reset the baseline whenever repoRoot or branch changes.
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
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
roborev agent-hookcommands for Codex/Claude harness hooks with install/dump/run/status/reset/daemon support.internal/agenthook, with native[agent_hook]TOML config and fail-open hook execution.go.kenn.io/kitusage.Current Status
main, but we expect to rebase again after the pending roborev daemon lifecycle work lands.Verification
go test ./...go vet ./...go build ./...roborev agent-hook dumpsmoke checks$roborev-fix: addressed/closed failing review jobs 21365, 21452, and 21453; final review job 21456 passed.