If you're requirements.txt file is the output of pip freeze then it's really
a lock file, not a list of project dependencies. To get just the actual
dependencies:
find . -name \*.py -type f | xargs sed -En '/^(import|from)/ {s/\S+ //; s/ .*//; s/\..*//; p}' | sort -u >reqsThis extracts foo from all import foo.bar... and from foo.bar import... lines, dropping
local imports (starting with '.').