Conversation
…e timeout for long-running poller Co-Authored-By: @drone <drone@aipass>
… --rebase to prevent dirty-tree abort Co-Authored-By: @drone <drone@aipass>
…pps/integrations/** with README negation, plus scaffold README.md in all 10 core branches' apps/integrations/ — private integration space is now leak-proof by construction. Drivers and wrappers dropped here stay local; only README.md is tracked. See DPLAN-0133 for architecture rationale (three-layer design: @api drivers, per-branch wrappers, public generic contracts). Co-Authored-By: @devpulse <devpulse@aipass>
…affold to builder template Every new branch spawned via `drone @Spawn create` now lands with `apps/integrations/README.md` — the private integration space introduced in DPLAN-0133. The README explains the three-layer architecture (api driver → branch wrapper → public contracts) and is the only tracked file in the folder; everything else dropped there is gitignored by the root rule shipped in PR #289. Changes: - templates/builder/apps/integrations/README.md — new scaffold file - templates/builder/.spawn/.template_registry.json — regenerated (44→45 files, 23→24 dirs) - tests/test_citizen_classes.py — new test asserting integrations/ exists after create; added missing docstrings to 14 test methods - .seedgo/bypass.json — added architecture + encapsulation bypasses for test_citizen_classes.py (standard test-file exemptions) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…o-discovery + integrations handlers
Implements the @api side of the three-layer private-integration architecture
(DPLAN-0133). Branches call generic contracts; @api resolves them at runtime
to whatever private driver is registered locally.
New modules:
apps/modules/bridge.py — module-level dict registry (register/resolve/list_contracts/clear)
apps/modules/registry.py — auto-discovery walker for apps/integrations/*/driver.py
apps/modules/integrations_manager.py — drone @api integrations {list,call} command routing
apps/handlers/integrations/list.py — handler: log + return contract listing
apps/handlers/integrations/call.py — handler: invoke driver, return result dict
apps/integrations/testcontract/driver.py — canary driver (contract "test" → "pong", gitignored)
tests/test_integrations.py — 17 tests (bridge, registry, fetch_contracts, call_contract)
All 306 existing tests remain green. Empty integrations/ exits 0 cleanly.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
@api just pushed Phase 2 onto this branch. PR #290 is now the complete DPLAN-0133 Phase 1 + Phase 2 delivery (+1411 -9). Full PR #290 contents:
Acceptance per @api's reply:
One design note from @api: handlers can't import bridge directly per seedgo's cli/handlers rule, so they went with module-layer orchestration — Merge strategy: PR #290 is now the strict superset of #288 and #289 AND Phase 2. Merging #290 alone delivers everything. Close #288 and #289 as superseded. — devpulse |
…bled Try: prefix Found via stress testing DPLAN-0133 Phase 2: - `drone @api integrations foobar` returned exit 0 (success) instead of 1 - Error message showed "Try: Try: list, call" (doubled prefix) Two-line fix: suggestion string drops "Try:" prefix (error() adds it), return True → sys.exit(1) for proper non-zero exit. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Stress test complete — 2 bugs found and fixed (pushed to this branch) Tested with 4 test drivers: multi-contract (memory/search/explode), broken import, no register() hook, empty folder. Bug 1 (fixed, commit 5ab2a99): Bug 2 (fixed, same commit): Error message showed 'Try: Try: list, call' — doubled prefix because What passed clean (no bugs):
Verdict: Phase 2 is solid. Two minor bugs in error handling, now fixed. Core architecture (bridge registry, auto-discovery, contract dispatch) works correctly under stress. — devpulse |
Summary
Phase 1 (part 2/2) — spawn template scaffold
apps/integrations/README.mdto the builder template so every branch spawned withdrone @spawn createautomatically gets the private integration scaffold introduced in DPLAN-0133.test_citizen_classes.pyassertsapps/integrations/README.mdexists after_spawn_agent().Phase 2 — @api driver registry + generic contract system
register/resolve/list_contracts/clear); zero side-effects on importload_drivers()walksapps/integrations/*/driver.pyviaimportlib; handles empty dirs, missingdriver.py, and broken imports gracefully (logs WARNING, skips, no crash); idempotent via_loadedflagdrone @api integrations listanddrone @api integrations call <contract> [args...]"test"→"pong"Test plan
drone @api integrations listwith emptyapps/integrations/→ "No integrations configured", exit 0drone @api integrations liston this branch → showstest(canary driver)drone @api integrations call test→ printspong, exit 0drone @api integrations call nope→ error message, exit 1python -m pytest src/aipass/api/tests/— 306 existing + 17 new = 323 passed, zero regressionspython -m pytest src/aipass/spawn/tests/— 215 passed, 37 skippedDo not merge — user reviewing end of day.
🤖 Generated with Claude Code