mirror of
https://github.com/python/cpython.git
synced 2025-12-31 04:23:37 +00:00
gh-131038: Use text=True in subprocesses in test_perf_profiler (#137117)
(cherry picked from commit a852c7bdd4)
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
This commit is contained in:
parent
c9d9f78feb
commit
e709361fc8
1 changed files with 3 additions and 3 deletions
|
|
@ -283,6 +283,7 @@ def run_perf(cwd, *args, **env_vars):
|
|||
stdout=subprocess.PIPE,
|
||||
stderr=subprocess.PIPE,
|
||||
env=env,
|
||||
text=True,
|
||||
)
|
||||
if proc.returncode:
|
||||
print(proc.stderr)
|
||||
|
|
@ -295,10 +296,9 @@ def run_perf(cwd, *args, **env_vars):
|
|||
stderr=subprocess.PIPE,
|
||||
env=env,
|
||||
check=True,
|
||||
text=True,
|
||||
)
|
||||
return proc.stdout.decode("utf-8", "replace"), proc.stderr.decode(
|
||||
"utf-8", "replace"
|
||||
)
|
||||
return proc.stdout, proc.stderr
|
||||
|
||||
|
||||
@unittest.skipUnless(perf_command_works(), "perf command doesn't work")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue