[tech] Python 2.7 site-packages in /usr/local on Motsugo

David Adam zanchey at ucc.gu.uwa.edu.au
Sat May 18 16:41:45 AWST 2019

[TEC] reported that starting a Python 2 program that imported `requests` 
on Motsugo spat out a traceback and exited.

Investigation showed that there were heaps of packages installed in 
/usr/local/lib/python2.7/dist-packages by pip, mostly dating from 2015.

Almost all of them were out of date (newer versions available in Debian), 
including packages with known security problems, so I have uninstalled 
them all. If your Python program breaks then please look at either 
installing the Debian package, or using `pip --user` to install packages 
in your home directory.

The full list of uninstalled local packages is:

aniso8601 av Babel bash-kernel Bottleneck brewer2mpl bugjar certifi cffi
chardet cryptography cymem cython cytoolz debtcollector dill distance
falcon Flask Flask-RESTful Flask-SQLAlchemy ftfy functools32 gdata
ggplot grip html5lib idna imapclient ipykernel ipython ipython-genutils
ipywidgets iso8601 itsdangerous jinja2 jsonschema jupyter-client
jupyter-console jupyter-core Logbook markdown markupsafe matplotlib
mechanize mock multipledispatch murmurhash nbconvert nbformat neovim
netaddr networkx nltk nose notebook ntlm numexpr numpy oauthlib oct2py
oslo.config oslo.i18n oslo.serialization oslo.utils pandas
path-and-address path.py patsy pattern pbr plumbum preshed psutil
ptyprocess pyasn1 pycallgraph pycparser pyexchange pyflakes Pygments
PyLaTeX PySpice pytz qtconsole requests requests-oauthlib rope ropemode
scimath scipy seaborn selenium setuptools six splinter sqlalchemy
statsmodels stevedore sympy terminado textblob Theano threadonly
threadpool toolz traitlets traits trello trollius trolly twill twisted
virtualenv wcwidth werkzeug yahmm 

In the same vein, I suggest to wheel members that running `make install` 
to put things into /usr/local is almost always wrong on multiuser systems. 
If there is not a package in Debian already, creating one is pretty easy 
and at least keeps track of what files are where properly. I am happy to 
assist if needed

David Adam
zanchey at ucc.gu.uwa.edu.au

More information about the tech mailing list