Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Pip3 patch package in virtualenv

I have the unfortunate situation that I need to patch a package inside my virtualenv because of version conflict requirements that prohibit upgrading a package with a bug inside it.

Is there any way of providing patch files to pip when installing requirements from a .txt file?
I could not find anything searching for "pip venv provide patches" and so on.
I guess the solution would be to wrap it inside a bash script, but I’d rather avoid it if possible.

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

Is there any way of providing patch files to pip when installing requirements from a .txt file?

No, there is not. pip install does not support this.

One alternative would be to point pip to a patched version of the package, e.g. at a git repo. The linked Google thread also suggests checking out Paver.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading