Skip to content

fix: wrong permissions directory#6172

Open
krisfremen wants to merge 4 commits intoZettlr:developfrom
krisfremen:kris/fix-permissions
Open

fix: wrong permissions directory#6172
krisfremen wants to merge 4 commits intoZettlr:developfrom
krisfremen:kris/fix-permissions

Conversation

@krisfremen
Copy link

Description

Fixes an issue with zettlr crashing upon startup because of an unhandled exception when accessing a directory that current use doesn't have permissions towards.

Changes

List directories that aren't accessible as dirNotFoundFlag-ed

Additional information

Fixes #6162

Tested on: openSUSE Tumbleweed, PopOS

@boring-cyborg
Copy link

boring-cyborg bot commented Feb 11, 2026

Thank you for opening your first PR! 🎉 We would like to thank you already for your contribution. If everything checks out, we'll make sure to review the PR as soon as possible and give feedback. Please note a few things:

  • For every PR, the automated pipeline will run the linter and unit tests on
    your code. Should these fail, we will not merge your PR.
  • Activate your notifications and check your inbox regularly to respond to our
    reviews and/or comments.

We are glad for every improvement that makes its way into the app, so we look forward to collaborating on merging this PR.

@nathanlesage
Copy link
Member

This looks fine in principle! There's just a merge conflict now because I merged the dot-file PR just now. But that should make the PR a bit cleaner I guess, since it only involves a few try/catch instances, no?

Aside of that, I'm curious — does this finally re-enable the "DirNotFound" descriptor functionality in the file tree? I implemented that years ago due to a request by someone who had their workspaces on a USB key and who sometimes forgot to plug it in before starting Zettlr. At some point, that got lost (and I never really understood why)…

@krisfremen
Copy link
Author

This looks fine in principle! There's just a merge conflict now because I merged the dot-file PR just now. But that should make the PR a bit cleaner I guess, since it only involves a few try/catch instances, no?

Aside of that, I'm curious — does this finally re-enable the "DirNotFound" descriptor functionality in the file tree? I implemented that years ago due to a request by someone who had their workspaces on a USB key and who sometimes forgot to plug it in before starting Zettlr. At some point, that got lost (and I never really understood why)…

Resolved the merge conflict.

Indeed, it does bring back the DirNotFound descriptor.
Upon further testing though, it seems like the "Check for directory" rescan isn't implemented.
I haven't tried out the workspace on a USB key, but I can test that out too.

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.

Zettlr won't start if workspace contains directory that's not accessible by user running Zettlr

2 participants