New submission from Trevor Meyerowitz <[EMAIL PROTECTED]>: There are two minor bugs in the example in: http://docs.python.org/lib/optparse-callback-example-6.html
For the optparse example documentation, the call to parser.add_option is listed as: parser.add_option("-c", "--callback", action="callback", callback=varargs) this has two bugs: 1. It refers to the wrong function name 2. It needs to have a dest variable defined, b/c the callback function operates on that. This can be fixed if the parser.add_option call is changed to: parser.add_option("-c", "--callback", action="callback", dest="foo", callback=varargs_callback) ---------- assignee: georg.brandl components: Demos and Tools, Documentation messages: 67709 nosy: georg.brandl, meyerowitz severity: normal status: open title: optparse documentation: variable arguments example doesn't work as listed type: behavior versions: Python 2.5 _______________________________________ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue3040> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com