This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author max
Recipients max
Date 2019-01-20.10:23:14
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1547979795.17.0.450145238356.issue35787@roundup.psfhosted.org>
In-reply-to
Content
I believe in both cases below, the ouptu should be ['a', 'b']; the extra ' ' inserted in the list is incorrect:

python3.6
Python 3.6.2 (default, Aug  4 2017, 14:35:04)
[GCC 6.3.0 20170516] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import shlex
>>> shlex.split('a \ b')
['a', ' b']
>>> shlex.split('a \  b')
['a', ' ', 'b']
>>>

Doc reference: https://docs.python.org/3/library/shlex.html#parsing-rules
> Non-quoted escape characters (e.g. '\') preserve the literal value of the next character that follows;

I believe this implies that backslash space should be just space; and then two adjacent spaces should be used (just like a single space) as a separator between arguments.
History
Date User Action Args
2019-01-20 10:23:18maxsetrecipients: + max
2019-01-20 10:23:15maxsetmessageid: <1547979795.17.0.450145238356.issue35787@roundup.psfhosted.org>
2019-01-20 10:23:15maxlinkissue35787 messages
2019-01-20 10:23:14maxcreate