[Distutils] Bilingual namespace package conundrum

Donald Stufft donald at stufft.io
Thu Jan 1 22:57:35 CET 2015

> On Jan 1, 2015, at 4:54 PM, Barry Warsaw <barry at python.org> wrote:
> On Jan 01, 2015, at 03:20 PM, Tres Seaver wrote:
>> That sounds right to me.  I never really understood the motivation for
>> PEP 420, but if the presence of that file disables it, then it should
>> ensure the "old" behavior regardless.
> The motivation is described in the PEP, but briefly, on (many, most, all?)
> Linux distros any single file can be owned by exactly one system package.  So
> which package would own e.g. zope/__init__.py?
> Before PEP 420, the answer is "well, it's complicated".  After PEP 420, the
> answer is "no package, because that file doesn't exist".
> This is why the Debian tools delete any stray zope/__init__.py files when they
> are creating any zope.* binary package for Python 3.
> I think you're right that removing the version guard will make it work, but
> they won't be PEP 420 packages.  I don't think it's possible to make a
> bilingual package a pseudo-namespace package under Python 2, but a PEP 420
> namespace package under Python >= 3.3.
> Cheers,
> -Barry
> _______________________________________________
> Distutils-SIG maillist  -  Distutils-SIG at python.org
> https://mail.python.org/mailman/listinfo/distutils-sig

I’m pretty sure the problem with setup.py develop and setup.py install is because
they are installed as eggs more or less and setuptools probably doesn’t support it.
pip install <whatever> installs it unpacked so it’ll rely on built in importing.

Donald Stufft
PGP: 7C6B 7C5D 5E2B 6356 A926 F04F 6E3C BCE9 3372 DCFA

More information about the Distutils-SIG mailing list