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.
Created on 2008年03月20日 20:38 by pbrandt, last changed 2022年04月11日 14:56 by admin. This issue is now closed.
| Messages (2) | |||
|---|---|---|---|
| msg64204 - (view) | Author: Patrick (pbrandt) | Date: 2008年03月20日 20:38 | |
When using wildcards as arguments to the processes being spawned by Popen, it seems to interpret them as hard literals. IE, when doing something like: >>> import subprocess >>> output = subprocess.Popen(['ls', '*'], stdout=subprocess.PIPE).communicate()[0] ls: *: No such file or directory >>> |
|||
| msg64228 - (view) | Author: Skip Montanaro (skip.montanaro) * (Python triager) | Date: 2008年03月21日 01:10 | |
The default for Popen objects is to not use the shell, thus no expansion. Set shell=True in the Popen call: >>> import subprocess >>> output = subprocess.Popen(['ls', '*']) >>> ls: *: No such file or directory >>> output = subprocess.Popen(['ls', '*'], shell=True) >>> configure.out svn-stat.out svn-update.out Skip |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:56:32 | admin | set | github: 46690 |
| 2008年03月21日 01:10:54 | skip.montanaro | set | status: open -> closed resolution: works for me messages: + msg64228 nosy: + skip.montanaro |
| 2008年03月20日 20:38:31 | pbrandt | create | |