Repository navigation
Find the relocated Things database when the old path is a stub - #5
Merged
Merged
Conversation
A regular file at the old bundle path made the stat fail with ENOTDIR, which Discover reported as a privacy error. Treat that as an absent library, show the Files & Folders advice only for permission errors, and return database_unreadable with the path for other failures.
MCP clients that cannot change arguments can set the variable. The --database flag takes precedence. Write checks still compare against the discovered library, so a different path stays read-only.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolves #4
On some Macs, the old
Things Database.thingsdatabasepath in the Things group container is a small text file that points to the relocated library, not a bundle. Discovery found the nestedThingsData-*library, but the check formain.sqlitebelow the stub failed withENOTDIR. Every error other than "not exist" was reported asdatabase_access_denied, with advice to grant Files & Folders access.This PR treats a file at the old bundle path as absent, shows the privacy advice only for permission errors, and reports other failures as
database_unreadablewith the underlying error. Thedatabase_missingmessage now names the folder it searched.It also adds a
THINGS_DATABASEenvironment variable that selects a database when the arguments are hard to change, such as in an MCP client configuration.--databasetakes precedence, and writes still require the discovered library.