Skip to content

pip3 freeze output still confusing when stray AdjacentTempDirectorys are present #7269

Closed
@ExplodingCabbage

Description

@ExplodingCabbage

Environment

  • pip version: 19.3.1
  • Python version: 3.7.4
  • OS: macOS 10.14.6

Like some other people (e.g. this fellow, and this guy), I have a site-packages littered with leftover folders created by AdjacentTempDirectory, visible at the bottom of this ls output:

Output
markamery@Marks-MacBook-Pro-3 site-packages$ ls -l
total 95312
drwxr-xr-x   12 markamery  admin   384B 28 Oct 18:24 Adafruit_GPIO/
drwxr-xr-x    7 markamery  admin   224B 28 Oct 18:24 Adafruit_GPIO-1.0.3.dist-info/
drwxr-xr-x    5 markamery  admin   160B 28 Oct 18:24 Adafruit_MAX31855/
drwxr-xr-x    8 markamery  admin   256B 28 Oct 18:24 Adafruit_MAX31855-1.6.1.dist-info/
drwxr-xr-x    5 markamery  admin   160B 28 Oct 18:24 Adafruit_PureIO/
drwxr-xr-x    7 markamery  admin   224B 28 Oct 18:24 Adafruit_PureIO-0.2.3.dist-info/
drwxr-xr-x    7 markamery  admin   224B 28 Oct 18:26 ArduinoKeywords-1.0.4.dist-info/
drwxr-xr-x    9 root       admin   288B 21 Sep 18:11 Babel-2.7.0.dist-info/
drwxr-xr-x   70 root       admin   2.2K 29 Oct 10:35 Bio/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:35 BioSQL/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 CairoSVG-2.4.2.dist-info/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:48 Click-7.0.dist-info/
drwxr-xr-x    7 markamery  admin   224B 28 Oct 18:26 CppHeaderParser/
drwxr-xr-x    7 markamery  admin   224B 28 Oct 18:26 CppHeaderParser-2.7.4.dist-info/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:35 Flask-1.1.1.dist-info/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:51 Flask_Compress-1.4.0.dist-info/
drwxr-xr-x   25 root       admin   800B 21 Sep 20:28 IPython/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:25 Jinja2-2.10.3.dist-info/
drwxr-xr-x   10 root       admin   320B 24 Oct 16:27 Mako-1.1.0.dist-info/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:49 MarkupSafe-1.1.1.dist-info/
-rw-r--r--    1 root       admin    46B  1 Oct 14:15 NanoSim-H.egg-link
drwxr-xr-x   11 root       admin   352B 24 Oct 16:27 OpenSSL/
drwxr-xr-x  103 root       admin   3.2K 29 Oct 10:29 PIL/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:29 Pillow-6.2.1.dist-info/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 PyWavelets-1.1.1.dist-info/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:27 PyYAML-3.13.dist-info/
drwxr-xr-x   10 root       admin   320B 21 Sep 18:11 Pygments-2.4.2.dist-info/
drwxr-xr-x    7 root       admin   224B 24 Oct 16:27 Pyphen-0.9.5.dist-info/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:35 SQLAlchemy-1.3.10.dist-info/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 Send2Trash-1.5.0.dist-info/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:36 Sphinx-2.2.1.dist-info/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:35 WeasyPrint-50.dist-info/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:36 Werkzeug-0.16.0.dist-info/
drwxr-xr-x   33 markamery  admin   1.0K 29 Oct 10:29 __pycache__/
-rw-r--r--    1 root       admin   396K 24 Oct 16:25 _cffi_backend.cpython-37m-darwin.so
-rw-r--r--    1 root       admin    23B 21 Sep 20:28 _pyrsistent_version.py
drwxr-xr-x   13 root       admin   416B 21 Sep 18:11 alabaster/
drwxr-xr-x   11 root       admin   352B 21 Sep 18:11 alabaster-0.7.12.dist-info/
drwxr-xr-x   16 root       admin   512B 29 Oct 10:35 alembic/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:35 alembic-1.2.1.dist-info/
drwxr-xr-x    4 root       admin   128B 29 Oct 10:25 apiclient/
drwxr-xr-x    6 root       admin   192B 21 Sep 20:28 appnope/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 appnope-0.1.0.dist-info/
drwxr-xr-x    6 markamery  admin   192B 28 Oct 18:26 arduinokeywords/
drwxr-xr-x   18 root       admin   576B 21 Sep 20:28 attr/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 attrs-19.1.0.dist-info/
drwxr-xr-x   31 root       admin   992B 29 Oct 10:24 awscli/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:24 awscli-1.16.268.dist-info/
drwxr-xr-x   19 root       admin   608B 21 Sep 18:11 babel/
drwxr-xr-x    6 root       admin   192B 21 Sep 20:28 backcall/
drwxr-xr-x    7 root       admin   224B 21 Sep 20:28 backcall-0.1.0.dist-info/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:35 biopython-1.74.dist-info/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 bleach/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 bleach-3.1.0.dist-info/
drwxr-xr-x   15 root       admin   480B 29 Oct 10:28 boto3/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:28 boto3-1.10.4.dist-info/
drwxr-xr-x   42 root       admin   1.3K 29 Oct 10:24 botocore/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:24 botocore-1.13.4.dist-info/
drwxr-xr-x    7 root       admin   224B 24 Oct 16:26 cached_property-1.5.1.dist-info/
-rw-r--r--    1 root       admin   4.2K 24 Oct 16:21 cached_property.py
drwxr-xr-x   12 root       admin   384B 24 Oct 16:26 cachetools/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:26 cachetools-3.1.1.dist-info/
drwxr-xr-x   18 root       admin   576B 24 Oct 16:27 cairocffi/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:27 cairocffi-1.1.0.dist-info/
drwxr-xr-x   21 root       admin   672B 24 Oct 16:27 cairosvg/
drwxr-xr-x    7 root       admin   224B 21 Sep 18:11 certifi/
drwxr-xr-x    9 root       admin   288B 21 Sep 18:11 certifi-2019.9.11.dist-info/
drwxr-xr-x   23 root       admin   736B 24 Oct 16:27 cffi/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 cffi-1.13.1.dist-info/
drwxr-xr-x   43 root       admin   1.3K 21 Sep 18:11 chardet/
drwxr-xr-x   10 root       admin   320B 21 Sep 18:11 chardet-3.0.4.dist-info/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:46 cigar-0.1.3.dist-info/
-rw-r--r--    1 root       admin   4.5K 16 Sep 15:45 cigar.py
drwxr-xr-x    4 root       admin   128B 29 Oct 10:25 ciso8601/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:25 ciso8601-2.1.2.dist-info/
-rwxr-xr-x    1 root       admin    18K 29 Oct 10:25 ciso8601.cpython-37m-darwin.so*
drwxr-xr-x   20 root       admin   640B 16 Sep 15:48 click/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 colorama/
drwxr-xr-x   10 root       admin   320B 24 Oct 16:27 colorama-0.3.9.dist-info/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:26 cpplint-1.4.4.dist-info/
-rw-r--r--    1 root       admin   247K 24 Oct 16:18 cpplint.py
drwxr-xr-x   10 root       admin   320B 24 Oct 16:27 cryptography/
drwxr-xr-x   12 root       admin   384B 24 Oct 16:27 cryptography-2.8.dist-info/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 cssselect2/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 cssselect2-0.2.2.dist-info/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:34 cv2/
drwxr-xr-x    9 root       admin   288B 16 Sep 15:45 cycler-0.10.0.dist-info/
-rw-r--r--    1 root       admin    16K 16 Sep 15:43 cycler.py
drwxr-xr-x   14 root       admin   448B 16 Sep 15:45 dateutil/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 decorator-4.4.0.dist-info/
-rw-r--r--    1 root       admin    17K 21 Sep 20:28 decorator.py
drwxr-xr-x   14 root       admin   448B 21 Sep 20:28 defusedxml/
drwxr-xr-x    7 root       admin   224B 21 Sep 20:28 defusedxml-0.6.0.dist-info/
drwxr-xr-x   17 root       admin   544B 20 Sep 17:38 docutils/
drwxr-xr-x    8 root       admin   256B 20 Sep 17:38 docutils-0.15.2.dist-info/
-rw-r--r--    1 root       admin    15K 24 Oct 16:25 dot_parser.py
-rw-r--r--    1 root       admin    67B  3 Oct 14:43 easy-install.pth
-rw-r--r--    1 markamery  admin   126B  8 Jul 19:31 easy_install.py
-rwxr-xr-x    1 root       admin   2.9K 24 Oct 16:25 editor.py*
drwxr-xr-x    7 root       admin   224B 16 Sep 15:45 entrypoints-0.3.dist-info/
-rw-r--r--    1 root       admin   8.1K 16 Sep 15:43 entrypoints.py
drwxr-xr-x   17 root       admin   544B 29 Oct 10:24 flake8/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:24 flake8-3.7.9.dist-info/
drwxr-xr-x   22 root       admin   704B 29 Oct 10:35 flask/
-rw-r--r--    1 root       admin   3.8K 16 Sep 15:51 flask_compress.py
drwxr-xr-x  121 root       admin   3.8K 24 Oct 16:26 gevent/
drwxr-xr-x   11 root       admin   352B 24 Oct 16:26 gevent-1.4.0.dist-info/
drwxr-xr-x    4 root       admin   128B 24 Oct 16:26 google/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:25 google_api_python_client-1.7.11.dist-info/
-rw-r--r--    1 root       admin   539B 24 Oct 16:25 google_auth-1.6.3-py3.5-nspkg.pth
drwxr-xr-x    9 root       admin   288B 24 Oct 16:26 google_auth-1.6.3.dist-info/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:26 google_auth_httplib2-0.0.3.dist-info/
-rw-r--r--    1 root       admin   8.2K 24 Oct 16:25 google_auth_httplib2.py
drwxr-xr-x   15 root       admin   480B 29 Oct 10:25 googleapiclient/
drwxr-xr-x   10 root       admin   320B 24 Oct 16:26 greenlet-0.4.15.dist-info/
-rwxr-xr-x    1 root       admin    30K 24 Oct 16:26 greenlet.cpython-37m-darwin.so*
drwxr-xr-x   22 root       admin   704B 20 Sep 17:38 gunicorn/
drwxr-xr-x    9 root       admin   288B 20 Sep 17:38 gunicorn-19.9.0.dist-info/
drwxr-xr-x   16 root       admin   512B 24 Oct 16:27 html5lib/
drwxr-xr-x   10 root       admin   320B 24 Oct 16:27 html5lib-1.0.1.dist-info/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:26 httplib2/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:26 httplib2-0.14.0.dist-info/
drwxr-xr-x   11 root       admin   352B 21 Sep 18:11 idna/
drwxr-xr-x    8 root       admin   256B 21 Sep 18:11 idna-2.8.dist-info/
drwxr-xr-x   10 root       admin   320B 24 Oct 16:27 imageio/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 imageio-2.6.1.dist-info/
drwxr-xr-x    8 root       admin   256B 21 Sep 18:11 imagesize-1.1.0.dist-info/
-rw-r--r--    1 root       admin   9.9K 21 Sep 18:11 imagesize.py
drwxr-xr-x   14 root       admin   448B 29 Oct 10:35 influxdb/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:35 influxdb-5.2.3.dist-info/
drwxr-xr-x   31 root       admin   992B 21 Sep 20:28 ipykernel/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 ipykernel-5.1.2.dist-info/
-rw-r--r--    1 root       admin   451B 21 Sep 20:27 ipykernel_launcher.py
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 ipython-7.8.0.dist-info/
drwxr-xr-x   14 root       admin   448B 21 Sep 20:28 ipython_genutils/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 ipython_genutils-0.2.0.dist-info/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 ipywidgets/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 ipywidgets-7.5.1.dist-info/
drwxr-xr-x   14 root       admin   448B 24 Sep 11:13 isodate/
drwxr-xr-x    9 root       admin   288B 24 Sep 11:13 isodate-0.6.0.dist-info/
drwxr-xr-x   13 root       admin   416B 16 Sep 15:49 itsdangerous/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:49 itsdangerous-1.1.0.dist-info/
drwxr-xr-x   18 root       admin   576B 21 Sep 20:28 jedi/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 jedi-0.15.1.dist-info/
drwxr-xr-x   30 root       admin   960B 29 Oct 10:25 jinja2/
drwxr-xr-x   11 root       admin   352B 20 Sep 17:38 jmespath/
drwxr-xr-x   10 root       admin   320B 20 Sep 17:38 jmespath-0.9.4.dist-info/
drwxr-xr-x   29 root       admin   928B 16 Sep 15:46 joblib/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:46 joblib-0.13.2.dist-info/
drwxr-xr-x   18 root       admin   576B 21 Sep 20:28 jsonschema/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 jsonschema-3.0.2.dist-info/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 jupyter-1.0.0.dist-info/
-rw-r--r--    1 root       admin   177B 21 Sep 20:27 jupyter.py
drwxr-xr-x   29 root       admin   928B 21 Sep 20:28 jupyter_client/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 jupyter_client-5.3.3.dist-info/
drwxr-xr-x   11 root       admin   352B 21 Sep 20:28 jupyter_console/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 jupyter_console-6.0.0.dist-info/
drwxr-xr-x   13 root       admin   416B 21 Sep 20:28 jupyter_core/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 jupyter_core-4.5.0.dist-info/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:45 kiwisolver-1.1.0.dist-info/
-rw-r--r--    1 root       admin   361K 16 Sep 15:43 kiwisolver.cpython-37m-darwin.so
drwxr-xr-x   21 root       admin   672B 24 Oct 16:27 mako/
drwxr-xr-x    9 root       admin   288B 16 Sep 15:49 markupsafe/
drwxr-xr-x   88 root       admin   2.8K 29 Oct 10:29 matplotlib/
-rw-r--r--    1 root       admin   569B 29 Oct 10:29 matplotlib-3.1.1-py3.7-nspkg.pth
drwxr-xr-x    8 root       admin   256B 29 Oct 10:29 matplotlib-3.1.1.dist-info/
drwxr-xr-x   10 root       admin   320B 16 Sep 15:45 mccabe-0.6.1.dist-info/
-rw-r--r--    1 root       admin    10K 16 Sep 15:43 mccabe.py
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 mistune-0.8.4.dist-info/
-rw-r--r--    1 root       admin    36K 21 Sep 20:27 mistune.py
drwxr-xr-x    9 root       admin   288B 24 Sep 11:12 mmtf/
drwxr-xr-x    7 root       admin   224B 24 Sep 11:12 mmtf_python-1.1.2.dist-info/
drwxr-xr-x    7 root       admin   224B 29 Oct 10:29 mpl_toolkits/
drwxr-xr-x    8 root       admin   256B 24 Sep 11:12 msgpack/
drwxr-xr-x    8 root       admin   256B 24 Sep 11:12 msgpack-0.6.2.dist-info/
drwxr-xr-x  196 root       admin   6.1K 29 Oct 10:24 mypy/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:24 mypy-0.740.dist-info/
drwxr-xr-x    7 root       admin   224B 16 Sep 15:45 mypy_extensions-0.4.1.dist-info/
-rw-r--r--    1 root       admin   4.9K 16 Sep 15:43 mypy_extensions.py
drwxr-xr-x   69 root       admin   2.2K 29 Oct 10:24 mypyc/
-rwxr-xr-x    1 root       admin    45M 29 Oct 10:24 mypyc_73ace4c88000b89b158a.cpython-37m-darwin.so*
drwxr-xr-x   16 root       admin   512B 21 Sep 20:28 nbconvert/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 nbconvert-5.6.0.dist-info/
drwxr-xr-x   17 root       admin   544B 21 Sep 20:28 nbformat/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 nbformat-4.4.0.dist-info/
drwxr-xr-x   19 root       admin   608B 24 Oct 16:27 networkx/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:27 networkx-2.4.dist-info/
drwxr-xr-x   35 root       admin   1.1K 21 Sep 20:28 notebook/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 notebook-6.0.1.dist-info/
drwxr-xr-x   30 root       admin   960B 29 Oct 10:26 numpy/
drwxr-xr-x   10 root       admin   320B 29 Oct 10:26 numpy-1.17.3.dist-info/
drwxr-xr-x   11 root       admin   352B 21 Sep 18:11 numpydoc/
drwxr-xr-x    8 root       admin   256B 21 Sep 18:11 numpydoc-0.9.1.dist-info/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:34 opencv_contrib_python-4.1.1.26.dist-info/
drwxr-xr-x   13 root       admin   416B 21 Sep 18:11 packaging/
drwxr-xr-x   10 root       admin   320B 21 Sep 18:11 packaging-19.2.dist-info/
drwxr-xr-x   20 root       admin   640B 29 Oct 10:31 pandas/
drwxr-xr-x   10 root       admin   320B 29 Oct 10:31 pandas-0.25.2.dist-info/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 pandocfilters-1.4.2.dist-info/
-rw-r--r--    1 root       admin   8.1K 21 Sep 20:28 pandocfilters.py
drwxr-xr-x    7 root       admin   224B 16 Sep 15:48 parasail/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:48 parasail-1.1.17.dist-info/
drwxr-xr-x   14 root       admin   448B 21 Sep 20:28 parso/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 parso-0.5.1.dist-info/
drwxr-xr-x   19 root       admin   608B 21 Sep 20:28 pexpect/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 pexpect-4.7.0.dist-info/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 pickleshare-0.7.5.dist-info/
-rw-r--r--    1 root       admin   9.7K 21 Sep 20:28 pickleshare.py
drwxr-xr-x    7 root       admin   224B 29 Oct 10:45 pip/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:45 pip-19.3.1.dist-info/
drwxr-xr-x    7 markamery  admin   224B 13 Sep 20:12 pkg_resources/
drwxr-xr-x   15 markamery  admin   480B 28 Oct 18:27 pkginfo/
drwxr-xr-x    9 markamery  admin   288B 28 Oct 18:27 pkginfo-1.5.0.1.dist-info/
drwxr-xr-x    9 markamery  admin   288B 28 Oct 18:26 ply/
drwxr-xr-x    9 markamery  admin   288B 28 Oct 18:26 ply-3.11.dist-info/
drwxr-xr-x   11 root       admin   352B 25 Sep 15:48 primer3/
drwxr-xr-x    9 root       admin   288B 25 Sep 15:48 primer3_py-0.6.0.dist-info/
drwxr-xr-x   10 root       admin   320B  1 Oct 14:15 progressbar/
drwxr-xr-x    8 root       admin   256B  1 Oct 14:15 progressbar2-3.47.0.dist-info/
drwxr-xr-x   23 root       admin   736B 21 Sep 20:28 prometheus_client/
drwxr-xr-x    7 root       admin   224B 21 Sep 20:28 prometheus_client-0.7.1.dist-info/
drwxr-xr-x   36 root       admin   1.1K 21 Sep 20:28 prompt_toolkit/
drwxr-xr-x    7 root       admin   224B 21 Sep 20:28 prompt_toolkit-2.0.9.dist-info/
drwxr-xr-x   16 root       admin   512B 29 Oct 10:25 psutil/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:25 psutil-5.6.3.dist-info/
drwxr-xr-x   17 root       admin   544B 29 Oct 10:26 psycopg2/
drwxr-xr-x    7 root       admin   224B 29 Oct 10:26 psycopg2-2.8.4-py3.7.egg-info/
drwxr-xr-x    7 root       admin   224B 21 Sep 20:28 ptyprocess/
drwxr-xr-x    7 root       admin   224B 21 Sep 20:28 ptyprocess-0.6.0.dist-info/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:27 pyOpenSSL-19.0.0.dist-info/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:26 pyasn1/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:26 pyasn1-0.4.7.dist-info/
drwxr-xr-x   85 root       admin   2.7K 24 Oct 16:26 pyasn1_modules/
drwxr-xr-x   11 root       admin   352B 24 Oct 16:26 pyasn1_modules-0.2.7.dist-info/
drwxr-xr-x   12 root       admin   384B 16 Sep 15:45 pycodestyle-2.5.0.dist-info/
-rw-r--r--    1 root       admin    98K 16 Sep 15:43 pycodestyle.py
drwxr-xr-x   16 root       admin   512B 24 Oct 16:27 pycparser/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:27 pycparser-2.19.dist-info/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:26 pydot-1.4.1.dist-info/
-rw-r--r--    1 root       admin    53K 24 Oct 16:25 pydot.py
drwxr-xr-x   11 root       admin   352B 16 Sep 15:45 pyflakes/
drwxr-xr-x    9 root       admin   288B 16 Sep 15:45 pyflakes-2.1.1.dist-info/
drwxr-xr-x   22 root       admin   704B 21 Sep 18:11 pygments/
-rw-r--r--    1 root       admin    90B 29 Oct 10:29 pylab.py
drwxr-xr-x   10 root       admin   320B 16 Sep 15:45 pyparsing-2.4.2.dist-info/
-rw-r--r--    1 root       admin   257K 16 Sep 15:43 pyparsing.py
drwxr-xr-x    5 root       admin   160B 24 Oct 16:27 pyphen/
-rw-r--r--    1 root       admin    11K 24 Oct 16:25 pyphen.py
drwxr-xr-x   23 root       admin   736B 21 Sep 20:28 pyrsistent/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 pyrsistent-0.15.4.dist-info/
drwxr-xr-x   41 root       admin   1.3K 16 Sep 15:45 pysam/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:45 pysam-0.15.3.dist-info/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 pyserial-3.4.dist-info/
drwxr-xr-x    9 root       admin   288B 16 Sep 15:45 python_dateutil-2.8.0.dist-info/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:27 python_editor-1.0.4.dist-info/
drwxr-xr-x   12 root       admin   384B  1 Oct 14:15 python_utils/
drwxr-xr-x   10 root       admin   320B  1 Oct 14:15 python_utils-2.3.0.dist-info/
drwxr-xr-x   10 root       admin   320B 29 Oct 10:25 pytz/
drwxr-xr-x   11 root       admin   352B 29 Oct 10:25 pytz-2019.3.dist-info/
drwxr-xr-x   22 root       admin   704B 24 Oct 16:27 pywt/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 pyzmq-18.1.0.dist-info/
-rw-r--r--    1 root       admin    23B 16 Sep 15:48 qcat.egg-link
drwxr-xr-x   39 root       admin   1.2K 21 Sep 20:28 qtconsole/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 qtconsole-4.5.5.dist-info/
drwxr-xr-x   25 root       admin   800B 24 Sep 11:13 rdflib/
drwxr-xr-x   11 root       admin   352B 24 Sep 11:13 rdflib-4.2.2.dist-info/
drwxr-xr-x   11 markamery  admin   352B 28 Oct 18:27 readme_renderer/
drwxr-xr-x    9 markamery  admin   288B 28 Oct 18:27 readme_renderer-24.0.dist-info/
drwxr-xr-x    8 root       admin   256B  4 Oct 15:28 regex/
drwxr-xr-x    7 root       admin   224B  4 Oct 15:28 regex-2019.8.19.dist-info/
drwxr-xr-x   13 root       admin   416B 24 Sep 11:13 reportlab/
drwxr-xr-x    8 root       admin   256B 24 Sep 11:13 reportlab-3.5.26.dist-info/
drwxr-xr-x   21 root       admin   672B 21 Sep 18:11 requests/
drwxr-xr-x    8 root       admin   256B 21 Sep 18:11 requests-2.22.0.dist-info/
drwxr-xr-x   15 markamery  admin   480B 28 Oct 18:27 requests_toolbelt/
drwxr-xr-x    9 markamery  admin   288B 28 Oct 18:27 requests_toolbelt-0.9.1.dist-info/
drwxr-xr-x   21 root       admin   672B 24 Oct 16:26 rsa/
drwxr-xr-x   10 root       admin   320B 24 Oct 16:26 rsa-3.4.2.dist-info/
drwxr-xr-x   18 root       admin   576B 24 Oct 16:26 s3transfer/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:26 s3transfer-0.2.1.dist-info/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:28 scikit_image-0.16.2.dist-info/
drwxr-xr-x    8 root       admin   256B 16 Sep 15:46 scikit_learn-0.21.3.dist-info/
drwxr-xr-x   35 root       admin   1.1K 29 Oct 10:27 scipy/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:27 scipy-1.3.1.dist-info/
drwxr-xr-x    6 root       admin   192B 24 Oct 16:27 selenium/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:27 selenium-3.141.0.dist-info/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 send2trash/
drwxr-xr-x   26 root       admin   832B 24 Oct 16:27 serial/
drwxr-xr-x   42 markamery  admin   1.3K 13 Sep 20:12 setuptools/
drwxr-xr-x    9 markamery  admin   288B 13 Sep 20:12 setuptools-41.0.1-py3.7.egg-info/
-rw-r--r--    1 markamery  admin   2.0K 13 Sep 20:12 sitecustomize.py
drwxr-xr-x    8 root       admin   256B 16 Sep 15:45 six-1.12.0.dist-info/
-rw-r--r--    1 root       admin    32K 16 Sep 15:43 six.py
drwxr-xr-x   28 root       admin   896B 29 Oct 10:28 skimage/
drwxr-xr-x   51 root       admin   1.6K 16 Sep 15:46 sklearn/
drwxr-xr-x    7 root       admin   224B 16 Sep 15:46 sklearn-0.0.dist-info/
drwxr-xr-x   32 root       admin   1.0K 21 Sep 18:11 snowballstemmer/
drwxr-xr-x    8 root       admin   256B 21 Sep 18:11 snowballstemmer-1.9.1.dist-info/
drwxr-xr-x   42 root       admin   1.3K 29 Oct 10:36 sphinx/
drwxr-xr-x    8 markamery  admin   256B 28 Oct 18:26 sphinx_autodoc_typehints-1.9.0.dist-info/
-rw-r--r--    1 markamery  admin    15K 28 Oct 18:26 sphinx_autodoc_typehints.py
drwxr-xr-x   13 root       admin   416B 21 Sep 18:12 sphinx_rtd_theme/
drwxr-xr-x    9 root       admin   288B 21 Sep 18:12 sphinx_rtd_theme-0.4.3.dist-info/
drwxr-xr-x    8 root       admin   256B 21 Sep 18:11 sphinxcontrib/
-rw-r--r--    1 root       admin   574B 21 Sep 18:11 sphinxcontrib_applehelp-1.0.1-py3.7-nspkg.pth
drwxr-xr-x    9 root       admin   288B 21 Sep 18:11 sphinxcontrib_applehelp-1.0.1.dist-info/
-rw-r--r--    1 root       admin   574B 21 Sep 18:11 sphinxcontrib_devhelp-1.0.1-py3.7-nspkg.pth
drwxr-xr-x    9 root       admin   288B 21 Sep 18:11 sphinxcontrib_devhelp-1.0.1.dist-info/
-rw-r--r--    1 root       admin   574B 21 Sep 18:11 sphinxcontrib_htmlhelp-1.0.2-py3.7-nspkg.pth
drwxr-xr-x    9 root       admin   288B 21 Sep 18:11 sphinxcontrib_htmlhelp-1.0.2.dist-info/
-rw-r--r--    1 root       admin   574B 21 Sep 18:11 sphinxcontrib_jsmath-1.0.1-py3.7-nspkg.pth
drwxr-xr-x    9 root       admin   288B 21 Sep 18:11 sphinxcontrib_jsmath-1.0.1.dist-info/
-rw-r--r--    1 root       admin   574B 21 Sep 18:11 sphinxcontrib_qthelp-1.0.2-py3.7-nspkg.pth
drwxr-xr-x    9 root       admin   288B 21 Sep 18:11 sphinxcontrib_qthelp-1.0.2.dist-info/
-rw-r--r--    1 root       admin   574B 21 Sep 18:11 sphinxcontrib_serializinghtml-1.1.3-py3.7-nspkg.pth
drwxr-xr-x    9 root       admin   288B 21 Sep 18:11 sphinxcontrib_serializinghtml-1.1.3.dist-info/
drwxr-xr-x   26 root       admin   832B 29 Oct 10:35 sqlalchemy/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:26 sqlalchemy_schemadisplay-1.3.dist-info/
-rw-r--r--    1 root       admin   8.7K 24 Oct 16:26 sqlalchemy_schemadisplay.py
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 terminado/
drwxr-xr-x    7 root       admin   224B 21 Sep 20:28 terminado-0.8.2.dist-info/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 testpath/
drwxr-xr-x    7 root       admin   224B 21 Sep 20:28 testpath-0.4.2.dist-info/
drwxr-xr-x   10 markamery  admin   320B 28 Oct 18:24 tests/
drwxr-xr-x   14 root       admin   448B 24 Oct 16:27 tinycss2/
drwxr-xr-x    8 root       admin   256B 24 Oct 16:27 tinycss2-1.0.2.dist-info/
drwxr-xr-x    7 root       admin   224B 24 Oct 16:27 tls_syslog-0.2.0.dist-info/
drwxr-xr-x    7 root       admin   224B 24 Oct 16:27 tlssyslog/
drwxr-xr-x   37 root       admin   1.2K 21 Sep 20:28 tornado/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 tornado-6.0.3.dist-info/
drwxr-xr-x   21 markamery  admin   672B 28 Oct 18:27 tqdm/
drwxr-xr-x    9 markamery  admin   288B 28 Oct 18:27 tqdm-4.36.1.dist-info/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 traitlets/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 traitlets-4.3.2.dist-info/
drwxr-xr-x   15 markamery  admin   480B 28 Oct 18:27 twine/
drwxr-xr-x    9 markamery  admin   288B 28 Oct 18:27 twine-2.0.0.dist-info/
drwxr-xr-x   10 root       admin   320B 29 Oct 10:24 typed_ast/
drwxr-xr-x    7 root       admin   224B 29 Oct 10:24 typed_ast-1.4.0.dist-info/
drwxr-xr-x    8 markamery  admin   256B 28 Oct 18:23 typing_extensions-3.7.4.1.dist-info/
-rw-r--r--    1 markamery  admin    74K 28 Oct 18:23 typing_extensions.py
drwxr-xr-x    8 root       admin   256B 24 Oct 16:26 uWSGI-2.0.18.dist-info/
drwxr-xr-x    7 root       admin   224B 24 Oct 16:26 uritemplate/
drwxr-xr-x    9 root       admin   288B 24 Oct 16:26 uritemplate-3.0.0.dist-info/
drwxr-xr-x   16 root       admin   512B 20 Sep 17:38 urllib3/
drwxr-xr-x   10 root       admin   320B 20 Sep 17:38 urllib3-1.23.dist-info/
-rw-r--r--    1 root       admin    10K 24 Oct 16:26 uwsgidecorators.py
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 wcwidth/
drwxr-xr-x   10 root       admin   320B 21 Sep 20:28 wcwidth-0.1.7.dist-info/
drwxr-xr-x   21 root       admin   672B 29 Oct 10:35 weasyprint/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 webencodings/
drwxr-xr-x    9 root       admin   288B 21 Sep 20:28 webencodings-0.5.1.dist-info/
drwxr-xr-x   27 root       admin   864B 29 Oct 10:36 werkzeug/
drwxr-xr-x   19 markamery  admin   608B 13 Sep 20:12 wheel/
drwxr-xr-x    9 markamery  admin   288B 15 Sep  2018 wheel-0.31.1-py3.7.egg-info/
drwxr-xr-x    9 markamery  admin   288B 13 Sep 20:12 wheel-0.33.4-py3.7.egg-info/
drwxr-xr-x    6 root       admin   192B 21 Sep 20:28 widgetsnbextension/
drwxr-xr-x    8 root       admin   256B 21 Sep 20:28 widgetsnbextension-3.5.1.dist-info/
drwxr-xr-x   77 root       admin   2.4K 29 Oct 10:30 wx/
drwxr-xr-x    9 root       admin   288B 29 Oct 10:30 wxPython-4.0.7.dist-info/
drwxr-xr-x   20 root       admin   640B 24 Oct 16:27 yaml/
drwxr-xr-x   75 root       admin   2.3K 29 Oct 10:25 yoctopuce/
drwxr-xr-x    8 root       admin   256B 29 Oct 10:25 yoctopuce-1.10.37304.dist-info/
drwxr-xr-x   20 root       admin   640B 21 Sep 20:28 zmq/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~%tocore-1.12.253.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~-2/
drwxr-xr-x  102 markamery  admin   3.2K 24 Oct 16:26 ~-L/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~-LAlchemy-1.3.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 16 Sep 15:45 ~-ake8-3.7.7.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~-ask-1.0.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~-asyPrint-47.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~-ctopuce-1.10.35153.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~-embic-1.0.10.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~-fluxdb-5.2.2.dist-info/
drwxr-xr-x    9 markamery  admin   288B 21 Sep 18:11 ~-hinx-2.2.0.dist-info/
drwxr-xr-x    4 markamery  admin   128B 24 Oct 16:26 ~-iclient/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~-ikit_image-0.15.0.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~-ipy-1.3.0.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~-mpy-1.16.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~-ndas-0.24.2.dist-info/
drwxr-xr-x    9 markamery  admin   288B 16 Sep 15:49 ~-nja2-2.10.1.dist-info/
drwxr-xr-x   70 markamery  admin   2.2K 24 Oct 16:26 ~-o/
drwxr-xr-x    7 markamery  admin   224B 16 Sep 15:45 ~-ped_ast-1.3.5.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~-rkzeug-0.15.4.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~-so8601-2.1.1.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~-tocore-1.12.253.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~-tplotlib-3.0.3.dist-info/
drwxr-xr-x   11 markamery  admin   352B 24 Oct 16:26 ~-tz-2019.1.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~-util-5.6.2.dist-info/
drwxr-xr-x   77 markamery  admin   2.4K 24 Oct 16:27 ~-wx/
drwxr-xr-x    7 markamery  admin   224B 24 Oct 16:27 ~-ycopg2-2.8.2-py3.7.egg-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~.tocore-1.12.253.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~=tocore-1.12.253.dist-info/
drwxr-xr-x  102 markamery  admin   3.2K 24 Oct 16:26 ~IL/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~QLAlchemy-1.3.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~andas-0.24.2.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~atplotlib-3.0.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~cikit_image-0.15.0.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~cipy-1.3.0.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~easyPrint-47.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~erkzeug-0.15.4.dist-info/
drwxr-xr-x    9 markamery  admin   288B 16 Sep 15:49 ~inja2-2.10.1.dist-info/
drwxr-xr-x   70 markamery  admin   2.2K 24 Oct 16:26 ~io/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~iso8601-2.1.1.dist-info/
drwxr-xr-x    9 markamery  admin   288B 16 Sep 15:45 ~lake8-3.7.7.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~lask-1.0.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~lembic-1.0.10.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~nfluxdb-5.2.2.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~octopuce-1.10.35153.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~otocore-1.12.253.dist-info/
drwxr-xr-x    9 markamery  admin   288B 21 Sep 18:11 ~phinx-2.2.0.dist-info/
drwxr-xr-x    4 markamery  admin   128B 24 Oct 16:26 ~piclient/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~sutil-5.6.2.dist-info/
drwxr-xr-x    7 markamery  admin   224B 24 Oct 16:27 ~sycopg2-2.8.2-py3.7.egg-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~umpy-1.16.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~v2/
drwxr-xr-x   77 markamery  admin   2.4K 24 Oct 16:27 ~wx/
drwxr-xr-x   77 markamery  admin   2.4K 24 Oct 16:27 ~x/
drwxr-xr-x    7 markamery  admin   224B 16 Sep 15:45 ~yped_ast-1.3.5.dist-info/
drwxr-xr-x   11 markamery  admin   352B 24 Oct 16:26 ~ytz-2019.1.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~~2/
drwxr-xr-x  102 markamery  admin   3.2K 24 Oct 16:26 ~~L/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~~LAlchemy-1.3.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 16 Sep 15:45 ~~ake8-3.7.7.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~~ask-1.0.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~~asyPrint-47.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~~ctopuce-1.10.35153.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~~embic-1.0.10.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~~fluxdb-5.2.2.dist-info/
drwxr-xr-x    9 markamery  admin   288B 21 Sep 18:11 ~~hinx-2.2.0.dist-info/
drwxr-xr-x    4 markamery  admin   128B 24 Oct 16:26 ~~iclient/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~~ikit_image-0.15.0.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~~ipy-1.3.0.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~~mpy-1.16.3.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:27 ~~ndas-0.24.2.dist-info/
drwxr-xr-x    9 markamery  admin   288B 16 Sep 15:49 ~~nja2-2.10.1.dist-info/
drwxr-xr-x   70 markamery  admin   2.2K 24 Oct 16:26 ~~o/
drwxr-xr-x    7 markamery  admin   224B 16 Sep 15:45 ~~ped_ast-1.3.5.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~~rkzeug-0.15.4.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~~so8601-2.1.1.dist-info/
drwxr-xr-x    9 markamery  admin   288B 24 Oct 16:26 ~~tocore-1.12.253.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:26 ~~tplotlib-3.0.3.dist-info/
drwxr-xr-x   11 markamery  admin   352B 24 Oct 16:26 ~~tz-2019.1.dist-info/
drwxr-xr-x    8 markamery  admin   256B 24 Oct 16:27 ~~util-5.6.2.dist-info/
drwxr-xr-x    7 markamery  admin   224B 24 Oct 16:27 ~~ycopg2-2.8.2-py3.7.egg-info/

