[Distutils] Having a Python package install itself under a different name

cool-RR cool-rr at cool-rr.com
Thu May 27 23:16:44 CEST 2010


On Thu, May 27, 2010 at 11:03 PM, P.J. Eby <pje at telecommunity.com> wrote:

> At 10:40 PM 5/27/2010 +0200, cool-RR wrote:
>
>> Is there a way that `garlicsim_py3` will install itself under the alias
>> `garlicsim`? What I want is for a Python 3 user to be able to `import
>> garlicsim` and refer to the module all the time as `garlicsim`, but that it
>> will really be `garlicsim_py3`.
>>
>
> Why not just develop them both with the same package name?  Your project
> name (in setup(name='...')) can still be different.
>
>
Oh, I didn't even know that was possible. That sounds great, and I wish I
would have known about this option 6 months ago.

If this works well, I'll start converting my entire codebase to this method.
Before I jump in, is there anything important I should keep in mind, any
possible problems?

Also, this is plain setuptools, right? I mean, not requiring Distribute.

Ram.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/distutils-sig/attachments/20100527/3ed4dda5/attachment.html>


More information about the Distutils-SIG mailing list