Skip to content

feat: add Factory Droid and Devin CLI agent adapters - #27

Merged
vsn411 merged 1 commit into
secfoo-com:mainfrom
AmirNCI:feat/droid-devin-agents
Oct 7, 2026
Merged

vsn411 merged 1 commit into
secfoo-com:mainfrom
AmirNCI:feat/droid-devin-agents

Conversation

@AmirNCI

@AmirNCI AmirNCI commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

What does this change, and why?

Adds two new agent adapters (SECFOO-6): Factory Droid and Devin, following
the existing AgentAdapter pattern used by claude/codex/gemini. Both are
registered in agents/registry.py and cli.py's AgentId enum, with unit
tests following test_codex.py's pattern.

NOT yet verified against a live account: no FACTORY_API_KEY or Devin
login was available while writing this. Both adapters run cleanly through
the full secfoo run pipeline end to end (correct command built, real CLI
invoked, clean status returned) — see each file's docstring for the exact
flags verified and what still needs a real account to confirm.

Testing

  • pytest tests passes (700 passed)
  • ruff check . passes on the new/changed files (cli.py's pre-existing
    Optional[X]-style findings are unrelated to this change)
  • Added/updated tests for the behavior change

🤖 Generated with Claude Code

Adds two new agent adapters following the existing AgentAdapter pattern
(build_command()/extract_report()/extract_usage()), registered in
agents/registry.py and cli.py's AgentId enum:

- droid.py: Factory CLI (`droid exec`). Authenticates via FACTORY_API_KEY
  (env var, so it can run headlessly in CI once configured). Defaults to
  read-only mode with no extra flag needed. Flag parsing (`--`, `--cwd`,
  `--output-format json`) was verified directly against the real CLI.

- devin.py: Devin CLI (`devin -p`). Authenticates only via a one-time
  interactive `devin auth login` -- no env-var/API-key path exists, so
  unlike Droid it can't be authenticated from a bare CI runner without a
  human logging in first. Requires --respect-workspace-trust false, or
  non-interactive runs fail on any directory Devin hasn't seen before.

15 new unit tests (tests/test_agents/test_droid.py, test_devin.py) cover
build_command()/extract_report()/extract_usage(), following the pattern
in test_codex.py.

Both adapters run cleanly through the full `secfoo run` pipeline (prompt
rendered, real CLI invoked, clean status returned) but have NOT been
verified against a live account -- no FACTORY_API_KEY or Devin login was
available while writing this. See each file's docstring for exactly what
was and wasn't verified.

Testing:
- pytest tests: 700 passed, 0 failed
- ruff check on the new/changed files: clean (cli.py's pre-existing
  Optional[X]-style findings are unrelated to this change)

Ref: SECFOO-6

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@vsn411
vsn411 merged commit ae289a8 into secfoo-com:main Oct 7, 2026
2 checks passed
@AmirNCI
AmirNCI deleted the feat/droid-devin-agents branch October 9, 2026 22:19
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.

2 participants