Serhiy Storchaka <storchaka+cpyt...@gmail.com> added the comment:

Yes, this is expected. bool('False') is True.

You can write your own converter which returns True for 'True', False for 
'False' and raise an exception otherwise.

But it is more common to add a pair of options without arguments 
--foo/--no-foo, or --with-foo/--without-foo, or --enable-foo/--disable-foo 
using the "store_const" action with True/False value.

----------
nosy: +serhiy.storchaka
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue36358>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to