Skip to content

fix: 🐛 Explain invalid capture directory paths - #80

Merged
oxspan merged 2 commits into
developfrom
feature/75
Nov 11, 2026
Merged

oxspan merged 2 commits into
developfrom
feature/75

Conversation

@oxspan

@oxspan oxspan commented Nov 11, 2026 •

Copy link
Copy Markdown
Owner

Why

Path typos during offline inspection could look like damaged captures. New capture destination errors used the same message as transport failures.

Refs #75

Changes

  • Give actionable messages for missing or invalid capture paths, occupied destinations, and missing or invalid parents. Apply them to both transaction capture formats and resume.
  • Detect a regular file anywhere in the supplied parent path, including descendants of that file. Preserve unrelated filesystem failures as I/O errors.
  • Keep creation atomic, with the parent and destination under the user's control. Existing captures and their integrity checks are preserved.

Validation

  • Linux: 231 tests passed. Coverage was 95.34% line and 80.18% branch. Release input checks passed.
  • Extended the existing CLI regression cases for file ancestors at two depths; all three test declarations failed before the correction and passed afterward.
  • Ran 30 cases through the packaged Linux CLI using a loopback Collector fixture for online capture and no credentials for offline inspection. Verified new capture/resume path errors in both formats, existing-file preservation, successful capture/inspection, a corrupt page, and preservation of genuine filesystem I/O errors.
  • CI passed for commit 6992741.

Compatibility and risks

These path errors now return INVALID_ARGUMENT (exit 2). A missing manifest in an existing bundle, a damaged page, and genuine filesystem I/O failures still return IO_ERROR (exit 10). Capture formats are unchanged. Native Windows execution is not included in this PR's local validation.

@github-actions

github-actions Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Linux CI: success · Commit 6992741

Test results (Linux)

Total Passed Failed Errors Skipped
231 231 0 0 0

Test coverage

Metric Covered / total Coverage Minimum Result
LINE 2089 / 2191 95.34% 90.00% PASS
BRANCH 1242 / 1549 80.18% 80.00% PASS

Includes the test JVM and CLI subprocesses. Excludes optional real-Collector smoke tests.

Workflow logs and report artifacts

Updated on each CI run. Windows checks, when required, are reported separately in the workflow.

@oxspan
oxspan merged commit 53d4c1b into develop Nov 11, 2026
6 checks passed
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.

1 participant