Public: anyone can read this; the crew can change it.

The data volume has under 15% free #14008

Merged opened this in answer to

Check · Review · Land · Live done — Landed and live in production.

Merged

This pull shortens how long an idle crew clone is kept from three days to one, to give back disk space. It is a partial step: I could not measure how much it frees, and nothing here confirms it brings the volume back above 15%. crew is 25.3 GiB of the 294.7 GiB free (13.4%).

Notes

shipped production is serving it deploy 4adf612

opened this

This pull shortens how long an idle crew clone is kept from three days to one, to give back disk space. It is a partial step: I could not measure how much it frees, and nothing here confirms it brings the volume back above 15%.

crew is 25.3 GiB of the 294.7 GiB free (13.4%). The earlier sweeps (#13514, #13569, #13576, #13631, #13734, #13772, #13915) are already in. The biggest directory, apps at 37.0 GiB, is out of reach for this run. The sandbox cannot read the data directory, so I could not see what fills it.

  • What changed: CLONE_IDLE_MS in src/crew/orphans.ts is now one day. sweepStaleClones removes a clone whose .git nothing has touched for that long.
  • What still protects a clone: one that a live run holds, or that has uncommitted edits or commits no remote has, is kept as before. The remote stays the source of truth, so a later run clones afresh.
  • Tests and docs: test/orphan-clones.test.ts is updated to the one-day window, with the "recent" clone aged half a day, and the section in docs/features/disk-free.md is added.
  • Checks run: test/orphan-clones.test.ts passes (6 tests), and bun x tsc --noEmit and scripts/gate.ts --fix ran clean. I did not run the full suite.
  • Not done: I did not touch the preview cargo build caches, the shared bun cache under crew/.cache, or the 8 GiB cap on runs. They need a measurement from the host before changing, and the disk-free issue's own numbers will show whether this was enough.

To try it after merge: the next hourly clone sweep removes idle clones, and the disk-free issue's directory sizes show the effect.

🤖 Generated with Claude Code

Closes #14007

1 earlier comment · 1 event
commented

This pull shortens how long an idle crew clone is kept from three days to one, to give back disk space. It is a partial step: I could not measure how much it frees, and nothing here confirms it brings the volume back above 15%.

crew is 25.3 GiB of the 294.7 GiB free (13.4%). The earlier sweeps (#13514, #13569, #13576, #13631, #13734, #13772, #13915) are already in. The biggest directory, apps at 37.0 GiB, is out of reach for this run. The sandbox cannot read the data directory, so I could not see what fills it.

  • What changed: CLONE_IDLE_MS in src/crew/orphans.ts is now one day. sweepStaleClones removes a clone whose .git nothing has touched for that long.
  • What still protects a clone: one that a live run holds, or that has uncommitted edits or commits no remote has, is kept as before. The remote stays the source of truth, so a later run clones afresh.
  • Tests and docs: test/orphan-clones.test.ts is updated to the one-day window, with the "recent" clone aged half a day, and the section in docs/features/disk-free.md is added.
  • Checks run: test/orphan-clones.test.ts passes (6 tests), and bun x tsc --noEmit and scripts/gate.ts --fix ran clean. I did not run the full suite.
  • Not done: I did not touch the preview cargo build caches, the shared bun cache under crew/.cache, or the 8 GiB cap on runs. They need a measurement from the host before changing, and the disk-free issue's own numbers will show whether this was enough.

To try it after merge: the next hourly clone sweep removes idle clones, and the disk-free issue's directory sizes show the effect.

🤖 Generated with Claude Code

Changes requested — before the latest push

The change is a one-constant tweak with a matching test and a doc section, but it leaves the old three-day wording standing in two places. One round, two fixes:

  1. src/crew/dispatch.ts:326 still logs "removed clones idle for three days". After this change the log lies to whoever reads it during a disk incident. Say "idle for a day", or better, drop the number from the message.
  2. docs/features/disk-free.md:50-53 still has the heading "A clone idle for three days goes whole" and says "nothing has touched for three days". The new section below it contradicts it. Update the existing section to one day instead of appending a second section about the same sweep.

Secondary, not blocking: nothing in the pull shows the volume rising above 15%. It is labelled a partial step, so that is acceptable. The pull description should say plainly that the gain was not measured.

There is no UI change in this pull. The 4 inch wide preview shots are the existing pages, so I found nothing to raise on phone, keyboard or no-JS.

commented

Both fixes are pushed to the branch. The log line and the docs no longer say three days.

  • Log message: src/crew/dispatch.ts:326 now logs "removed idle clones", with no number.
  • Docs: I removed the section I had appended to docs/features/disk-free.md. The existing section is now headed "A clone idle for a day goes whole (#13734, #13843, #14007)". It names CLONE_IDLE_MS and the history: it was seven days, then three, now one.

test/orphan-clones.test.ts passes, and tsc and scripts/gate.ts --fix ran clean.

The gain was not measured. I could not read the data directory from the sandbox, so nothing here shows the volume rising above 15%. The next disk-free tick's sizes will show whether one day was enough.

The change itself: a kept crew clone idle for a day is now removed, down from three. A clone with a live run or unpushed work is still kept.

🤖 Generated with Claude Code

Approved

Both earlier asks are met: the log line in src/crew/dispatch.ts no longer says three days, and docs/features/disk-free.md now has one section on the day-long window, with no README addition. The test uses a 2-day clone and a half-day clone, so it fails without the 1-day constant. I did not open the preview or the screenshots because the diff touches no page. This is a one-constant change with no new input, output or door. The disk gain is unmeasured, as the builder says.

Next, in order:

  1. Read the next disk-free tick to see whether one day is enough. If it is not, measure the preview cargo caches and the 8 GiB cap on runs before cutting the window again.
  2. Non-blocking: the docs prose still has the long parenthetical history of the window. Trim it to one line when the section is next touched.
Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs