James Bennett wrote:
> On Thu, Sep 17, 2009 at 5:23 AM, Chris Withers <ch...@simplistix.co.uk> wrote:
>> Well, I'm certainly not setuptools-happy, but Django appears to be
>> wrapped up as a standard distribution on PyPI (sorry, should have said
>> distro, not egg), so it would make sense to use that...
> 
> Putting on my release-manager hat for a moment, I'll note that we
> currently *only* provide a source package and not an egg, and that's
> likely to remain the case for the foreseeable future, because Django
> is flat-out not zip-safe and probably never will be. 

zip-safe != egg.

Using zipped eggs is something I hate and tell buildout not to do.
That said, if in doubt, buildout/setuptools/etc always unzip eggs anyway.

I feel I should point out that buildout/setuptools/etc work fine with 
source distributions, provided they play the game properly
(ie: "python setup.py install" does) and don't do anything too 
outlandish. Having had a read of Django's setup.py, I can't see anything 
that would cause problems...

 > As such, I'd
> strongly recommend against ever trying to install Django as an egg.

...even as an egg ;-)

> Django *applications* also are not normally safe to install as eggs.

I think you have an overly paranoid view of eggs. It's just a packaging 
mechanism. I'd be pretty surprised to find at application that couldn't 
be packaged as an egg. What makes you feel this wouldn't work or be safe 
to do?

> Some parts of Django can handle the bizarre alternate reality
> setuptools creates (e.g., there's a template loader which knows how to
> look for templates inside eggs), but other parts can't (custom
> management commands will completely break, for example).

All of your problems seem to center on zipped eggs. These are evil 
things anyway, and can be avoided by simply putting zip_safe=False as a 
parameter to setuptools (whether it actually comes from setuptools, or 
if it comes from the maintained fork, distribute). Buildout event has a 
config options to say "I don't care whether the egg thinks it's zip safe 
or not, unzip it!" ;-)

The real benefits come in being able to specify what versions of what 
other packages your package depends on, whether any of them use 
setuptools or distutils to create their packages, and being able to 
manage those dependencies with tools like buildout, so you get simple, 
easy and sane ways to reproduce whole project or even machine setups...

I find the need to only do:

python bootstrap.py && ./bin/buildout

..to get a completely set up and rigidly controlled environment pretty 
powerful.

cheers,

Chris

-- 
Simplistix - Content Management, Batch Processing & Python Consulting
            - http://www.simplistix.co.uk

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to