diff options
author | Gregory P. Smith <greg@krypto.org> | 2021-06-02 21:15:26 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-02 21:15:26 -0700 |
commit | 5a8ddcc4524dca3880d7fc2818814ffae1cfb8a2 (patch) | |
tree | dd41018682a99af6c4725af4c97f63aa67138db1 /Python/Python-ast.c | |
parent | 5df4abd6b033a5f1e48945c6988b45e35e76f647 (diff) | |
download | cpython-git-5a8ddcc4524dca3880d7fc2818814ffae1cfb8a2.tar.gz |
[3.9] bpo-43776: Remove list call from args in Popen repr (GH-25338) (GH-26510)
Removes the `list` call in the Popen `repr`.
Current implementation:
For cmd = `python --version`, with `shell=True`.
```bash
<Popen: returncode: None args: ['p', 'y', 't', 'h', 'o', 'n', ' ', '-', '-',...>
```
For `shell=False` and args=`['python', '--version']`, the output is correct:
```bash
<Popen: returncode: None args: ['python', '--version']>
```
With the new changes the `repr` yields:
For cmd = `python --version`, with `shell=True`:
```bash
<Popen: returncode: None args: 'python --version'>
```
For `shell=False` and args=`['python', '--version']`, the output:
```bash
<Popen: returncode: None args: ['python', '--version']>
```
Automerge-Triggered-By: GH:gpshead.
(cherry picked from commit db0c5b786df961785ae8c803f5572ae0c8dadcc7)
Co-authored-by: M. Kocher <michael.kocher@me.com>
Co-authored-by: M. Kocher <michael.kocher@me.com>
Diffstat (limited to 'Python/Python-ast.c')
0 files changed, 0 insertions, 0 deletions