[Distutils] setuptools patch for egg_info.get_svn_revision; max() doesn't like an empty list

Kumar McMillan kumar.mcmillan at gmail.com
Fri Jan 5 05:22:31 CET 2007

hi folks.
I looked high and low for an official spot to submit setuptools
patches but just found this mailing list.  Please accept my apologies
in advance if this is inconvenient.

I found that when running setup.py commands on an svn checkout while
having just added a directory, but not committed it yet, I would get
"ValueError: max() arg is an empty sequence" from around line 227 of
egg_info.py.  This seems easily fixable by checking the length of
all_revs before handing it to max() and the patch attached solves the
problem I was having.  After applying the patch to the source, `python
setup.py test` ran ok.

thanks, Kumar
-------------- next part --------------
A non-text attachment was scrubbed...
Name: setuptools.r52354.get_svn_revision.patch
Type: application/octet-stream
Size: 935 bytes
Desc: not available
Url : http://mail.python.org/pipermail/distutils-sig/attachments/20070104/6d86dd68/attachment.obj 

More information about the Distutils-SIG mailing list