At 10:17 AM 2/3/2011 -0500, Matt Chaput wrote:
When I create an egg the Python version used to create the egg is encoded in the egg filename, e.g. Whoosh-1.6.0-py2.7.egg.

Is this version number used to decide what egg a user gets from PyPI? I didn't think it was, but a user is seeming to indicate that he got different versions based on what version of Python he was using.

Is there a way to set this value to "py2.5" as a configuration option, other than running setup.py using the Python 2.5 executable? Or not have it be part of the egg filename at all? I'm using Python 2.7 as my default Python install but I make sure that the code in my library is compatible with 2.5+. I've already someone think the library is only for a later version of Python because that's what I used to build the egg.

Sorry if this is an old question, I looked around but didn't find any docs on the subject.

I see you've already solved your issue by using source distributions, but for the archives I thought I should mention that the reason eggs are version specific is because they contained compiled .pyc or .pyo files, and those are only compatible with the Python version that compiled them.

If you are distributing pure Python code through PyPI, though, there is usually no reason to ship it in an egg. Eggs were designed as a binary plugin format for rich application platforms, analagous to Java "jars" or Eclipse plugins. They're intended for scenarios where installing from source is overly complex and/or you want to make it so users can just drop a file into a plugin directory to get going. (easy_install came later, as a quick hack to automate building and installing eggs.)

_______________________________________________
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig

Reply via email to