Question about installing python and modules on Red Hat Linux 6

Chris Angelico rosuav at gmail.com
Sat Nov 15 06:09:51 CET 2014


On Sat, Nov 15, 2014 at 2:01 PM, pythonista
<software.by.python at gmail.com> wrote:
> The scope of the project was to install python 2.7.8 and 4 modules/site packages on a fresh linux build.
>
> The first team failed after almost 3 weeks of work.
>
> Then  they put their star Linux administrator on the task and it took almost a week of considerable effort.
>
> I was able to perform the same task on my windows desktop in less than a morning.
>
> I cannot get a straight answer as to what the problems are.

Well, you're asking the wrong people. The crystal ball manufacturer
around here is horribly shoddy, shipping us faulty optics and devices
with frequent outages. But if you ask the people who did the work,
they should be able to tell you what was happening.

My suspicion here is that the admins were trying to use multiple
different installation methods, and they ran into issues. This
currently can't happen on Windows, as there simply isn't a
system-provided package manager (though that may be changing - soon
Windows people will have all the same advantages AND disadvantages
that everyone else has!), hence you perhaps found it easier. On my
Debian systems, I can use "apt-get install python python-bs4
python-django" and grab a consistent set of packages from the
OS-provided repositories; or alternatively, I can use pip to get
things from the Python-provided repository (PyPI). Trying to use both
can cause issues.

Want an easy solution? Get a recent Python (preferably 3.x, but
otherwise the latest builds of 2.7 should do I think), get pip, get
virtualenv, and then do everything inside a venv with "pip install"
(maybe using requirements.txt to save you the hassle of keying
everything in). You'll find that that "just works", pretty much all
the time. It's perhaps more work than you truly need (I personally
don't usually bother with a venv), but that way you can be sure you're
not trampling all over anything else.

ChrisA



More information about the Python-list mailing list