question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Adding path dependency fails when given absolute path

See original GitHub issue

Version: 1.0.0b9 (e943a4e)

Expected behaviour: I can add path dependencies specified by absolute path. Actual behaviour: '/abs/path/to/dependency' does not start with '/abs/path/to/poetry-file/parent'

In poetry.console.commands.init:412(_parse_requirements) a call is made to path.relative_to(), which raise ValueErrorwhenpathisn't a relative path tocwd`.

I’m guessing that this was added thinking it behaves like os.path.relpath(), which it doesn’t. AFAICT, there isn’t any functionality in pathlib that does the same thing as os.path.relpath().

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:15
  • Comments:18 (3 by maintainers)

github_iconTop GitHub Comments

10reactions
thearchitectorcommented, Mar 1, 2021

Is there an update on this? I would greatly appreciate this functionality.

4reactions
gitpushdashfcommented, Aug 21, 2020

Any update on this? Would be really nice to do poetry add /some/absolute/path

Read more comments on GitHub >

github_iconTop Results From Across the Web

LoadLibrary with Absolute Path returns Incorrect HMODULE ...
When trying to load the dll from an absolute path, I get a Non-Null HMODULE that gives no windows error codes on a...
Read more >
Path Operations - Essential Java Classes - Oracle Help Center
A relative path cannot be constructed if only one of the paths includes a root element. If both paths include a root element,...
Read more >
OperatingSystem - Robot Framework
Documentation. Fails if the given path points to an existing file. The path can be given as an exact path or as a...
Read more >
Dependency resolution - Parcel
Relative specifiers start with . or .. , and resolve a file relative to the importing file. /path/to/project/src/client.js: import './utils.js' ...
Read more >
systemd.path - Freedesktop.org
If a path unit is beneath another mount unit in the file system hierarchy, both a requirement and an ordering dependency between both...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found