mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-27 22:03:54 +03:00
python3Packages.qiskit-terra: 0.12.0 -> 0.13.0
Also add in optional visualization inputs as default to ensure that they are in the environment when used at runtime. Some hacks to avoid packaging retworkx (uses a semi-complicated Rust -> Python packaging system, will try to get that packaged in future). For now, just disabling retworkx, will need to package it in future.
This commit is contained in:
parent
e218af21ab
commit
c6ea35d599
@ -2,35 +2,41 @@
|
||||
, pythonOlder
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
# Python requirements
|
||||
, cython
|
||||
, dill
|
||||
, fastjsonschema
|
||||
, jsonschema
|
||||
, numpy
|
||||
, marshmallow
|
||||
, marshmallow-polyfield
|
||||
, matplotlib
|
||||
, networkx
|
||||
, ply
|
||||
, psutil
|
||||
, python-constraint
|
||||
, retworkx
|
||||
, scipy
|
||||
, sympy
|
||||
# Python visualization requirements, semi-optional
|
||||
, ipywidgets
|
||||
, matplotlib
|
||||
, pillow
|
||||
, pydot
|
||||
, pygments
|
||||
, pylatexenc
|
||||
, seaborn
|
||||
# test requirements
|
||||
, ddt
|
||||
, hypothesis
|
||||
, ipywidgets
|
||||
, nbformat
|
||||
, nbconvert
|
||||
, pillow
|
||||
, pydot
|
||||
, python
|
||||
, pygraphviz
|
||||
, pylatexenc
|
||||
, pytestCheckHook
|
||||
, python
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "qiskit-terra";
|
||||
version = "0.12.0";
|
||||
version = "0.13.0";
|
||||
|
||||
disabled = pythonOlder "3.5";
|
||||
|
||||
@ -38,13 +44,14 @@ buildPythonPackage rec {
|
||||
owner = "Qiskit";
|
||||
repo = pname;
|
||||
rev = version;
|
||||
sha256 = "1yarfziy2w8n1d7zyyxykfs68608j8md4kwfyhbyc6wy483fk9sy";
|
||||
sha256 = "03fgqmyahgmkf5dbw19n9c1v8p4kmpk50wxhhc8435cclvs26x9j";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cython ];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
dill
|
||||
fastjsonschema
|
||||
jsonschema
|
||||
numpy
|
||||
marshmallow
|
||||
@ -53,34 +60,41 @@ buildPythonPackage rec {
|
||||
networkx
|
||||
ply
|
||||
psutil
|
||||
python-constraint
|
||||
retworkx
|
||||
scipy
|
||||
sympy
|
||||
# Optional/visualization inputs
|
||||
ipywidgets
|
||||
matplotlib
|
||||
pillow
|
||||
pydot
|
||||
pygments
|
||||
pylatexenc
|
||||
seaborn
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
# Fix relative imports in tests
|
||||
touch test/python/dagcircuit/__init__.py
|
||||
'';
|
||||
|
||||
# *** Tests ***
|
||||
checkInputs = [
|
||||
ddt
|
||||
hypothesis
|
||||
ipywidgets
|
||||
nbformat
|
||||
nbconvert
|
||||
pillow
|
||||
pydot
|
||||
pygraphviz
|
||||
pylatexenc
|
||||
pytestCheckHook
|
||||
];
|
||||
dontUseSetuptoolsCheck = true; # can't find setup.py, so fails. tested by pytest
|
||||
|
||||
pythonImportsCheck = [
|
||||
"qiskit"
|
||||
"qiskit.transpiler.passes.routing.cython.stochastic_swap.swap_trial"
|
||||
];
|
||||
|
||||
dontUseSetuptoolsCheck = true; # can't find setup.py, so fails. tested by pytest
|
||||
|
||||
disabledTests = [
|
||||
"test_long_name" # generated circuit images differ for some reason
|
||||
"test_jupyter_jobs_pbars" # needs IBMQ provider package (qiskit-ibmq-provider), circular dependency
|
||||
];
|
||||
|
||||
@ -112,7 +126,8 @@ buildPythonPackage rec {
|
||||
longDescription = ''
|
||||
Allows the user to write quantum circuits easily, and takes care of the constraints of real hardware.
|
||||
'';
|
||||
homepage = "https://github.com/QISKit/qiskit-terra";
|
||||
homepage = "https://qiskit.org/terra";
|
||||
downloadPage = "https://github.com/QISKit/qiskit-terra/releases";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ drewrisinger ];
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user