Commit Graph

12 Commits

Author SHA1 Message Date
Éric Araujo 229011d949 Make a number of small changes to ease the backport to distutils2 2011-09-18 20:11:48 +02:00
Éric Araujo 37ccd6f794 Fix packaging.database.Distribution.list_distinfo_files (#12785).
This method was supposed to return only the file under the dist-info
directory, but it actually returned all installed files.

The tests didn’t catch this because they were flawed; I updated them.
Thanks to Nadeem Vawda and Jeremy Kloth for testing.

As a bonus, the removal of os.path.relpath use should also fix the
Windows buildbots.
2011-09-15 18:18:51 +02:00
Éric Araujo b931ab4345 Fix typo 2011-08-19 00:53:20 +02:00
Éric Araujo bab50cb124 Minor packaging cleanup.
- Use shortcut dist.version instead of going through metadata;
- Use %r throughout to display project names and paths.
2011-07-29 02:37:21 +02:00
Éric Araujo fe95848c16 Clear packaging.database caches in place 2011-07-15 17:47:46 +02:00
Éric Araujo 4468e55d4b Close file handles in a timely manner in packaging.database (#12504).
This fixes a bug with the remove (uninstall) feature on Windows.  Patch
by Thomas Holmes.
2011-07-08 17:22:19 +02:00
Éric Araujo 6f67765389 Stop binding sys.path as default parameter value in packaging.
The two public functions in database default to sys.path if the given
*paths* argument is None; the private functions don’t have default
values for their arguments anymore, which is fine as the public
functions that call them pass their arguments down.  Likewise in
install, the functions will pass down their *paths* arguments down to
database functions.

A one-line unneeded function in install was removed instead of being
changed, and the few remaining tests that used brute-force restoration
of sys.path have been cleaned up to use sys.path.remove.
2011-06-16 23:43:15 +02:00
Éric Araujo df8ef02488 Style change in packaging: use “not in” over “not x in”.
Such tests are IMO easier to read if both operators are grouped.
2011-06-08 04:47:13 +02:00
Tarek Ziade 43f289ad88 cleanup packaging.database 2011-05-30 11:07:54 +02:00
Tarek Ziade a17d8883fd a resource module for 2 functions is overkill. database is the right place for those 2011-05-30 10:57:44 +02:00
Tarek Ziade be20be1345 use the same line terminator everywhere 2011-05-21 19:45:48 +02:00
Tarek Ziade 1231a4e097 initial import of the packaging package in the standard library 2011-05-19 13:07:25 +02:00