Nick Coghlan <ncogh...@gmail.com> added the comment: I believe the main argument for -X options is the fact that cmd on Windows doesn't offer a nice way of setting environment variables as part of the command invocation (hence "-X utf8", for example).
As far as setting values for X options goes, `sys._xoptions` in CPython is a str:Union[bool,str] dict, with the command args split on "=": $ python3 -X arg=value -c "import sys; print(sys._xoptions)" {'arg': 'value'} If no value is given for the arg, then it's just set to the boolean True. The _xoptions entry shouldn't be the public API though - it's just a way of shuttling settings from the command line through to CPython-specific initialisation code. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue33499> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com