diff --git a/pkgs/development/python-modules/qcs-api-client/default.nix b/pkgs/development/python-modules/qcs-api-client/default.nix new file mode 100644 index 000000000000..1e5e254e4a87 --- /dev/null +++ b/pkgs/development/python-modules/qcs-api-client/default.nix @@ -0,0 +1,66 @@ +{ lib +, attrs +, buildPythonPackage +, fetchPypi +, httpx +, iso8601 +, pydantic +, pyjwt +, pytest-asyncio +, pytestCheckHook +, python-dateutil +, pythonOlder +, respx +, retrying +, rfc3339 +, toml +}: + +buildPythonPackage rec { + pname = "qcs-api-client"; + version = "0.8.0"; + + disabled = pythonOlder "3.7"; + + src = fetchPypi { + inherit pname version; + sha256 = "1c0g3aa2pk4zd40banap2j797080qivd42q7imla2yvv6cvq24b8"; + }; + + propagatedBuildInputs = [ + attrs + httpx + iso8601 + pydantic + pyjwt + python-dateutil + retrying + rfc3339 + toml + ]; + + checkInputs = [ + pytest-asyncio + pytestCheckHook + respx + ]; + + postPatch = '' + substituteInPlace setup.py \ + --replace "attrs>=20.1.0,<21.0.0" "attrs" \ + --replace "httpx>=0.15.0,<0.16.0" "httpx" \ + --replace "pyjwt>=1.7.1,<2.0.0" "pyjwt" + ''; + + # Project has no tests + doCheck = false; + + pythonImportsCheck = [ "qcs_api_client" ]; + + meta = with lib; { + description = "Python library for accessing the Rigetti QCS API"; + homepage = "https://pypi.org/project/qcs-api-client/"; + license = licenses.asl20; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 4b9ea9254386..5494755526f1 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6655,8 +6655,6 @@ in { pyquery = callPackage ../development/python-modules/pyquery { }; - pyquil = callPackage ../development/python-modules/pyquil { }; - pyrabbit2 = callPackage ../development/python-modules/pyrabbit2 { }; pyrad = callPackage ../development/python-modules/pyrad { }; @@ -7605,6 +7603,8 @@ in { qcengine = callPackage ../development/python-modules/qcengine { }; + qcs-api-client = callPackage ../development/python-modules/qcs-api-client { }; + qdarkstyle = callPackage ../development/python-modules/qdarkstyle { }; qdldl = callPackage ../development/python-modules/qdldl { };