Repository navigation
Description
Priority
high by depth: run folders, caches and builds belong to the execution backend and the workspace store. P2 is set: a missing feature; disk use only grows, and the way around it is deleting folders by hand.
Components
- app/nullius (backend)
- app/web (routes)
- templates and static files
- docs and the site
- catalogue (benchmarks, agents, capabilities)
- the standard (ports, kits, relay, runs)
- CI, workflows and skills
Today
On main 3347bf3, nothing removes:
- the folders of ended runs under the runs folder, with their
nullius.log, unless a launch is deleted one by one (feat(runs): delete a launch that has ended #156); - a workspace's parsed-job cache files
<workspace>/jobs/<digest>.jsonof jobs no longer on disk (app/nullius/workspace.py, lines 492-504); refreshing a workspace (clear_cache, line 572, fromopen_workspace(refresh=True),app/web/shared.py, line 307) removes all of them, the live ones too. Measured on main: a job deleted on disk, then its root removed from the workspace, still leavescache files: 2of 2; - built Harbor pins under
harbor-pins/no recipe names any more (app/nullius/harbor/source.py, line 143); - lock files under
<cache>/locks/(app/nullius/standard/contract/definitions.py, lines 1897-1901) and the standard's snapshots under<cache>/standard-app.
The relay's key folders are the one thing removed when stale (container.forget_stale_keys, app/nullius/standard/backends/container.py, line 1890).
Wanted
Pruning on request, which never removes anything a user still needs: no running or resumable run, no job a workspace still lists, no judgement, no pin a saved recipe or a live run names.
Open question for the owner: what is pruned (ended runs older than a given age, or chosen ones; orphan caches; unused pins and snapshots), when (only on request, or also offered at start), and on whose request (a Settings action, a CLI command, or both). Nothing is pruned automatically until that is decided.
Acceptance
- An action prunes on request and says, before removing anything, what it will remove and how much space that frees.
- A cache file whose job is no longer on disk is removed; a live job's cache file is kept (test).
- A running, resumable or recently ended run's folder is never removed (test).
- A Harbor pin named by a saved recipe or a live run is kept (test).
- Judgements are never removed by pruning.
- Nothing is removed without a request.
Dependencies and related
#358 (stale index entries and cache files of jobs no longer on disk), #360 (the run folder's files), #156 (deleting a launch), #362 (judgements).
Activity