New submission from Rob Dalton <robcdal...@gmail.com>:
Parsing an unknown optional argument whose leading characters (e.g. '--user') match those of another, known optional argument (e.g. '--userdata') causes the unknown argument to be parsed as the known one. For example - passing the unknown argument '--user' to a parser with the known argument '--userdata' assigns the passed '--user' value to '--userdata'. Here's my setup info: Python: Python 3.6.3 :: Anaconda custom (64-bit) OS: MacOS High Sierra 10.13.6 Wrote up some example cases here: https://gist.github.com/rob-dalton/9ec06b8d5e2e9083713ddc7884d16072 ---------- components: Library (Lib) messages: 326824 nosy: rob-dalton priority: normal severity: normal status: open title: Incorrect assignment of optional argument when partial match with different argument found. type: behavior versions: Python 3.6 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue34865> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com