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
fix(capture): explain macOS -3821 stops caused by low disk space - #1497
When macOS ends a take with SCStreamErrorDomain -3821 ("Stream was stopped by the system"), the warning used to quote the raw NSError. It now names the likely cause:
recordings volume under 15 GB free: "macOS stopped the recording because the disk is almost full (8.5 GB free). Free up space and record again. The part recorded until then was saved."
otherwise, or when free space can't be measured: "macOS stopped the recording. The part recorded until then was saved."
Free space comes from statfs on the recording's folder, no native change. Other interruptions keep their existing message. The pre-recording HUD warning and an automatic stream restart (points 2 and 3 of the issue) are left out on purpose: they are product calls.
Tests: npx vitest --run electron/recording (163 passed), both typechecks, npm run lint.
Improved warnings for recordings stopped by macOS when the destination drive is low on space. When less than 15 GB is available, the warning now reports the estimated free space and recommends freeing space.
When space is sufficient or cannot be measured, a general macOS-stopped warning is shown. Other interruption warnings continue to include their reason.
No actionable comments were generated in the recent review.
Walkthrough
The macOS recording stop outcome now checks available disk space for ScreenCaptureKit error -3821. It reports a disk-space warning below 15,000,000,000 bytes and a general stop warning when space is sufficient or cannot be measured. Other interruption reasons remain in the warning.
The stop outcome measures available space beside the output file. For error -3821, it reports available GB below the threshold and uses a general stop warning otherwise. Tests cover low, sufficient, and unavailable space.
Issue 1496 reports recordings stopping with error -3821 when disk space is low. This PR changes the warning and reports available space; the requested pre-recording warning and recovery are outside its scope.
Possibly related PRs
getopenscreen/openscreen#1388: This PR also changes the recording warning, adding a Presenter Overlay camera interruption description.
Merge Risk: Minimal · up to 17a61
The warnings distinguish low disk space from other macOS stops while preserving the generic fallback when space cannot be measured. No concrete merge-blocking risk was established.
Pre-merge checks: 5
Check name
Status
Explanation
Title check
The title clearly describes the low-disk warning for macOS -3821 stops.
Description check
The description covers the change, related issue, scope, and testing. Add the template headings and specify the change type, release impact, and desktop impact. Add screenshots or video if applicable.
Docstring Coverage
Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage
Explanation
Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 3 functions across 2 files.
Finishing Touches
Generate docstrings
Commit to this branch
Create a new PR
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
File: No configuration file from this repository applied
Commit: Unavailable
Layers: defaults
Review profile: CHILL
Plan: Advanced
Run ID: f8c0c5a7-d906-40c0-ba75-a68838d8d5ad
Commits
Reviewing files that changed from the base of the PR and between bc8d0a0 and 17a61e5.
Files selected for processing: 2
electron/recording/nativeMacCaptureStop.test.ts
electron/recording/nativeMacCaptureStop.ts
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.
This branch has not been deployed
No deployments
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Refs #1496
When macOS ends a take with
SCStreamErrorDomain -3821("Stream was stopped by the system"), the warning used to quote the raw NSError. It now names the likely cause:Free space comes from
statfson the recording's folder, no native change. Other interruptions keep their existing message. The pre-recording HUD warning and an automatic stream restart (points 2 and 3 of the issue) are left out on purpose: they are product calls.Tests:
npx vitest --run electron/recording(163 passed), both typechecks,npm run lint.🤖 Generated with Claude Code
Summary by CodeRabbit