Add support for pip-tools
Closed this issue · 3 comments
Is your feature request related to a problem? Please describe.
Similarly, as for #22, it would be nice to add support for requirements.txt as produced by pip-tools.
Describe the solution you'd like
micropipenv would parse the lock file produced by pip-tools into its internal representation and would do the installation process in the s2i. The reason behind not installing requirements directly is the capability of failovers implemented in micropipenv (#12).
Another reason behind this is standardized standard and error output produced that is suitable for Thoth's analyzers which can parse failures out of build logs (note we install one package at a time which will help a lot in the build-analyzers to detect the package causing installation issues).
Describe alternatives you've considered
Stick with the current approach - install requirements using raw pip. This approach is prone to installation issues that can be introduced due to the relative ordering of Python modules.
I gave this a brief spike. To have this properly implemented, we will need to parse requirements from requirements.txt file. That will require either creating own logic for requirements.txt parsing (I'm against this approach) or depend on packaging, which introduces dependencies on pyparsing and six. None of these are present in the current Python s2i.
Let's see if supporting this feature outweights dependencies introduced to s2i.
Already done in the referenced PR.