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 christian.heimes
Recipients christian.heimes
Date 2018-04-11.10:28:49
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
The shlex module implements simple tokenize for a shell-like mini language. The shlex.split() function splits a string into subcomponents just like a typical Unix shell. However function has a surprising feature. When None is passed into shlex.split().

Note: Since the split() function instantiates a shlex instance, passing None for s will read the string to split from standard input.

This is both surprising, unnecessary and potentially dangerous. Reading from sys.stdin is a blocking operation. In case an application doesn't account for None, shlex.split(value) could lead to a blocked server application. I suggest to deprecate and eventually remove this mis-feature.

Credits: David R. MacIver reported the bug on Twitter:
Date User Action Args
2018-04-11 10:28:49christian.heimessetrecipients: + christian.heimes
2018-04-11 10:28:49christian.heimessetmessageid: <>
2018-04-11 10:28:49christian.heimeslinkissue33262 messages
2018-04-11 10:28:49christian.heimescreate