[Distutils] Using Wheel with zipimport

Daniel Holth dholth at gmail.com
Wed Jan 29 14:43:25 CET 2014


On Wed, Jan 29, 2014 at 8:31 AM, Donald Stufft <donald at stufft.io> wrote:
>
> On Jan 29, 2014, at 8:10 AM, Paul Moore <p.f.moore at gmail.com> wrote:
>
>> On 29 January 2014 12:58, Nick Coghlan <ncoghlan at gmail.com> wrote:
>>> You can campaign to deprecate that feature *if* we ever want to make a
>>> change to the wheel format that is incompatible with it.
>>
>> Note that virtualenv uses the ability to run wheels from sys.path. I
>> don't believe that virtualenv should be a "special exception" here,
>> nor do I want it to rely on accidents of the implementation.
>>
>> So from my POV, pypa is already shipping code that relies on this
>> behaviour being by design.
>>
>> Paul
>
>
> Here's Paul explicitly mentioning that Wheels being used with zip import is
> an incidental benefit and not a core feature.
>
> https://mail.python.org/pipermail/distutils-sig/2013-March/020379.html

I designed it very intentionally to be compatible with zip import.
Otherwise wheels would probably not even be zip files (like pypm
packages which are tar) and would achieve greater compression.

It may be useful to understand that wheel has *political features* or
if you prefer *setting the defaults based on what we have learned from
eggs*. I don't recommend that they be zip-imported generally but if
you are a consenting adult who understands the caveats you may do so.


More information about the Distutils-SIG mailing list