[issue40365] argparse: action "extend" with 1 parameter splits strings into characters

2020-06-09 Thread Jonathan Haigh
Jonathan Haigh added the comment: >> But I wonder, was this situation discussed in the original bug/issue? >Doesn't look like it: I was looking at the wrong PR link. This has more discussion: https://github.com/python/cpython/pull/13305. nargs is discussed but I'm not sure it was realized

[issue40365] argparse: action "extend" with 1 parameter splits strings into characters

2020-06-07 Thread Jonathan Haigh
Jonathan Haigh added the comment: The situation for type=int and unspecified nargs or nargs="?" is also surprising: Python 3.8.3 (default, May 21 2020, 12:19:36) [GCC 9.2.1 20191008] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import argparse >>> p =

[issue40365] argparse: action "extend" with 1 parameter splits strings into characters

2020-04-22 Thread paul j3
paul j3 added the comment: This is a consequence of Python's own definition of append vs extend In [730]: alist = [] In [731]: alist.append('astring')

[issue40365] argparse: action "extend" with 1 parameter splits strings into characters

2020-04-22 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +paul.j3, rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue40365] argparse: action "extend" with 1 parameter splits strings into characters

2020-04-22 Thread strjan
New submission from strjan : When positional argument with action='extend' is given to parse only one string argument, the string is splitted into individual characters. The problem occures, when no "nargs" is given; it makes sense that nargs is requiered, though at least notion in