Skip to content

Remote runtimes: analysis runs without a repository fail with "Cannot use simple-git on a directory that does not exist" (agent playground on Fly) #3893

Done

Description

@integry

Problem

On a Docker-less instance (Fly, with Sprites or Fly Machines runtimes), every analysis run without a repository fails immediately. For example, in the agent playground on propr-dev-3868, a signed-in Claude agent answering "hi" gives:

Cannot use simple-git on a directory that does not exist (14ms)

Cause: runtimes without bind mounts always use the clone workspace transport (resolveWorkspaceTransportMode → createWorkspaceTransport in packages/core/src/git/workspaceTransport.ts). CloneWorkspaceTransport.prepare (packages/core/src/git/workspaceCloneTransport.ts) opens spec.workspace.hostPath with git and requires a clean worktree with a commit. Analysis runs with no repository pass a scratch path that doesn't exist on the control plane and isn't a git repo:

  • ClaudeAgent.resolveClaudeAnalysisWorkspace → /tmp/claude-analysis
  • CodexAgent → /tmp/codex-analysis
  • AntigravityAgent → /tmp/an… (fallback when there's no read-only workspace)
  • OpenCodeAgent → /tmp/git-processor/opencode-analysis
  • PiAgent → /tmp/git-processor/pi-analysis
  • Vibe → mkdtemp('/tmp/vibe-analysis-'), which exists but isn't a git repository

Docker never hits this, because bind mounts the path and Docker creates it.

This breaks the agent playground and probably every other analyze() caller without a repository on Fly (task titles, summaries and similar lightweight analysis). Audit the callers.

Expected

An analysis run with no repository workspace runs on remote runtimes with an empty scratch working directory: no git checkout, nothing returned, no GitHub token minted.

Suggested shape (the implementer may choose another):

  • Mark such runs explicitly in the run spec, e.g. workspace.mode = 'none' or workspace.kind = 'scratch', instead of relying on a magic /tmp/*-analysis path.
  • Have the transport layer use a "none" transport for them that starts the run in an empty directory on the Sprite or Machine and has no complete step. On Docker, keep today's behavior.
  • Keep the existing refusals for real repository workspaces: a read-only workspace on clone and the start-as-root requirement.

Acceptance

  • Unit tests: for each agent (Claude, Codex, Antigravity, OpenCode, Pi, Vibe), analyze() with no repository on a runtime without bind mounts uses the no-workspace path and never calls git on the host path. Repository-backed runs still use clone.
  • Live on a Fly instance (Sprites): the playground returns an answer from a signed-in Claude and Codex agent. Any other no-repository analyze() caller found in the audit works too.
  • No change for Docker instances (existing tests).

Activity

  1. propr-dev commented on Nov 29, 2026

    @propr-dev
    Contributor

    🤖 AI processing has started for this issue using codex agent with gpt-6.2-sol model.

    I'll analyze the problem and work on a solution. This may take a few minutes.

    Processing Details:

    • Agent: codex
    • Model: gpt-6.2-sol
    • Branch: 3893/gpt-6.2-sol-remote-runtimes-analysis--20261129-2225-mj2
    • Base Branch: 3758-epic-runtime-abstraction-sc0
    • Worktree: issue-3893-20261129-2225-gpt-6.2-sol-mj2

    🔍 Track Task Execution

  2. integry commented on Dec 1, 2026

    @integry
    OwnerAuthor

    Done in #3894, which merged into the runtime epic; the epic merged into main with #3774 and ships in 0.9.4.

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions