Optional dependencies not marked as optional
akeeman opened this issue · 2 comments
Describe the bug
Maybe I'm wrong, but as I read it some dependencies should have been marked optional while they're not, when using pep621 (or pdm):
deptry/tests/dependency_getter/test_pep_621.py
Lines 20 to 27 in 2f39fb5
foobar:
barfoo:
dep:
Well spotted. This is a consequence of lack of standardization within the Python ecosystem/PEP-621. PEP-621 does not specify a way to list development dependencies, and just places everything under optional dependencies. See e.g. here. So for optional dependencies, we use the definition as listed here. It is done by this part of the code. I don't think there is much we can do to improve here, but if you have any ideas feel free to share them!
Ok, I wasn't aware that it was intentional.