Skip to content

Commit

Permalink
pythongh-100750: pass encoding kwarg in lib/platform.py (python#100751)
Browse files Browse the repository at this point in the history
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
  • Loading branch information
3 people authored Jan 20, 2023
1 parent 01093b8 commit 6b3993c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Lib/platform.py
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,7 @@ def _syscmd_ver(system='', release='', version='',
stdin=subprocess.DEVNULL,
stderr=subprocess.DEVNULL,
text=True,
encoding="locale",
shell=True)
except (OSError, subprocess.CalledProcessError) as why:
#print('Command %s failed: %s' % (cmd, why))
Expand Down Expand Up @@ -824,6 +825,7 @@ def from_subprocess():
['uname', '-p'],
stderr=subprocess.DEVNULL,
text=True,
encoding="utf8",
).strip()
except (OSError, subprocess.CalledProcessError):
pass
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
pass encoding kwarg to subprocess in platform

0 comments on commit 6b3993c

Please sign in to comment.