Windows-10-Toast-Notifications
Windows-10-Toast-Notifications copied to clipboard
Building with pip version > 10
So while building the project, I have encountered an issue with pip module while in setup.py
In pip versions greater than 10 parse_requirements is in pip._internal.req instead of pip.req. Here is a snippet on how I fixed it.
diff --git a/setup.py b/setup.py
index 8ead33e..a1ef1ad 100644
--- a/setup.py
+++ b/setup.py
@@ -2,7 +2,10 @@
from operator import attrgetter
from os import path
-from pip.req import parse_requirements
+try: # for pip >= 10
+ from pip._internal.req import parse_requirements
+except ImportError: # for pip <= 9.0.3
+ from pip.req import parse_requirements
from setuptools import setup
def read(fname):
Created pull request #60