Hacker News new | past | comments | ask | show | jobs | submit login

I work in an rpm shop, and we've been exploring switching to python. Could you expand on or link to some of the rpm&pyhton issues you've run into?



The main thing is understanding that the system python installation should be left alone and you should install each app/project in a separate virtualenv / venv so their versions of Python & installed packages are isolated from the system and each other. This also tends to get rid of about 99% of the times where someone try "sudo <previous command>" before reading the error message.

These days I tend to recommend using https://pipenv.readthedocs.io/ or https://poetry.eustace.io/ which will automate creation of those virtual environments and provide a nice interface for managing versioned package installs (i.e. `pipenv install foobar` will record the exact version you installed, including SHA-256 hashes, for repeatable installs).

If you're in the Red Hat world, note also that they're making some big (and I think welcome) changes to isolate the Python they use from the version developers use, which will also allow tracking newer versions faster:

https://developers.redhat.com/blog/2018/11/27/what-no-python...


I was looking at venv, but I guess not fully looking through into deployment. Do you know if venv works with setup.py bdist_rpm or is there nothing standard linking the two concepts?


You should not mix bdist_rpm and venv; but you can build eggs or wheels with bdist_egg/bdist_whl and install these into venv.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: