-
Notifications
You must be signed in to change notification settings - Fork 19
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
KeyError when pyproject.toml dependencies are dynamically read from requirements.txt #421
Comments
Interesting, didn't know that it was possible to do that with Unfortunately, until this is implemented, there is no escape hatch to force |
Hello, I am interested in working on this issue. Since I am new to project, I will appreciate if I can get a bit more guidance on what changes are supposed to be made and what is the expected behaviour? |
We have the same issue for all our Python projects in our organisation. |
There is ongoing work to support this in #881, if anyone wants to try it out and report back on whether this works. |
Describe the bug
I usually have the following structure in my projects:
And then the projects requirements are listed in the
requirements.txt
file. This is useful because IDEs will usually syntax-highlight PEP 440 syntax in requirements files, but not in strings inside TOML tables.When I run
deptry .
with such a project, it crashes with the following traceback:To Reproduce
Using a pyproject.toml file as described above (with no
dependencies
key inside the top-levelproject
table, but mentioning"dependencies"
as adynamic
metadata), inside a Python 3.10 virtual environment, run:Expected behavior
Either:
tool.setuptools.dynamic.dependencies.file
idiom (see https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata); orSystem:
The text was updated successfully, but these errors were encountered: