optparse.py: FutureWarning error

Terry Reedy tjreedy at udel.edu
Thu Jun 2 18:31:29 EDT 2005


"kosuke" <kevin at rustybear.com> wrote in message 
news:1117722584.910599.242900 at g47g2000cwa.googlegroups.com...
>I keep getting the following error/warning message when using the
> python based program getmail4:
>
> /usr/lib/python2.3/optparse.py:668: FutureWarning: %u/%o/%x/%X of
> negative int will return a signed string in Python 2.4 and up
>  return ("<%s at 0x%x: %r>"
>
> I'm using python2.3.5 on a debian sid box.
>
> The getmail4 website/FAQ maintains that this is a bug in the optparse
> module.
>
> Any idea on how to resolve this?

a) Learn to live with it ;-)
b) Upgrade to 2.4 (if getmail4 will run with it)
c) Check to see if Python has a startup option for suppressing warnings

As to c) python -h gives a list indicating what I thought, that -W controls 
warnings, but gives insufficient info for me to use it, and I didn't find 
any more in the docs.  I hope someone else chimes in.

Terry J. Reedy


Terry J. Reedy






More information about the Python-list mailing list