2021-01-05 11:02:48 +01:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2021-01-06 10:46:48 +01:00
|
|
|
, google-auth
|
2021-03-05 16:20:42 +01:00
|
|
|
, googleapis-common-protos
|
2021-01-05 11:02:48 +01:00
|
|
|
, grpcio
|
2021-11-30 15:04:31 +01:00
|
|
|
, grpcio-status
|
2021-01-05 11:02:48 +01:00
|
|
|
, protobuf
|
2021-08-23 13:01:07 +02:00
|
|
|
, proto-plus
|
2021-01-05 11:02:48 +01:00
|
|
|
, requests
|
|
|
|
, mock
|
|
|
|
, pytest-asyncio
|
|
|
|
, pytestCheckHook
|
2021-11-29 11:58:42 +01:00
|
|
|
, pythonOlder
|
2021-01-05 11:02:48 +01:00
|
|
|
}:
|
2017-12-20 23:47:52 +01:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "google-api-core";
|
2022-02-19 01:36:15 +01:00
|
|
|
version = "2.5.0";
|
2021-11-29 11:58:42 +01:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.6";
|
2017-12-20 23:47:52 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2022-02-19 01:36:15 +01:00
|
|
|
sha256 = "sha256-8zhjpnCWUXA7ixi2cJNRSDjHnysE0CqlASAwefJLgBg=";
|
2017-12-20 23:47:52 +01:00
|
|
|
};
|
|
|
|
|
2021-01-05 11:02:48 +01:00
|
|
|
propagatedBuildInputs = [
|
2021-03-05 16:20:42 +01:00
|
|
|
googleapis-common-protos
|
2021-01-06 10:46:48 +01:00
|
|
|
google-auth
|
2021-01-05 11:02:48 +01:00
|
|
|
grpcio
|
2021-11-30 15:04:31 +01:00
|
|
|
grpcio-status
|
2021-01-05 11:02:48 +01:00
|
|
|
protobuf
|
2021-08-23 13:01:07 +02:00
|
|
|
proto-plus
|
2021-01-05 11:02:48 +01:00
|
|
|
requests
|
|
|
|
];
|
2017-12-20 23:47:52 +01:00
|
|
|
|
2021-11-29 11:58:42 +01:00
|
|
|
checkInputs = [
|
|
|
|
mock
|
|
|
|
pytest-asyncio
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2019-10-24 23:24:37 -07:00
|
|
|
|
2020-11-02 17:14:27 -08:00
|
|
|
# prevent google directory from shadowing google imports
|
|
|
|
preCheck = ''
|
|
|
|
rm -r google
|
|
|
|
'';
|
|
|
|
|
2021-11-29 11:58:42 +01:00
|
|
|
disabledTests = [
|
|
|
|
# Those grpc_helpers tests are failing
|
|
|
|
"test_wrap_unary_errors"
|
|
|
|
"test_wrap_stream_errors_raised"
|
|
|
|
"test_wrap_stream_errors_read"
|
|
|
|
"test_wrap_stream_errors_aiter"
|
|
|
|
"test_wrap_stream_errors_write"
|
|
|
|
"test_wrap_unary_errors"
|
|
|
|
"test___next___w_rpc_error"
|
|
|
|
"test_wrap_stream_errors_invocation"
|
|
|
|
"test_wrap_stream_errors_iterator_initialization"
|
|
|
|
"test_wrap_stream_errors_during_iteration"
|
|
|
|
"test_exception_with_error_code"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"google.api_core"
|
|
|
|
];
|
2017-12-20 23:47:52 +01:00
|
|
|
|
2018-04-06 21:22:26 +02:00
|
|
|
meta = with lib; {
|
2020-06-03 15:42:54 +02:00
|
|
|
description = "Core Library for Google Client Libraries";
|
|
|
|
longDescription = ''
|
|
|
|
This library is not meant to stand-alone. Instead it defines common
|
|
|
|
helpers used by all Google API clients.
|
|
|
|
'';
|
|
|
|
homepage = "https://github.com/googleapis/python-api-core";
|
2021-08-23 13:01:07 +02:00
|
|
|
changelog = "https://github.com/googleapis/python-api-core/blob/v${version}/CHANGELOG.md";
|
2017-12-20 23:47:52 +01:00
|
|
|
license = licenses.asl20;
|
2021-01-05 11:02:48 +01:00
|
|
|
maintainers = with maintainers; [ SuperSandro2000 ];
|
2017-12-20 23:47:52 +01:00
|
|
|
};
|
|
|
|
}
|