2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
buildPythonPackage,
|
|
|
|
cirq-core,
|
|
|
|
freezegun,
|
|
|
|
google-api-core,
|
|
|
|
protobuf,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonRelaxDepsHook,
|
|
|
|
setuptools,
|
2021-05-20 23:08:51 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "cirq-google";
|
2024-02-07 01:22:34 +00:00
|
|
|
pyproject = true;
|
2021-05-20 23:08:51 +00:00
|
|
|
inherit (cirq-core) version src meta;
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
sourceRoot = "${src.name}/${pname}";
|
2021-05-20 23:08:51 +00:00
|
|
|
|
2023-10-19 13:55:26 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
pythonRelaxDepsHook
|
2024-02-07 01:22:34 +00:00
|
|
|
setuptools
|
2023-10-19 13:55:26 +00:00
|
|
|
];
|
|
|
|
|
2021-05-20 23:08:51 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
cirq-core
|
|
|
|
google-api-core
|
|
|
|
protobuf
|
2023-01-11 07:51:40 +00:00
|
|
|
] ++ google-api-core.optional-dependencies.grpc;
|
2021-05-20 23:08:51 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-10-28 06:52:43 +00:00
|
|
|
freezegun
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2022-01-13 20:06:32 +00:00
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
disabledTestPaths = [
|
|
|
|
# No need to test the version number
|
|
|
|
"cirq_google/_version_test.py"
|
2023-04-29 16:46:19 +00:00
|
|
|
# Trace/BPT trap: 5
|
|
|
|
"cirq_google/engine/calibration_test.py"
|
2024-02-07 01:22:34 +00:00
|
|
|
# Very time-consuming
|
|
|
|
"cirq_google/engine/*_test.py"
|
2022-10-21 18:38:19 +00:00
|
|
|
];
|
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
disabledTests = [
|
|
|
|
# unittest.mock.InvalidSpecError: Cannot autospec attr 'QuantumEngineServiceClient'
|
|
|
|
"test_get_engine_sampler_explicit_project_id"
|
|
|
|
"test_get_engine_sampler"
|
2023-10-19 13:55:26 +00:00
|
|
|
# Calibration issue
|
|
|
|
"test_xeb_to_calibration_layer"
|
2022-01-13 20:06:32 +00:00
|
|
|
];
|
2021-05-20 23:08:51 +00:00
|
|
|
}
|