Karthikeyan Singaravelan <tir.kar...@gmail.com> added the comment:
argparse allows abbreviations by default so --li matches --list as a prefix match. This is documented at https://docs.python.org/2.7/library/argparse.html#argument-abbreviations-prefix-matching >From python 3.5 allow_abbrev=False can be passed to ArgumentParser to disable >this. See also issue10981 and issue14910 that implemented this. >https://docs.python.org/3/library/argparse.html#argument-abbreviations-prefix-matching. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue37227> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com