-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Closed
Labels
area/solverRelated to the dependency resolverRelated to the dependency resolverkind/bugSomething isn't working as expectedSomething isn't working as expected
Description
Poetry's solver rejects installation of pytype in a project supporting Python 3.6+, even though pytype's Python constraint is compatible with it.
Repro:
- Add the following pyproject.toml
[tool.poetry]
name = "foobar"
version = "0.1.0"
description = ""
authors = ["User <[email protected]>"]
[tool.poetry.dependencies]
python = "^3.6"
[tool.poetry.dev-dependencies]
[build-system]
requires = ["poetry>=0.12"]
build-backend = "poetry.masonry.api"- Run
poetry add --dev --python="<3.8" pytype
This results in the following error message:
Creating virtualenv poetry-pytype-VZF4hhnk-py3.7 in ~/Library/Caches/pypoetry/virtualenvs
Using version ^2020.2.20 for pytype
Updating dependencies
Resolving dependencies... (0.0s)
[SolverProblemError]
The current project's Python requirement (^3.6) is not compatible with some of the required packages Python requirement:
- pytype requires Python !=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,<3.8,>=2.7
Because no versions of pytype match >2020.2.20,<2021.0.0
and pytype (2020.2.20) requires Python !=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,<3.8,>=2.7, pytype is forbidden.
So, because poetry-pytype depends on pytype (^2020.2.20), version solving failed.The same error happens with the command poetry add --dev pytype. (The --python="<3.8" was added because pytype currently does not support Python 3.8.)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
area/solverRelated to the dependency resolverRelated to the dependency resolverkind/bugSomething isn't working as expectedSomething isn't working as expected