Skip to content

Comments

fix(importer): ignore persistent .nzbs path in virtual directory calculation#220

Merged
javi11 merged 1 commit intojavi11:mainfrom
drondeseries:fix/importer-ignore-nzbs-path
Jan 5, 2026
Merged

fix(importer): ignore persistent .nzbs path in virtual directory calculation#220
javi11 merged 1 commit intojavi11:mainfrom
drondeseries:fix/importer-ignore-nzbs-path

Conversation

@drondeseries
Copy link
Contributor

This PR fixes an issue where the internal persistent storage directory '.nzbs' was being exposed in the virtual mount path when NZB files were moved to persistent storage.

Changes:

  • Core Logic: Modified 'CalculateVirtualDirectory' in 'internal/importer/filesystem/utils.go' to filter out '.nzbs' segments from the path calculation.
  • Cleanup: Removed the redundant (and slightly buggy) manual fix in 'internal/importer/service.go' as it's now handled natively by the filesystem utility.
  • Tests: Added a new test case to 'internal/importer/processor_test.go' to ensure '.nzbs' is correctly ignored and prevent future regressions.

Verified with 'go test ./internal/importer/...' and all tests passed.

…ulation

- Updated CalculateVirtualDirectory to filter out '.nzbs' segments from the path.
- Removed redundant logic in importer service that was previously used as a workaround.
- Added test case to verify the fix and prevent regressions.

This ensures that while NZB files are stored in a persistent .nzbs directory for stability, this implementation detail is not exposed in the virtual mount path.
@javi11 javi11 merged commit 8ded48e into javi11:main Jan 5, 2026
1 check passed
@drondeseries drondeseries deleted the fix/importer-ignore-nzbs-path branch February 5, 2026 20:09
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.

2 participants