Walter Mundt <waltermu...@codethink.info> added the comment:

Attached is a patch to fix this bug by deferring matching of nargs='*' argument 
against a zero-length pattern until the end of the arguments list.

I believe that it ought to be maximally conservative in that it should not 
change the behavior of any existing parsers except in cases where it allows 
them to accept arguments they would previously have left unrecognized in cases 
like the test in the initial report.

----------
keywords: +patch
Added file: http://bugs.python.org/file26097/argparse_fix_empty_nargs_star.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue15112>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to