[ ] If an exception occurs when executing a command, I executed it again in debug mode (-vvv option).
OS version and name: Windows 10
[tool.poetry]
name = "pip-install-dev-error"
version = "0.1.0"
description = ""
authors = []
[tool.poetry.dependencies]
python = "*"
[tool.poetry.dev-dependencies]
test = {path = "../something-only-for-devs", develop=true}
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
Packages with path dependencies in [tool.poetry.dev-dependencies] cannot be installed by pip.
When trying to install it, prepare_metadata_for_build_wheel in poetry-core tries to resolve development dependencies, even though they are not going to be installed, and this fails with ValueError: Directory ..\something-only-for-devs does not exist.
At this point, I don't think it make any sense to try to resolve development dependencies. In the example above, it is a path dependency that doesn't exist for users installing the package (actually, the path existing or not doesn't matter, since poetry-core won't find it anyway, not even with --no-build-isolation - not sure why though), however, there can be other reasons for a development dependency to fail to resolve (e.g. private repo) that shouldn't matter for users installing the package.
Is that a duplicate of https://github.com/python-poetry/poetry/issues/2174?
If yes, @absassi would you mind trying the fix at https://github.com/python-poetry/poetry-core/pull/101 if you get a chance?
Yes, I believe it is a duplicate. Thanks for finding it.
I'll give it a try as soon as possible, but looking at the diff, it seems that it will fix this.
It works with current master of poetry-core. Thanks again @sinoroc .