Description
As a consequence of the above, when I run pip3 freeze, I get a whole load of seemingly nonsensical warnings:

Warnings output
WARNING: Could not generate requirement for distribution -ycopg2 2.8.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ycopg2='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -util 5.6.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-util==5'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -tz 2019.1 (/usr/local/lib/python3.7/site-packages): Parse error at "'-tz==201'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -tplotlib 3.0.3 (/usr/local/lib/python3.7/site-packages): Parse error at "'-tplotli'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -tocore 1.12.253 (/usr/local/lib/python3.7/site-packages): Parse error at "'-tocore='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -so8601 2.1.1 (/usr/local/lib/python3.7/site-packages): Parse error at "'-so8601='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -rkzeug 0.15.4 (/usr/local/lib/python3.7/site-packages): Parse error at "'-rkzeug='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -ped-ast 1.3.5 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ped-ast'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -nja2 2.10.1 (/usr/local/lib/python3.7/site-packages): Parse error at "'-nja2==2'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -ndas 0.24.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ndas==0'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -mpy 1.16.3 (/usr/local/lib/python3.7/site-packages): Parse error at "'-mpy==1.'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -LAlchemy 1.3.3 (/usr/local/lib/python3.7/site-packages): Parse error at "'-LAlchem'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -ipy 1.3.0 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ipy==1.'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -ikit-image 0.15.0 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ikit-im'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -hinx 2.2.0 (/usr/local/lib/python3.7/site-packages): Parse error at "'-hinx==2'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -fluxdb 5.2.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-fluxdb='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -embic 1.0.10 (/usr/local/lib/python3.7/site-packages): Parse error at "'-embic=='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -ctopuce 1.10.35153 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ctopuce'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -asyPrint 47 (/usr/local/lib/python3.7/site-packages): Parse error at "'-asyPrin'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -ask 1.0.3 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ask==1.'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -ake8 3.7.7 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ake8==3'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -ytz 2019.1 (/usr/local/lib/python3.7/site-packages): Parse error at "'-ytz==20'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -yped-ast 1.3.5 (/usr/local/lib/python3.7/site-packages): Parse error at "'-yped-as'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -umpy 1.16.3 (/usr/local/lib/python3.7/site-packages): Parse error at "'-umpy==1'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -.tocore 1.12.253 (/usr/local/lib/python3.7/site-packages): Parse error at "'-.tocore'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -sycopg2 2.8.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-sycopg2'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -sutil 5.6.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-sutil=='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -QLAlchemy 1.3.3 (/usr/local/lib/python3.7/site-packages): Parse error at "'-QLAlche'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -phinx 2.2.0 (/usr/local/lib/python3.7/site-packages): Parse error at "'-phinx=='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -otocore 1.12.253 (/usr/local/lib/python3.7/site-packages): Parse error at "'-otocore'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -octopuce 1.10.35153 (/usr/local/lib/python3.7/site-packages): Parse error at "'-octopuc'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -nfluxdb 5.2.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-nfluxdb'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -lembic 1.0.10 (/usr/local/lib/python3.7/site-packages): Parse error at "'-lembic='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -lask 1.0.3 (/usr/local/lib/python3.7/site-packages): Parse error at "'-lask==1'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -lake8 3.7.7 (/usr/local/lib/python3.7/site-packages): Parse error at "'-lake8=='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -iso8601 2.1.1 (/usr/local/lib/python3.7/site-packages): Parse error at "'-iso8601'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -inja2 2.10.1 (/usr/local/lib/python3.7/site-packages): Parse error at "'-inja2=='": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution - 2.8.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-==2.8.2'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -erkzeug 0.15.4 (/usr/local/lib/python3.7/site-packages): Parse error at "'-erkzeug'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -easyPrint 47 (/usr/local/lib/python3.7/site-packages): Parse error at "'-easyPri'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -cipy 1.3.0 (/usr/local/lib/python3.7/site-packages): Parse error at "'-cipy==1'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -cikit-image 0.15.0 (/usr/local/lib/python3.7/site-packages): Parse error at "'-cikit-i'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -atplotlib 3.0.3 (/usr/local/lib/python3.7/site-packages): Parse error at "'-atplotl'": Expected W:(abcd...)
WARNING: Could not generate requirement for distribution -andas 0.24.2 (/usr/local/lib/python3.7/site-packages): Parse error at "'-andas=='": Expected W:(abcd...)

