mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
commit
13537c4891
1 changed files with 2 additions and 11 deletions
|
@ -49,22 +49,13 @@ if HAS_PIP is True:
|
|||
if 'pip' in sys.modules:
|
||||
del sys.modules['pip']
|
||||
|
||||
ver = pip.__version__.split('.')
|
||||
pip_ver = tuple([int(x) for x in ver if x.isdigit()])
|
||||
if pip_ver >= (8, 0, 0):
|
||||
try:
|
||||
from pip.exceptions import InstallationError
|
||||
else:
|
||||
except ImportError:
|
||||
InstallationError = ValueError
|
||||
|
||||
# pylint: enable=import-error
|
||||
|
||||
ver = pip.__version__.split('.')
|
||||
pip_ver = tuple([int(x) for x in ver if x.isdigit()])
|
||||
if pip_ver >= (8, 0, 0):
|
||||
from pip.exceptions import InstallationError
|
||||
else:
|
||||
InstallationError = ValueError
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
# Define the module's virtual name
|
||||
|
|
Loading…
Add table
Reference in a new issue