paul j3 <> added the comment:

This is another expression of the bigger problem of handling arguments that 
look like flags.  In optparse the 'nargs' (or equivalent, it doesn't handle 
positionals), control how many arguments an Option takes, regardless of their 
form.  In argparse, the distinction between a option (flag) and argument has 
priority.  So it is difficult to treat strings like '--def' as a plain 
argument.  The default behavior is to treat it as an optional flag.


Python tracker <>
Python-bugs-list mailing list

Reply via email to