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 to outside of project root better #89

Open
amyreese opened this issue Apr 7, 2023 · 0 comments
Open

Handle symlinks to outside of project root better #89

amyreese opened this issue Apr 7, 2023 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@amyreese
Copy link
Member

amyreese commented Apr 7, 2023

(all) amethyst@luxray ~/workspace/fixit main± ‹1› » fixit lint .
(PosixPath('.'),)
Traceback (most recent call last):
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/bin/fixit", line 10, in <module>
    sys.exit(main())
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/lib/python3.10/site-packages/click/core.py", line 1130, in __call__
    return self.main(*args, **kwargs)
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/lib/python3.10/site-packages/click/core.py", line 1055, in main
    rv = self.invoke(ctx)
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/lib/python3.10/site-packages/click/core.py", line 1657, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/lib/python3.10/site-packages/click/core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/lib/python3.10/site-packages/click/core.py", line 760, in invoke
    return __callback(*args, **kwargs)
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/lib/python3.10/site-packages/click/decorators.py", line 26, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "/Users/amethyst/workspace/Fixit/src/fixit/cli.py", line 96, in lint
    for result in fixit_paths(paths):
  File "/Users/amethyst/workspace/Fixit/src/fixit/api.py", line 180, in fixit_paths
    expanded_paths.extend(trailrunner.walk(path))
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/lib/python3.10/site-packages/trailrunner/core.py", line 185, in gen
    yield from gen(child.iterdir())
  File "/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all/lib/python3.10/site-packages/trailrunner/core.py", line 176, in gen
    relative = child.resolve().relative_to(root)
  File "/Users/amethyst/.pyenv/versions/3.10.6/lib/python3.10/pathlib.py", line 818, in relative_to
    raise ValueError("{!r} is not in the subpath of {!r}"
ValueError: '/Users/amethyst/Library/Application Support/hatch/env/virtual/fixit/OQ5NT6ov/all' is not in the subpath of '/Users/amethyst/workspace/Fixit' OR one path is relative and the other is absolute.
@amyreese amyreese added the bug Something isn't working label Apr 7, 2023
@amyreese amyreese self-assigned this Apr 7, 2023
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

No branches or pull requests

1 participant