8000 T43 — Run a task as a task box that returns its exit code · Issue #2405 · gominimal/minimal · GitHub
[go: up one dir, main page]

Skip to content

T43 — Run a task as a task box that returns its exit code #2405

Closed

Description

@mitodrummer

Task

slice size difficulty model who estimated lines
Tasks leave exited boxes L needs care strongest an agent 740 (440 code, 300 tests)

min task run returns the exit code and keeps the box.

Covers:

  • BOX-015
  • BOX-038

Layers:

  • client:
    • crates/minimal/src/task.rs: task box from spec; exit code
    • crates/minimal/src/cmd/boxes/create.rs: shared create path
    • crates/minimal/src/cmd/boxes/lifecycle.rs: run keeps its box
    • cargo nextest run -p minimal task_run_returns_the_entrypoint_exit_code
  • daemon:
    • crates/minimald/src/exec/run.rs: old task path, one release
    • crates/minimald/src/exec/process.rs: task is the entrypoint
    • crates/minimald-rpc/src/exec.rs: old request, one release
    • crates/minimald/src/box_actor/host.rs: launch runs the spec argv; drop run_by_exec
    • crates/minimald/src/box_runtime/launcher.rs: entrypoint launches the argv, not the shell
    • cargo nextest run -p minimald daemon_never_stops_for_idle_or_client_loss
    • cargo nextest run -p minimald until_complete_ends_on_entrypoint_return_without_client

Widened by the maintainer (2026-11-03): the launch flip needs box_actor/host.rs (run_by_exec: true) and box_runtime/launcher.rs; both files' comments name this task as the one that removes the interim flag.

Split by the maintainer (2026-11-03): relaying the task's exit code and inputs through the in-box helper (env.rs, env_min_helper.sh) is T62 (#2953). This task waits on it, then switches the launch to the entrypoint.

Waits on:

Plan block
### T43 — Run a task as a task box that returns its exit code
  slice: S2
  kind: task
  covers: BOX-015, BOX-038
  size: L
  est: 440 code, 300 tests
  executor: agent
  difficulty: needs care
  model: strongest
  diagnostics: daemon log names each task box and its code
  observability: one span per task run
  layers:
    - client:
      - crates/minimal/src/task.rs: task box from spec; exit code
      - crates/minimal/src/cmd/boxes/create.rs: shared create path
      - crates/minimal/src/cmd/boxes/lifecycle.rs: run keeps its box
      test: cargo nextest run -p minimal task_run_returns_the_entrypoint_exit_code
    - daemon:
      - crates/minimald/src/exec/run.rs: old task path, one release
      - crates/minimald/src/exec/process.rs: task is the entrypoint
      - crates/minimald-rpc/src/exec.rs: old request, one release
      - crates/minimald/src/box_actor/host.rs: launch runs the spec argv; drop run_by_exec
      - crates/minimald/src/box_runtime/launcher.rs: entrypoint launches the argv, not the shell
      test: cargo nextest run -p minimald daemon_never_stops_for_idle_or_client_loss
      test: cargo nextest run -p minimald until_complete_ends_on_entrypoint_return_without_client
  produces: none
  consumes: none
  proof: `min task run` returns the exit code and keeps the box.
  depends on:
    - blocked by #2401
    - blocked by #2398
    - blocked by #2953

Activity

  1. added
    kind:taskA task the plan skill rendered; the body carries ## Task
    size:L500 to 900 net lines; one PR, and the ceiling
    model:strongestThe strongest model available: unknown ground, or large work that needs care
    on Oct 19, 2026
  2. mitodrummer commented on Nov 2, 2026

    @mitodrummer
    MemberAuthor

    From the #2841 (T42) review: SandboxLauncher::launch's Argv branch (crates/minimald/src/box_runtime/launcher.rs) sets no SHELL/PS1 and skips the per-attach environment that the shell branch delivers through ATTACH_ENV_BASH_RC. Today nothing reaches it in production, because run_by_exec is always true. When this task makes the task the box's entrypoint and removes run_by_exec, give an argv entrypoint the attach environment too, through the process env rather than a bash rcfile.

  3. minimal-foundry commented on Nov 3, 2026

    @minimal-foundry
    Contributor

    Done. #2999 merged.

    branch agent/2405-run-a-task-as-a-task-box-that-returns-its-exit-c · epic #2236 · PR #2999

    round outcome job
    1 pushed e27591d0
    2 pushed d6c9b59e
    3 pushed 28b49472
    4 pushed 81d59e19
    5 pushed 8d6d0599
    6 pushed 89a800f5
    7 pushed 041df101
    8 pushed 2d778d14
    9 pushed d5697b4e
    9 pushed 85802268
    1 failed: push: 1 commit(s) were pushed to agent/2405-run-a-task-as-a-task-box-that-returns-its-exit-c while this round ran (5c6c53b) and merging them conflicted in crates/minimald/src/exec/process.rs. Not 9137bd32

    Updated 2026-11-06T01:31:47.488Z.

  4. added
    needs-humanAn agent handed off; a human must act, then clear this label. Set by defer and handoffs.
    on Nov 3, 2026
  5. removed
    needs-humanAn agent handed off; a human must act, then clear this label. Set by defer and handoffs.
    on Nov 3, 2026
  6. added
    needs-humanAn agent handed off; a human must act, then clear this label. Set by defer and handoffs.
    on Nov 3, 2026
  7. removed
    needs-humanAn agent handed off; a human must act, then clear this label. Set by defer and handoffs.
    on Nov 3, 2026
  8. added
    needs-humanAn agent handed off; a human must act, then clear this label. Set by defer and handoffs.
    on Nov 5, 2026
  9. removed
    needs-humanAn agent handed off; a human must act, then clear this label. Set by defer and handoffs.
    on Nov 6, 2026
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

    kind:taskA task the plan skill rendered; the body carries ## Taskmodel:strongestThe strongest model available: unknown ground, or large work that needs caresize:L500 to 900 net lines; one PR, and the ceiling

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0