For now we recognize only requirements files. We need to also support setup.py dependencies:
Distinguish it from requirements file (simple match the name against predefined setup.py)
Parse the file, find a list of dependencies in install-requires section
Do regual processing for requirements found
Limitations
We don't want to reinvent Python parser. That's why should do the simplies parsing for install-requires: check for an explicit list of strings. Variables, function calls assigned to install-requires won't be parsed.
Maybe also add verbosity flag and stdout notification if setup.py file detected, but install-requires parsing failed (field exists, but contains not a list of strings)
For now we recognize only requirements files. We need to also support
setup.py
dependencies:setup.py
)Limitations
We don't want to reinvent Python parser. That's why should do the simplies parsing for
install-requires
: check for an explicit list of strings. Variables, function calls assigned toinstall-requires
won't be parsed.Maybe also add verbosity flag and stdout notification if
setup.py
file detected, butinstall-requires
parsing failed (field exists, but contains not a list of strings)