Skip to content

Keep tracks under the disc directory and surface rip retry errors - #702

Open
ajzrva-sys wants to merge 2 commits into
whipper-team:developfrom
ajzrva-sys:feature/issue-692-template-paths
Open

ajzrva-sys wants to merge 2 commits into
whipper-team:developfrom
ajzrva-sys:feature/issue-692-template-paths

Conversation

@ajzrva-sys

@ajzrva-sys ajzrva-sys commented Sep 18, 2026 •

Copy link
Copy Markdown

A filename-only --track-template, such as %t. %n, can leave tracks outside the disc directory and make the rip fail.

Put those tracks beside the disc's cue and log files. Preserve explicit track directories under the disc directory, removing shared leading artist/album/disc components to avoid duplication. Create the track directory before ripping.

Resolve every audio destination before ripping, including HTOA. Reject duplicate destinations, case/Unicode aliases on the output filesystem, and unrelated existing audio or partial files. Create partial files exclusively and publish finished audio without replacing an existing destination.

Also show the exception from each failed attempt and include the last error when retries run out.

Includes temporary-filesystem and synthetic-metadata tests for hierarchy, relative/absolute paths, traversal, duplicate titles, existing files, filesystem aliases, default paths, and retry errors. Filename-limit correction in PR #706 remains separate.

Fixes #692

Checked 3ae13db on macOS arm64 / Python 3.11: 135 unit tests pass. Independent review: 23 focused tests pass, no blocking findings. Changed lines pass lint; repository-wide lint retains existing failures. No optical-drive test in this run.

When --track-template has no directory prefix matching --disc-template,
getPath() wrote tracks outside the disc folder (or failed on missing
parents) and the retry loop logged only debug lines, so the run looked
like a dead drive (issue whipper-team#692).

- common.align_track_path()/path_is_within(): place tracks under the
  disc output directory; create the track parent directory before ripping
- command/cd.py: warn on realignment; log each failed attempt at WARNING
  and include the last exception when giving up (pairs with whipper-team#681)
- Document the behaviour in --track-template help text

Signed-off-by: ajzrva-sys <ajzrva-sys@users.noreply.github.com>
Addresses whipper-team#692.
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.

Custom track template without directory prefix silently fails all rips — no error output

1 participant