Skip to content

fix: report dropped segments when sanitizing folder paths#218

Merged
fuzzzerd merged 1 commit into
masterfrom
fuzzz/repository-sanitize-diagnostics
May 20, 2026
Merged

fix: report dropped segments when sanitizing folder paths#218
fuzzzerd merged 1 commit into
masterfrom
fuzzz/repository-sanitize-diagnostics

Conversation

@fuzzzerd
Copy link
Copy Markdown
Owner

Summary

  • ClipRepository.SanitizeFolderPath now logs Log.Warn naming the dropped segments and what was kept whenever it discards ./../whitespace segments.
  • New FolderPathSanitized event on ClipRepository carries the original path, the sanitized path, and the dropped segments.
  • MainWindowViewModel.SaveClipsStorageAsync subscribes around the save and appends ; sanitized N folder path(s) — see log for dropped segments to the final status when sanitization fired, so plugin-driven or user-typed placements that landed somewhere unexpected are visible.
  • Percent-encoded segments (e.g. Date/Time) do not trigger the warning — that's a reversible round-trip, not a drop.

ClipRepository.SanitizeFolderPath now logs a warning naming the
dropped segments and what was kept, and raises FolderPathSanitized
so the host can surface a non-blocking notice. The save flow in
MainWindowViewModel captures these notices and appends a sanitized
suffix to the final status, so programmatic placements that landed
somewhere other than requested are visible to the user.
@github-actions
Copy link
Copy Markdown

Test Results

✔️ Tests 1417 / 1417 - passed in 18s
✔️ Coverage 79.38% - passed with 70% threshold
📏 15239 / 17662 lines covered 🌿 5164 / 8042 branches covered
🔍 click here for more details

✏️ updated for commit 3ca406c

@fuzzzerd fuzzzerd merged commit d6e2aff into master May 20, 2026
6 checks passed
@fuzzzerd fuzzzerd deleted the fuzzz/repository-sanitize-diagnostics branch May 20, 2026 02:08
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