I’ve been a fan of Paver since the first time I read about it. It gives
me all of the control I want with just enough of an implied structure to keep
things sane and easy. The problem was, I couldn’t get the latest version,
which had many shiny new features. You know how I feel about shiny, so
I obviously needed to find a way to run Paver’s trunk, lest I invalidate
my work by targeting the almost-irrelevant current version.

Paver is such a flexible tool, it can present a chicken-and-egg packaging
dilemma by relying heavily on itself to build… itself. The packaged
1.0a1 was having trouble installing via easy_install and pip so I
had to figure out a way to build my own package. Unfortunately Paver’s
trunk has neither paver-minilib.zip nor setup.py which means to
get things going, you have to use the current version of Paver. Of course,
the new alpha is so different, that the current release can’t handle it
and the build fails. I finally figured out a way to get a clean trunk
checkout installed and set out to squash the bug that got 1.0a1 recalled
in the first place.

After poking around for a while, I believe paver’s option parsing methods
are confusing distutils commands. It has to do with the way that options
are translated from the command line to Paver’s options. I updated
a relevant issue on Paver’s project page and attached a patch that fixes the
problem and allows Paver to build itself cleanly.

It becomes clear that cmdopts definitions will never override default
options for this task. We can’t use foo-bar as an option name in our
Bunch, nor could we access the runtime value using
options.show_opts.foo-bar. It turns out distutils and setuptools
already noticed this problem and convert hyphens to underscores when
determining the storage variable’s name for an option. I’ve attached a
small patch for Paver SVN r37 that automatically makes this conversion.

Hopefully 1.0 will come out soon, but until then you can download the patch
and apply it from within trunk:

$ patch -p0 -i options_fix.diff

http://www.blueskyonmars.com/ Kevin Dangoor

Wow, I was actually going to spend some time this evening looking into this problem (two other projects have been keeping me busy). I could tell it was something fairly simple with the passing of options, but I couldn’t tell exactly *what* was the matter in my few minutes of looking.

(Thank goodness for Google Alerts, otherwise I wouldn’t have noticed this. I didn’t realize all this time that googlecode doesn’t email me when a new issue is opened!)