Skip to content

refactor(runtime): remove the opencode adapter and in-sandbox serve #66

Description

@FreshlyBrewedCode

Parent

#62

What to build

Remove the opencode-specific runtime (ADR 0013 §1, §4, §6).

  • Delete:
    • runtime/opencode-adapter.ts, extractOpencodeSignal;
    • lib/sandbox-config.ts and the opencode.json write;
    • AgentAdapter.prepareWorkspace and StartRunOptions.prepareWorkspace;
    • the @tanstack/ai-opencode, @tanstack/ai-sandbox and -local-process dependencies;
    • the .tanstack-projected-* and data/ ignores, if nothing else needs them.
  • Re-record the replay corpus with the ACP adapter, for both agents. The replay adapter
    takes signals from the recorded stream without opencode event names. Keep the old corpora only
    where a test needs historical opencode chunks, such as the SPA folding old logs.
  • Simplify agent-step.ts: rewrite the abort-chain commentary. Keep abortableIterable and
    AGENT_TEARDOWN_GRACE_MS only if the tests still need them.

Acceptance

  • bun run check and bun run test:e2e green.
  • No opencode serve or free-port code remains.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    taskA single self-contained piece of work that ships as one PR

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions