[issue41534] argparse : allow_abbrev behavior between 3.7 and 3.8

2022-01-10 Thread Steve Fox
Steve Fox added the comment: Fundamentally the use of allow_abbrev=False is now broken (it is allowing abbreviations when already explicitly told not to) The use of a single - for all options is much older than -- and exists in my unix utilities and many programs have been written to follow

[issue41534] argparse : allow_abbrev behavior between 3.7 and 3.8

2020-09-01 Thread paul j3
paul j3 added the comment: I'm going to close this. 3.8 works as expected/documented, provided we use the normal double dash protocol for long options. Single dash is best reserved for single character options, where chaining is allowed. -- stage: -> resolved status: open -> clos

[issue41534] argparse : allow_abbrev behavior between 3.7 and 3.8

2020-08-24 Thread paul j3
paul j3 added the comment: In your first example: In [29]: parser = argparse39.ArgumentParser(allow_abbrev=True) In [30]: parser.add_argument('-o'); In [32]: parser.parse_known_args(['-o','test'])

[issue41534] argparse : allow_abbrev behavior between 3.7 and 3.8

2020-08-24 Thread r1kk3r
r1kk3r added the comment: Another issue: parser = argparse.ArgumentParser(allow_abbrev=False) parser.add_argument('-verbose', type=int, required=True, dest="bla", help="bla") known_args, rest_of_args = parser.parse_known_args(["-v", "-verbose=2"]) With python 3.8.5 test.py: error: argument -

[issue41534] argparse : allow_abbrev behavior between 3.7 and 3.8

2020-08-13 Thread Ned Deily
Change by Ned Deily : -- nosy: +petr.viktorin ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.py

[issue41534] argparse : allow_abbrev behavior between 3.7 and 3.8

2020-08-12 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: Bisection tells me this was introduced with commit b1e4d1b6032d4c82b549233fa08a2c7cfe7e818b in issue26967 -- nosy: +xtreak ___ Python tracker

[issue41534] argparse : allow_abbrev behavior between 3.7 and 3.8

2020-08-12 Thread hai shi
Change by hai shi : -- nosy: +paul.j3, rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue41534] argparse : allow_abbrev behavior between 3.7 and 3.8

2020-08-12 Thread r1kk3r
New submission from r1kk3r : I looked into changelog and the source code to see if the behavior was wanted but I was not able to see the source of the issue. import argparse parser = argparse.ArgumentParser(allow_abbrev=True) parser.add_argument('-o', type=str, required=True, dest="bla", help=