[New-bugs-announce] [issue42499] python not correctly processing double quotes in command line args in windows

Vikram Pal report at bugs.python.org
Sun Nov 29 00:33:58 EST 2020


New submission from Vikram Pal <vikram.invincible.pal4 at gmail.com>:

Using PowerShell in Windows, double quotes in argument given with "-c" flag to python does not work. E.g.

> Write-Host 's = "fn main() {"; s += "\n".join("let x = 0;" for _ in range(2)); s+= "}"; print(s)'
s = "fn main() {"; s += "\n".join("let x = 0;" for _ in range(6000)); s+= "}"; print(s)

> python -c 's = "fn main() {"; s += "\n".join("let x = 0;" for _ in range(2)); s+= "}"; print(s)'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
NameError: name 'fn' is not defined

----------
components: Windows
messages: 382039
nosy: paul.moore, steve.dower, tim.golden, vikram.invincible.pal4, zach.ware
priority: normal
severity: normal
status: open
title: python not correctly processing double quotes in command line args in windows
type: behavior
versions: Python 3.9

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue42499>
_______________________________________


More information about the New-bugs-announce mailing list