Update setup.py: REQUIREMENTS (#5613)

* Update setup.py to utilize requirements.txt for installation-required dependencies. This reduces the chance of hard-to-debug errors if requirements and setup don't match

* Add requirements to MANIFEST

Co-authored-by: Matthew Treinish <mtreinish@kortar.org>
This commit is contained in:
Lauren Capelluto 2021-01-12 16:37:19 -05:00 committed by GitHub
parent cb919e37cd
commit 5515717594
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 14 deletions

View File

@ -1,4 +1,5 @@
include LICENSE.txt
include requirements.txt
include qiskit/qasm/libs/*.inc
include qiskit/schemas/*.json
include qiskit/VERSION.txt

View File

@ -22,20 +22,8 @@ except ImportError:
subprocess.call([sys.executable, '-m', 'pip', 'install', 'Cython>=0.27.1'])
from Cython.Build import cythonize
REQUIREMENTS = [
"contextvars>=2.4;python_version<'3.7'",
"jsonschema>=2.6",
"retworkx>=0.7.0",
"numpy>=1.17",
"ply>=3.10",
"psutil>=5",
"scipy>=1.4",
"sympy>=1.3",
"dill>=0.3",
"fastjsonschema>=2.10",
"python-constraint>=1.4",
"python-dateutil>=2.8.0",
]
with open('requirements.txt') as f:
REQUIREMENTS = f.read().splitlines()
# Add Cython extensions here
CYTHON_EXTS = ['utils', 'swap_trial']