Repository navigation
Conversation
… integration tests
…egistry, flare-output, flare-code
📝 WalkthroughWalkthroughAdds the ChangesAgent execution and registry
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant Operator
participant WorkCommand
participant MCPBackend
participant AgentProcess
Operator->>WorkCommand: invoke work target
WorkCommand->>MCPBackend: claim item and obtain worktree
WorkCommand->>AgentProcess: run headless agent with autonomous args
AgentProcess-->>WorkCommand: result, stdout, stderr
WorkCommand->>MCPBackend: mark done or release and comment
Possibly related PRs
Suggested labels: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (2)
crates/agent-registry/src/registry.rs (2)
319-329: 🧹 Nitpick | 🔵 TrivialOperational note: bypass/YOLO flags run unattended, outside a container sandbox.
agentflare worklaunches these agents with permission-bypass flags (--dangerously-skip-permissions,--yolo) inside a plain git worktree, not a network/filesystem sandbox. Vendor guidance for all three agents explicitly recommends running bypass modes only inside containers/VMs with restricted network and no credentials loaded, given documented incidents of destructiverm -rf/ credential-exfiltration outcomes. Worth considering container isolation (or at minimum a locked-down--allowedTools/--disallowedTools-style scope) foragentflare work's execution environment given it's unattended and autonomous by design.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@crates/agent-registry/src/registry.rs` around lines 319 - 329, Update the unattended agent execution flow that consumes autonomous_args so bypass modes are not launched in an unrestricted plain worktree. Add container/VM isolation with restricted network and credentials, or enforce an equivalent allowed/disallowed tool scope for ClaudeCode, Codex, and GeminiCli before launching autonomous work; preserve normal execution for agents without bypass flags.
309-329: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winSwitch Codex to the current non-interactive permission flags
--full-autois now a deprecated compatibility path incodex execand emits a warning. Replace it with Codex’s explicit sandbox/approval flags or a saved profile so this registry entry doesn’t depend on a legacy switch that may disappear.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@crates/agent-registry/src/registry.rs` around lines 309 - 329, Update the Codex branch in autonomous_args to replace the deprecated --full-auto switch with Codex’s current explicit non-interactive sandbox and approval flags, or the established saved-profile option. Keep the existing behavior for ClaudeCode, GeminiCli, and agents without known bypass flags unchanged.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@crates/agent-registry/src/registry.rs`:
- Around line 319-329: Update the unattended agent execution flow that consumes
autonomous_args so bypass modes are not launched in an unrestricted plain
worktree. Add container/VM isolation with restricted network and credentials, or
enforce an equivalent allowed/disallowed tool scope for ClaudeCode, Codex, and
GeminiCli before launching autonomous work; preserve normal execution for agents
without bypass flags.
- Around line 309-329: Update the Codex branch in autonomous_args to replace the
deprecated --full-auto switch with Codex’s current explicit non-interactive
sandbox and approval flags, or the established saved-profile option. Keep the
existing behavior for ClaudeCode, GeminiCli, and agents without known bypass
flags unchanged.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 84f2ca2f-fb54-48fa-a037-e1e6447c02ee
📒 Files selected for processing (17)
crates/agent-registry/src/detect.rscrates/agent-registry/src/lib.rscrates/agent-registry/src/registry.rscrates/flare-code/src/config.rscrates/flare-code/src/detect.rscrates/flare-code/src/state.rscrates/flare-output/src/compress.rscrates/flare-output/src/llm.rscrates/flare-output/src/validate.rssrc/agent_launch.rssrc/agents.rssrc/cli/handoff.rssrc/cli/mod.rssrc/cli/optimize.rssrc/cli/work.rssrc/mcp_server.rssrc/mcp_server/item.rs
Summary
agentflare workplan, following on from Tasks 1-5 onfeat/agentflare-work): extractswork.rsinto pure, unit-tested helpers (build_prompt,parse_claude_reply,format_success_comment,failure_message,build_extra_args), wires Claude Code's--output-format jsonstructured-output parsing (session id / cost capture), adds a--notifyhandoff hook, and adds two real integration tests against an isolatedAgentflareMcp::for_testinstance (new constructor).cargo clippy --workspace --all-features -- -D warningsdebt inagent-registry,flare-output, andflare-code(missing# Errors/# Panicsdocs,implicit_hasher,match_same_arms,needless_pass_by_value,cast_possible_truncation,doc_markdown,redundant_closure_for_method_calls) — unrelated to the work-command change but blocking the full workspace lint gate.Test plan
cargo build --workspace --all-featurescargo clippy --workspace --all-features -- -D warnings(clean)cargo fmt --all -- --check(clean)cargo test --workspace(all green, incl. 12 newcli::worktests)Summary by CodeRabbit
workcommand to claim work items, run agents in dedicated worktrees, and report completion or failure.