[issue38570] Shlex does not parse commands containing single quotes correctly

2019-10-23 Thread timonegk


New submission from timonegk :

Steps to reproduce:
>>> from shlex import split
>>> line = "export F=$'\\''"
>>> split(line)
ValueError: No closing quotation

However, when printing the line

>>> print(line)
export F=$'\''

and pasting the output in bash, no further quotation marks are required.
The behavior of bash is described in its man page (line 497 for me, Chapter 
Quoting) and occurs also when bash is called with --posix. Therefore I guess 
that shlex does not reproduce the posix behavior here.

--
components: Library (Lib)
messages: 355265
nosy: timonegk
priority: normal
severity: normal
status: open
title: Shlex does not parse commands containing single quotes correctly
type: behavior
versions: Python 2.7, Python 3.7

___
Python tracker 
<https://bugs.python.org/issue38570>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue38570] Shlex does not parse commands containing single quotes correctly

2019-10-26 Thread timonegk


timonegk  added the comment:

Okay, thanks a lot. I am closing this since it is not a bug then.

--
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker 
<https://bugs.python.org/issue38570>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com