Debugging automatic quotation in subprocess.Popen()
c.buhtz at posteo.jp
c.buhtz at posteo.jp
Fri Oct 7 04:38:40 EDT 2022
Hello,
I need to improve my understanding about how subprocess.Popen() does
quote arguments. I have special case here.
Simple example:
Popen(['ls', '-l']) results on a shell in "ls -l" without quotation.
Quotes are added if they are needed:
Popen(['ls', 'folder with blank']) results on a shell in
"ls 'folder with blank'".
Am I right so far with the basics?
Is there a way to be sure and to debug how Popen() give it to the shell?
More information about the Python-list
mailing list