Adding path dependency fails when given absolute path
See original GitHub issueVersion: 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
ValueErrorwhen
pathisn't a relative path to
cwd`.
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:
- Created 4 years ago
- Reactions:15
- Comments:18 (3 by maintainers)
Top 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 >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Is there an update on this? I would greatly appreciate this functionality.
Any update on this? Would be really nice to do
poetry add /some/absolute/path