In parse_known_args() consume_positionals()
the _.zip(positionals, argCounts)
behaves different from the python version when there aren't as many
argCounts as positionals. Python zip iterates over the shortest, the
underscore version over the longest, adding undefines as needed.
The if (argCounts.length>0) takes care of some cases, but parsing
'X -f A Y', where arguments are -a, x, and y, is another case where
this JS zip is wrong. At the start, there are 2 possible positional
actions [x, y], but only one [X] argument string.
Adding an argCount === undefined test is the simplest fix.
An alternative is to define a _zipShortest() as suggested in
I added a test case to base.js
I discovered this case when adapting 'TestArgumentsFromFile' from test_argparse.py