@cjerdonek's change at #6538 improves this slightly (previously there was no clue that these weird names referred to anything in the site-packages directory), but as a naive user this I'm still left unsure what I'm being told or what to do about it. When encountering this message, I'm left adrift in a couple of ways:

  1. The new message falls short of explicitly stating that the warning was triggered by a folder with a weird name in the site-packages directory. It mentions the directory, and mentions the weird name, and then leaves me to guess.
  2. The name given isn't even a perfect match for anything in the site-packages directory! The subdirectories triggering the errors start with a ~, but in the error message that ~ has somehow shapeshifted into a -.
  3. Even if I correctly infer that the weird subfolders in my site-packages directory somehow relate to this error message despite the above hurdles, I'm still left confused and guessing about what that implies. Why are they there at all? Should I delete them or is that going to break my Python installation somehow? Is something horribly corrupted and do I need to reinstall Python? The error message gives me no guidance; it suggests that something is wrong with the fact that these folders exist, but that's all the help I get.

(The answer to my rhetorical questions in point 3 is that they're temporary folders created by Pip, possibly left behind when I killed a Pip process previously before it could clean up, and that deleting them is safe. But I'm not sure how I could've found this out without stumbling across this Stack Overflow answer.)

It's got to be possible to avoid confusing and worrying the user in this way.

A possible easy fix

Make pip freeze ignore ~-prefixed folders without logging a warning. From what I understand from https://stackoverflow.com/a/57488427/1709587, ~-prefixed directories are guaranteed to be temporary directories. So just treat them like they don't exist in freeze.

A possible harder fix

Attack the root cause by ensuring that these temporary directories eventually get cleaned up properly, even if a pip process gets uncleanly killed. I see two strategies for this:

  • Check for their presence and attempt cleanup on every pip invocation, even if the command is to do something unrelated (similarly to how git, by default, sometimes decides to run garbage collection on the objects in your local repo).
  • Use the OS's temp directory (e.g. via Python's builtin tempfile module) instead

(I'm throwing both these ideas out naively, without much understanding of Pip's internals; I apologise if either of them is stupid for a reason I'm not seeing.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions