1. Tarek Ziadé
  2. distribute
Issue #343 new

empty "data_files" dirs incorrectly added to --record logs

Marcus Smith
created an issue

if a project's setup.py has this:

   data_files=[('<DIR>', []),]

and you install like this (like pip does):

    python setup.py install --single-version-externally-managed --record=install.log

then <DIR> will end up in the install.log like so: <venv path>/<DIR>

then pip uses this log to perform uninstalls, and uninstalls the whole directory.

this is bad when it's something like "lib" on linux or "DLLS" on windows. see here for the real world scenario where this happened with the "shapely" package. https://github.com/pypa/pip/issues/727

based on the docs: http://docs.python.org/2/distutils/setupscript.html#distutils-additional-files I'm surmising that ('<DIR>', []) should result in no files, not all files

Comments (1)

  1. Log in to comment