Skip to content

openenv/tbench2: drop the daytona bake CLI, which nothing can consume - #2136

Merged
nblintao merged 1 commit into
mainfrom
tao/openenv-drop-daytona-bake-cli
Aug 4, 2026
Merged

openenv/tbench2: drop the daytona bake CLI, which nothing can consume#2136
nblintao merged 1 commit into
mainfrom
tao/openenv-drop-daytona-bake-cli

Conversation

@nblintao

@nblintao nblintao commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

What

Deletes the named-snapshot bake CLI from examples/experimental/openenv/tb2_sandbox_daytona.py (snapshot_name, bake, main, the __main__ guard, and the three imports that existed only for them). Nothing else changes; the daytona rollout leg is untouched.

Why it can't be used

The per-task sandbox refactor made this leg declarative: an episode creates from an Image definition and the definition hash is the cache key. The bake CLI instead registers a named snapshot — and no create on this leg can reference one:

  • create_task_sandbox() passes CreateSandboxFromImageParams(image=...); consuming a snapshot needs the other param type, CreateSandboxFromSnapshotParams(snapshot=...) (daytona SDK 0.198.0).
  • It always will, because dodging the org-level snapshot quota is the stated reason the declarative path exists — our shared org has sat within two snapshots of its 500 ceiling.

So the "optional warm cache" in its docstring warms nothing the trainer touches. It burns quota and needs a live API key to do it.

Confirming nobody uses it

  • No caller in the repo: the only importers of the module are openenv_daytona_agent_function.py (make_daytona + create_task_sandbox) and the module's own tests, which cover labels / API-key resolution / TTL-keepalive and never bake.
  • Not documented: the openenv README covers the daytona leg's env vars and the e2b bake CLI, never this entry point — in any revision, on any branch.
  • Not in any runbook: grepped every remote branch's markdown plus my TB2 notes. The only other bake-style tooling is harbor's own, unrelated harbor/environments/daytona/snapshots.py.
  • Provenance: it landed in openenv/tbench2: per-task sandbox image recipe + Daytona materialization #1710 together with the declarative path — a carry-over of the pool era's named-snapshot habit, never wired up.

If we ever want to pre-warm this leg, it's one declarative create per task (the same path a rollout takes), not a snapshot registration. That's a separate change and not obviously worth it.

Test

pytest examples/experimental/openenv/tests/ → 21 passed, 1 skipped (this suite is outside the repo-level testpaths, so CI doesn't run it). ruff / black / isort clean.

Interaction with #1913

Independent change, so it's based on main. #1913 (open) rewrites the deleted main()'s argument parsing to use a shared recipe.add_task_selection_args; whichever lands first, the other's rebase drops that hunk, and #1913's helper docstring then wants the singular ("the e2b bake CLI's task selection") since e2b becomes its only caller.

🤖 Generated with Claude Code

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

The per-task sandbox refactor made the daytona leg declarative: every
episode creates from an ``Image`` definition, and the definition hash IS
the cache key. The bake CLI shipped alongside it registers *named
snapshots* instead, and nothing on the create path can reference one —
that needs ``CreateSandboxFromSnapshotParams(snapshot=...)``, while
``create_task_sandbox`` passes ``CreateSandboxFromImageParams(image=...)``
and always will, because avoiding the org-level snapshot quota is the
reason the declarative path exists. So the "optional warm cache" the
CLI advertises never warms anything the trainer touches; it only spends
quota (the shared org has run within two of its 500-snapshot ceiling),
and it needs a live API key to do it.

No caller, no test, no doc, and no runbook references it: the README
documents the daytona leg's env vars and never this entry point.
Warming the daytona leg, if ever wanted, is one declarative create per
task — the same code path a rollout uses — not a snapshot registration.

Verified with the openenv example suite (21 passed, 1 skipped;
``pytest examples/experimental/openenv/tests/``), which is not in the
repo-level testpaths.
@nblintao
nblintao force-pushed the tao/openenv-drop-daytona-bake-cli branch from b088ef7 to 1776d14 Compare August 3, 2026 23:59
@nblintao
nblintao requested a review from Shi-Dong August 4, 2026 02:40

@Shi-Dong Shi-Dong left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@nblintao
nblintao merged commit 40e0287 into main Aug 4, 2026
74 of 75 checks passed
@nblintao
nblintao deleted the tao/openenv-drop-daytona-bake-cli branch August 4, 2026 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants