Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle symlinks in nodes_path or classes_path as separate entities #26

Merged
merged 2 commits into from
Sep 12, 2023

Conversation

simu
Copy link
Member

@simu simu commented Sep 12, 2023

We introduce function to_lexical_absolute() which converts a Path into its normalized absolute form without resolving symlinks. We replace our usage of canonicalize() with that function, so that we correctly treat symlinks in nodes_path or classes_path as separate entities (nodes or classes).

Checklist

  • The PR has a meaningful title. The title will be used to auto generate the changelog
  • PR contains a single logical change (to build a better changelog).
  • Update the documentation.
  • Update tests.
  • Categorize the PR by setting a good title and adding one of the labels:
    bug, enhancement, documentation, change, breaking, dependency, internal
    as they show up in the changelog
  • Link this PR to related PRs or issues.

Sorry, something went wrong.

@simu simu added the bug Something isn't working label Sep 12, 2023
@simu simu force-pushed the fix/discover-nodes-classes-symlink branch from 9cd2808 to b5f63c1 Compare September 12, 2023 11:58
Base automatically changed from feat/inventory to main September 12, 2023 12:11

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
We introduce function `to_lexical_absolute()` which converts a Path into
its normalized absolute form without resolving symlinks. We replace our
usage of `canonicalize()` with that function, so that we correctly treat
symlinks in `nodes_path` or `classes_path` as separate entities (nodes
or classes).

Additionally, we also use `to_lexical_absolute()` when generating the
`uri` in the `NodeInfoMeta` struct in `Node::parse()` to match Python
reclass's behavior.

Verified

This commit was signed with the committer’s verified signature.
jmeridth JM (Jason Meridth)
@simu simu force-pushed the fix/discover-nodes-classes-symlink branch from b5f63c1 to 15d1c22 Compare September 12, 2023 12:11
@simu simu requested a review from a team September 12, 2023 12:42
@simu simu merged commit 66a2905 into main Sep 12, 2023
@simu simu deleted the fix/discover-nodes-classes-symlink branch September 12, 2023 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants