[Zope3-Users] Re: buildout and egg depedencies

Martin Aspeli optilude at gmx.net
Wed Dec 12 17:07:20 EST 2007


Hi Jeff,

> How did it come to be that the Python tools are so bad at this?

To be fair, it's a hard problem. In Java land, you have similar problems 
with JARs in that they frequently have the same filename but different 
versions and there's no nice way that I know of to manage conflicts. 
Most Java projects I've worked on have had handful of ghost JARs - 
no-one knows where they come from, but they break something when removed 
and sometimes you get obscure errors like NoMethodDefFound when versions 
get out of sync...

> Setuptools is horrible when it comes to doing local
> (instance-home-ish) installations, requiring virtualenv or whatever.
> And I've had little success getting those to work. Maybe they just
> break my way of thinking about how Python does and should work.

virtualenv is reasonably easy in my experience (make sure you have the 
latest version), and reasonably natural (just use the binary in the env, 
not the global python binary).

> Whatever. Buildout looks like it tries to address many of those
> issues, but again I find myself fighting against my natural instincts.

I've been happy with buildout when I've used it in anger.

> Where's some end user documentation? 

The cheeseshop page for buildout is pretty decent, and I wrote 
http://plone.org/documentation/tutorial/buildout.

> The doc-test is difficult to read
> and speaks in generics, not about day-to-day problems. The Recipes are
> even worse, leaving one to clamor through the web to get back to the
> cheeseshop page and then face the same difficult to read doc-test kind
> of 'help'. Which I wouldn't mind reading, if I could easily read that
> help locally, like a man page or using Python's 'help()' system.
> ``buildout help zc.recipe.egg``, ``buildout help zc.recipe.cmmi``,
> whatever.

+1

In general, once you understand that recipes are just eggs, loaded with 
an entry point, and that options are passed around in dicts-of-dicts, I 
find buildout pretty easy to get to grips with.

> That I'm still frustrated by these tools all this time later is
> disappointing. And yes, it's easier to write your own. That's the
> Python way. Don't understand [zope, pylons, cherrypy, quixote,
> skunkweb]? Write your own web framework! Python does make it easy to
> do that because it's such a fantastic language. But I think that
> attitude, in turn, gives us worse tools, because everyone scratches
> their own itch and moves on, leaving everything incomplete. It seems
> almost like it's easier to write your own tool than to read whatever
> cryptic documentation exists for another.

Completely.

> I've gotten Buildout to work on some small components. It's great -
> check out the source, run buildout, wait, wait, wait, and then have a
> nice little self contained testing and development environment. But
> I've never been able to get a full Zope 3 "Application" up and running
> in that environment.

Have you looked at zopeproject (uses buildout) grokproject (uses 
buildout) or Repoze (uses virtualenv)?

> There's just no time and the tools are just too hard to learn under
> the circumstances my little company is operating in right now.
> Buildout *seems* like it could fix some big problems that have been
> hitting us hard in recent weeks. But I still can't wrap my head around
> how.

Maybe you should start a new thread and tell of your use cases and ask 
for examples of how to solve them?

Martin


-- 
Author of `Professional Plone Development`, a book for developers who
want to work with Plone. See http://martinaspeli.net/plone-book



More information about the Zope3-users mailing list