Skip to content

Fix ODF loading through symlinked OrganDefinitions on macOS - #31

Merged
bonninr merged 2 commits into
bonninr:mainfrom
vpoguru:fix/macos-symlinked-organ-definitions
Sep 23, 2026
Merged

bonninr merged 2 commits into
bonninr:mainfrom
vpoguru:fix/macos-symlinked-organ-definitions

Conversation

@vpoguru

@vpoguru vpoguru commented Sep 23, 2026

Copy link
Copy Markdown
Contributor

Fixes #12.

On macOS, selecting an ODF through the native file chooser can return the resolved physical path when OrganDefinitions is a symlink. This loses the logical relationship to the sibling OrganInstallationPackages directory.

This change restores the logical ODF path through known Hauptwerk library roots before deriving the organ root. The reconstructed path is then used for loading, settings, cache identity, and lastorgan.

The issue was reproduced with:

  • normal ODFs with audio
  • an artwork-only development ODF with no audio samples
  • switching repeatedly between ODFs
  • reopening the last organ after restart
  • a symlink whose target directory is not named OrganDefinitions

Regression coverage was added to functional.loader.symlinked-organ for the resolved-path case.

Test status:

  • functional.loader.symlinked-organ passes with the new regression check - functional.settings.master-gain still fails, but the identical failure is reproducible on unmodified main and is unrelated to this change

Native macOS file selection resolves paths through a symlinked
OrganDefinitions directory before returning the selected ODF.

Restore the logical ODF path through known Hauptwerk library roots before
deriving the organ root. This preserves the relationship between
OrganDefinitions and OrganInstallationPackages and also ensures that the
logical path is stored as the last opened organ.

Add regression coverage for a resolved ODF path underneath a symlinked
OrganDefinitions directory.
@bonninr

bonninr commented Sep 23, 2026

Copy link
Copy Markdown
Owner

Thank you for this, and for the detailed reports behind it. I will review it alongside the other work on the project.

@vpoguru

vpoguru commented Sep 23, 2026

Copy link
Copy Markdown
Contributor Author

I tried to find a fix because v0.5.4 still did not work. Same issue as before: OrganInstallationPackage could be moved and symlinked, OrganDefinitions not.

The root is now derived after the logical path is restored, so the comment
explaining deriveOrganRoot moves down to that line, and the restoration gets
a comment of its own. Wrapping follows the rest of the file. No change in
behaviour.
@bonninr
bonninr merged commit 6030e11 into bonninr:main Sep 23, 2026
6 checks passed
@vpoguru
vpoguru deleted the fix/macos-symlinked-organ-definitions branch September 24, 2026 12:19
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.

Feature Request: Support for Symbolic-Linked Folders on macOS

3 participants