only look at stdout when doing pip --version

This commit is contained in:
Nevins Bartolomeo 2017-04-06 14:15:09 -04:00
parent 56363bc41c
commit 9f1321d1a7

View File

@ -1101,7 +1101,7 @@ def version(bin_env=None):
'''
pip_bin = _get_pip_bin(bin_env)
output = __salt__['cmd.run'](
output = __salt__['cmd.run_stdout'](
'{0} --version'.format(pip_bin), python_shell=False)
try:
return re.match(r'^pip (\S+)', output).group(1)