And another thing... (was Re: Interleaved commands ...)

Magnus Lie Hetland mlh at furu.idi.ntnu.no
Wed Jan 22 22:01:54 EST 2003


In article <slrnb2um1o.bp7.mlh at furu.idi.ntnu.no>, Magnus Lie Hetland wrote:
[snip]
>It seems that one way of doing this sort of thing would be to
>use callbacks for the options,

Section 6.20 of the docs says that one only has to specify the
callback argument, as in:

  parser.add_option("-c", callback=my_callback)

This doesn't seem to work (might be nice if add_option understood that
I wanted action='callback' when I supplied a callback ;). In 6.20.4.4,
the version with action='callback' is presented. I suppose this is a
documentation bug in 6.20?

-- 
Magnus Lie Hetland
http://hetland.org




More information about the Python-list mailing list