feat(miner-hands): wire CLI and Agent-SDK drivers into CodingAgentDriver factory - #4561
feat(miner-hands): wire CLI and Agent-SDK drivers into CodingAgentDriver factory#4561carlh7777 wants to merge 1 commit into
Conversation
… factory - Introduced `cli-subprocess` and `agent-sdk` as new provider options in the coding agent driver factory. - Enhanced `CODING_AGENT_DRIVER_CONFIG_ENV` to include configuration for the new drivers. - Implemented `createDefaultCliSubprocessSpawn` for lazy loading of the CLI subprocess. - Updated tests to validate the new driver configurations and their functionality. This change expands the capabilities of the coding agent by allowing integration with CLI subprocesses and an Agent-SDK, improving flexibility in coding agent operations.
|
🚨 Contributor flagged. Click here for more info: Superagent Dashboard |
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4561 +/- ##
=======================================
Coverage 94.08% 94.08%
=======================================
Files 427 427
Lines 37961 37972 +11
Branches 13864 13869 +5
=======================================
+ Hits 35715 35726 +11
Misses 1586 1586
Partials 660 660
🚀 New features to boost your workflow:
|
|
Caution 🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥 🛑 Gittensory review result - reject/close recommendedReview updated: 2026-07-10 03:01:15 UTC
🛑 Suggested Action - Reject/Close
Review summary Blockers
Nits — 5 non-blocking
Why this is blocked
Flagged checks (non-blocking)
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
|
Gittensory is closing this pull request on the maintainer's behalf (AI reviewers agree on a likely critical defect: driver-factory.ts declares `MINER_CODING_AGENT_CLI_MODEL`, `MINER_CODING_AGENT_SDK_MODEL`, and `MINER_CODING_AGENT_MAX_TURNS` in `CODING_AGENT_DRIVER_CONFIG_ENV` (lines 45-54), but `createCodingAgentDriver`'s switch (lines ~175-198) only reads `command`/`timeoutMs` for `cli-subprocess` and passes nothing but `query`/`hooks` to `createAgentSdkCodingAgentDriver`, so setting those model/maxTurns env vars has zero effect — dead, misleading config-as-code surface.). This is an automated maintenance action — to pursue this change, please open a new pull request with the issues resolved. Closed PRs may be analyzed later to improve review accuracy, but they are not automatically reopened or re-reviewed. |
Summary
createCodingAgentDriver, soMINER_CODING_AGENT_PROVIDERcan selectnoop | cli-subprocess | agent-sdk.src/selfhost/ai-config.ts: deny-by-default unknown names, per-provider config env map (CODING_AGENT_DRIVER_CONFIG_ENV), and injectedspawn/queryseams so CI never shells out or calls a real model.Closes #4289
Scope
type(scope): short summaryConventional Commit format, for examplefix(api): restore profile access checks.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Closes #123) — a linked open issue is required for every contributor PR.Validation
git diff --checknpm run actionlintnpm run typechecknpm run test:coveragelocally;codecov/patchrequires ≥99% coverage of the lines AND branches you changed (aim for 100% on your diff so CI variance does not fail near the threshold). Global coverage is a non-blocking trend with a loose 90% backstop, not the gate.npm run test:workersnpm run build:mcpnpm run test:mcp-packnpm run ui:openapi:checknpm run ui:lintnpm run ui:typechecknpm run ui:buildnpm audit --audit-level=moderateIf any required check was skipped, explain why:
npx vitest run test/unit/coding-agent-miner.test.ts(+ CLI/SDK driver suites), enginedriver-factorynode:test suite aftertsc,npm run typecheck,npm run docs:drift-check,npm run build:miner, andnpm audit --audit-level=moderate. Fullnpm run test:cinot finished in this environment (Windowsrmin engine test script / pack spawn quirks); CI will run the full gate on the PR.Safety
UI Evidencesection below with JPG/JPEG or PNG screenshots arranged as organized, captioned, clickable thumbnails. SVG screenshots are not used as review evidence. Review-only screenshots or recordings are not committed to the repository.UI Evidence
N/A — no visible UI/frontend/extension change.
Notes
CODING_AGENT_DRIVER_NAMESis now["noop", "cli-subprocess", "agent-sdk"].child_process/ SDK paths stay behind injected defaults (createDefaultCliSubprocessSpawn, Agent-SDK lazy import); tests always inject fakes.