{ lib, buildPythonPackage, fetchFromGitHub, # build-system setuptools, # dependencies google-api-core, google-cloud-logging, proto-plus, protobuf, # testing google-cloud-testutils, mock, pytest-asyncio, pytestCheckHook, pythonOlder, }: buildPythonPackage (finalAttrs: { pname = "google-cloud-error-reporting"; version = "1.14.0"; pyproject = true; src = fetchFromGitHub { owner = "googleapis"; repo = "python-error-reporting"; tag = "v${finalAttrs.version}"; hash = "sha256-do/pxm+Bo2c57ehg1cRlpax+UggSUMv8WSK30sXhHpo="; }; build-system = [ setuptools ]; pythonRelaxDeps = [ "protobuf" ]; dependencies = [ google-api-core google-cloud-logging proto-plus protobuf ] ++ google-api-core.optional-dependencies.grpc; nativeCheckInputs = [ google-cloud-testutils mock pytest-asyncio pytestCheckHook ]; disabledTests = [ # Tests require credentials "test_report_error_event" "test_report_exception" # Import is already tested "test_namespace_package_compat" # AssertionError: assert None is "test_error_group_service_client_get_mtls_endpoint_and_cert_source" ":test_report_errors_service_client_get_mtls_endpoint_and_cert_source" "test_report_errors_service_client_get_mtls_endpoint_and_cert_source" "test_error_stats_service_client_get_mtls_endpoint_and_cert_source" ]; # disabledTestPaths = lib.optionals (pythonOlder "3.14") [ "tests/unit/gapic/errorreporting_v1beta1/test_error_group_service.py" "tests/unit/gapic/errorreporting_v1beta1/test_error_stats_service.py" "tests/unit/gapic/errorreporting_v1beta1/test_report_errors_service.py" ]; preCheck = '' # prevent google directory from shadowing google imports rm -r google ''; pythonImportsCheck = [ "google.cloud.error_reporting" "google.cloud.errorreporting_v1beta1" ]; meta = { description = "Stackdriver Error Reporting API client library"; homepage = "https://github.com/googleapis/python-error-reporting"; changelog = "https://github.com/googleapis/python-error-reporting/blob/${finalAttrs.src.tag}/CHANGELOG.md"; license = lib.licenses.asl20; maintainers = [ lib.maintainers.sarahec ]; }; })