-
Notifications
You must be signed in to change notification settings - Fork 54
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
Dependency walk failed #176
Comments
You have not provided a pyproject.toml as requested in the issue template -- can you please provide that information so that people can help you debug? |
I guess this is a duplicate of #173 |
@neersighted updated the issue description with pyproject.toml @finswimmer i'm already using a python constraint so i don't believe this is a duplicate. Let me know. |
It's hard to know what to make of this. So far as I can see poetry simply doesn't support source distributions with file suffix So I don't know how this becomes an export problem... |
I've updated the pyproject.toml file with packages that are the culprit - click and black. Also, this issue might be related - psf/black#2964, but i'm still not sure why export is not working? |
Tweaked my pyproject.toml a bit more and was able to resolve the issue by specifying black versions for each python version. Marking closed. |
I don't know that this should be closed -- we shouldn't fail to export a valid lock file generated from a valid pyproject. |
I'm having the same issue, not sure if it's the same cause. I think in our case it is related to #28. Our poetry.lock conatins duplicate entries for scipy (versions 1.8.1 and 1.10.0). This doesn't seem to be a problem, the poetry instally 1.10 and the project works fine. But export fails with In our case a workaround is adding a direct |
This comment was marked as off-topic.
This comment was marked as off-topic.
Adding a direct dependency is not exactly a workaround; you should add constraints for anything you care to perturb/alter, not just anything you import directly. That being said, it is a workaround in this specific case as you are trying to perturb the lock file for us with this plugin, and not the dependency tree as a whole. |
Poetry-export is used in CI so this bug blocks CI operation without the workaround suggested in this issue: python-poetry/poetry-plugin-export#176
I encountered this I am able to reproduce this with this
N.b. it's got two I think it might have something to do with the scipy = [
{version = ">=1.3", markers = "python_version > \"3.9\" and python_version < \"3.12\" or platform_system != \"Windows\" and python_version < \"3.12\" or platform_machine != \"x86\" and python_version < \"3.12\""},
{version = ">=1.3,<1.9", markers = "python_version == \"3.9\" and platform_system == \"Windows\" and platform_machine == \"x86\""},
] |
poetry export also appears to fail on poetry itself:
|
Just as @novas0x2a said - even poetry itself fails as it defines separate virtualenv dependency range for Windows and Python 3.9: virtualenv = [
{version = ">=20.4.3,<20.4.5 || >20.4.5,<20.4.6 || >20.4.6,<21.0.0", markers = "sys_platform != \"win32\" or python_version != \"3.9\""},
{version = ">=20.4.3,<20.4.5 || >20.4.5,<20.4.6 || >20.4.6,<20.16.6", markers = "sys_platform == \"win32\" and python_version == \"3.9\""},
] |
linking to a closely-related issue: #168 |
Closely related issues: #163, #168, #183, #186, #187. Also, the culprit seems to be this block of code - https://github.com/python-poetry/poetry-plugin-export/blob/main/src/poetry_plugin_export/walker.py#L235. @finswimmer |
I see this error on several newer packages:
when they are part of the dependency graph, poetry fails with "Dependency walk failed" error. |
Anything came up since? Edit: I've tried to add specific version of |
Hi, I need help, I have a similar issue, using
From my [tool.poetry.dependencies]
python = ">=3.9,<3.11"
typed-argument-parser = "^1.7.2"
opencv-python = "4.6.0.66"
pillow = "^9.3.0"
tqdm = "^4.64.1"
scikit-image = "^0.19.3"
numpy = "^1.23.5"
tornado = "^6.2"
parse = "^1.19.0"
more-itertools = "^9.0.0"
matplotlib = "^3.7.0"
tensorflow = "2.13.1"
humanize = "^4.8.0"
torch = "2.0.1"
boto3 = "^1.34.0"
[tool.poetry.group.dev.dependencies]
pre-commit = "^2.20.0"
pytest-cov = "^4.0.0"
ipdb = "^0.13.11"
pdbpp = "^0.10.3"
boto3-stubs = { extras = ["lambda", "s3"], version = "^1.34.0" }
types-pillow = "^9.4.0.12"
types-tqdm = "^4.64.7.13"
pytest-xdist = "^3.2.0"
keras = "^2.11.0"
onnxruntime-gpu = "^1.13.1"
pip = "^23.1.2"
wheel = "^0.40.0"
ruff = "^0.1.3"
mypy = "^1.6.1"
types-requests = "2.31.0.6"
mypy-boto3-lambda = "^1.34.0"
mypy-boto3-s3 = "^1.34.0" Never mind, the issue is the way |
-vvv
option) and have included the output below.Issue
When using poetry export with dev dependencies (following command), i get stack trace below with error:
poetry export -f requirements.txt -o ./dev_dependencies --without-hashes --with dev
The text was updated successfully, but these errors were encountered: