You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Disk-space preflight for recordings and a storage report in doctor #354
Retention prunes only screenshots, frames and index sidecars (recordings and edits are never touched), doctor's storage reports only { home, homeExists }, and nothing checks free space before a capture (no statfs anywhere in src/). The default cap is 1 h, the maximum is 7 days, and every edit writes a new full file.
Where
src/utils/retention.ts:1-14, 66-70
src/tools/doctor.ts:43
src/tools/startRecording.ts:133-142
Impact
A long or forgotten recording on a nearly full drive fails partway with an ffmpeg write error, and SCREENCAST_HOME fills up over weeks with no tool that says how much space it uses.
Proposal
doctor: storage.freeBytes (fs.statfs on the home volume) and per-folder bytes for recordings/, edits/, screenshots/ and frames/, plus a problems entry below a threshold.
start_recording: estimate bytes from fps, quality and maxDurationSec, refuse with a clear error below a floor (or the estimate), and warn when near.
Optional: an opt-in SCREENCAST_MAX_HOME_GB, or delete_recording { olderThanDays, dryRun }.
5ea2b09 adds part 1: doctor's storage.freeBytes, per-folder bytes, and a problem below 2 GB free. Still open: part 2 (start_recording estimating the size from fps, quality and maxDurationSec and refusing or warning when free space is short) and the optional cap or bulk delete.
c097bfd: start_recording now checks free space on the output drive before spawning anything (nearest existing folder above the output): it refuses below 500 MB and returns a diskNote below 2 GB. Together with doctor's storage report from 5ea2b09 this covers points 1 and 2; the optional cap / bulk delete in point 3 is not done. Verified with unit tests in storage.test.ts and the full suite.
Activity
feat(doctor): report free space and what the store uses (#354)
TMHSDigital commentedon Nov 17, 2026
5ea2b09 adds part 1: doctor's
storage.freeBytes, per-folderbytes, and a problem below 2 GB free. Still open: part 2 (start_recording estimating the size from fps, quality and maxDurationSec and refusing or warning when free space is short) and the optional cap or bulk delete.TMHSDigital commentedon Nov 18, 2026
c097bfd: start_recording now checks free space on the output drive before spawning anything (nearest existing folder above the output): it refuses below 500 MB and returns a diskNote below 2 GB. Together with doctor's storage report from 5ea2b09 this covers points 1 and 2; the optional cap / bulk delete in point 3 is not done. Verified with unit tests in storage.test.ts and the full suite.