Blame SOURCES/pip-allow-different-versions.patch

db7918
--- /usr/bin/pip3	2019-11-12 17:37:34.793131862 +0100
db7918
+++ pip3	2019-11-12 17:40:42.014107134 +0100
db7918
@@ -2,7 +2,23 @@
db7918
 # -*- coding: utf-8 -*-
db7918
 import re
db7918
 import sys
db7918
-from pip._internal.cli.main import main
db7918
+
db7918
+try:
db7918
+    from pip._internal.cli.main import main
db7918
+except ImportError:
db7918
+    try:
db7918
+        from pip._internal.main import main
db7918
+    except ImportError:
db7918
+        try:
db7918
+            # If the user has downgraded pip, the above import will fail.
db7918
+            # Let's try older methods of invoking it:
db7918
+
db7918
+            # pip 19 uses this
db7918
+            from pip._internal import main
db7918
+        except ImportError:
db7918
+            # older pip versions use this
db7918
+            from pip import main
db7918
+
db7918
 if __name__ == '__main__':
db7918
     sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
db7918
     sys.exit(main())