Commit Graph

9 Commits

Author SHA1 Message Date
Ian Cordasco 2669f0c0b1 Fix when packages are unvendored
When working these changes back upstream to pip, we realized that the
previous fix wasn't ideal since unvendoring the packages broke the
imports. For example, if urllib3 were unvendored, then the following
would fail:

    from requests.packages import urllib3
2015-02-28 23:04:24 -06:00
Ian Cordasco 6ea3f2ada8 Only alias the imports for vendored dependencies
While discussion the issue, Donald Stufft (@dstufft) and I realized the
simplest solution is to simply add an alias per vendored dependency. The
resulting changes are simple and effective. It prevents the issue in
2.5.2 and 2.5.3 where the following would work:

    from requests.packages import webbrowser

This now appropriately raises an ImportError.

Closes #2465
2015-02-28 20:13:46 -06:00
Ian Cordasco da82fb4b1d Give proper attribution to pip 2014-12-12 21:12:31 -06:00
Ian Cordasco d615405519 Copy pip's import machinery wholesale 2014-12-08 20:48:40 -06:00
Kenneth Reitz 69e7e94c4c updated urllib3 2011-11-12 07:35:55 -08:00
Kenneth Reitz 34ca692c9c from __future__ import absolute_imports 2011-02-16 12:47:58 -05:00
Kenneth Reitz 4c192ec5ac absolute imports 2011-02-14 09:36:14 -05:00
Kenneth Reitz 127bbbb18d Worth a shot 2011-02-14 09:04:41 -05:00
Kenneth Reitz df419fa6fa vendorized poster 2011-02-14 08:55:55 -05:00