aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/python/ipython/py3/IPython/utils/_process_posix.py
diff options
context:
space:
mode:
authorrobot-contrib <robot-contrib@yandex-team.ru>2022-05-18 00:43:36 +0300
committerrobot-contrib <robot-contrib@yandex-team.ru>2022-05-18 00:43:36 +0300
commit9e5f436a8b2a27bcc7802e443ea3ef3e41a82a75 (patch)
tree78b522cab9f76336e62064d4d8ff7c897659b20e /contrib/python/ipython/py3/IPython/utils/_process_posix.py
parent8113a823ffca6451bb5ff8f0334560885a939a24 (diff)
downloadydb-9e5f436a8b2a27bcc7802e443ea3ef3e41a82a75.tar.gz
Update contrib/python/ipython/py3 to 8.3.0
ref:e84342d4d30476f9148137f37fd0c6405fd36f55
Diffstat (limited to 'contrib/python/ipython/py3/IPython/utils/_process_posix.py')
-rw-r--r--contrib/python/ipython/py3/IPython/utils/_process_posix.py19
1 files changed, 5 insertions, 14 deletions
diff --git a/contrib/python/ipython/py3/IPython/utils/_process_posix.py b/contrib/python/ipython/py3/IPython/utils/_process_posix.py
index a11cad7697..59b5c23896 100644
--- a/contrib/python/ipython/py3/IPython/utils/_process_posix.py
+++ b/contrib/python/ipython/py3/IPython/utils/_process_posix.py
@@ -24,21 +24,12 @@ import pexpect
# Our own
from ._process_common import getoutput, arg_split
-from IPython.utils import py3compat
from IPython.utils.encoding import DEFAULT_ENCODING
#-----------------------------------------------------------------------------
# Function definitions
#-----------------------------------------------------------------------------
-def _find_cmd(cmd):
- """Find the full path to a command using which."""
-
- path = sp.Popen(['/usr/bin/env', 'which', cmd],
- stdout=sp.PIPE, stderr=sp.PIPE).communicate()[0]
- return py3compat.decode(path)
-
-
class ProcessHandler(object):
"""Execute subprocesses under the control of pexpect.
"""
@@ -82,12 +73,12 @@ class ProcessHandler(object):
Parameters
----------
cmd : str
- A command to be executed in the system shell.
+ A command to be executed in the system shell.
Returns
-------
output : str
- A string containing the combination of stdout and stderr from the
+ A string containing the combination of stdout and stderr from the
subprocess, in whatever order the subprocess originally wrote to its
file descriptors (so the order of the information in this string is the
correct order as would be seen if running the command in a terminal).
@@ -103,12 +94,12 @@ class ProcessHandler(object):
Parameters
----------
cmd : str
- A command to be executed in the system shell.
+ A command to be executed in the system shell.
Returns
-------
output : str
- A string containing the combination of stdout and stderr from the
+ A string containing the combination of stdout and stderr from the
subprocess, in whatever order the subprocess originally wrote to its
file descriptors (so the order of the information in this string is the
correct order as would be seen if running the command in a terminal).
@@ -124,7 +115,7 @@ class ProcessHandler(object):
Parameters
----------
cmd : str
- A command to be executed in the system shell.
+ A command to be executed in the system shell.
Returns
-------