nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 92 lines 2.1 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 google-auth, 6 googleapis-common-protos, 7 grpcio, 8 grpcio-gcp, 9 grpcio-status, 10 proto-plus, 11 protobuf, 12 pytest-asyncio, 13 pytest-mock, 14 pytestCheckHook, 15 requests, 16 setuptools, 17}: 18 19buildPythonPackage rec { 20 pname = "google-api-core"; 21 version = "2.29.0"; 22 pyproject = true; 23 24 src = fetchFromGitHub { 25 owner = "googleapis"; 26 repo = "python-api-core"; 27 tag = "v${version}"; 28 hash = "sha256-wqDGtCYAH2f+P3zUfXgiQTePLr7a0qzUTeEc6pdCGio="; 29 }; 30 31 build-system = [ setuptools ]; 32 33 dependencies = [ 34 googleapis-common-protos 35 google-auth 36 protobuf 37 proto-plus 38 requests 39 ]; 40 41 optional-dependencies = { 42 async_rest = [ google-auth ] ++ google-auth.optional-dependencies.aiohttp; 43 grpc = [ 44 grpcio 45 grpcio-status 46 ]; 47 grpcgcp = [ grpcio-gcp ]; 48 grpcio-gcp = [ grpcio-gcp ]; 49 }; 50 51 nativeCheckInputs = [ 52 pytest-asyncio 53 pytest-mock 54 pytestCheckHook 55 ]; 56 57 # prevent google directory from shadowing google imports 58 preCheck = '' 59 rm -r google 60 ''; 61 62 disabledTests = [ 63 # Those grpc_helpers tests are failing 64 "test_wrap_unary_errors" 65 "test_wrap_stream_errors_raised" 66 "test_wrap_stream_errors_read" 67 "test_wrap_stream_errors_aiter" 68 "test_wrap_stream_errors_write" 69 "test_wrap_unary_errors" 70 "test___next___w_rpc_error" 71 "test_wrap_stream_errors_invocation" 72 "test_wrap_stream_errors_iterator_initialization" 73 "test_wrap_stream_errors_during_iteration" 74 "test_exception_with_error_code" 75 ]; 76 77 pythonImportsCheck = [ "google.api_core" ]; 78 79 meta = { 80 description = "Core Library for Google Client Libraries"; 81 longDescription = '' 82 This library is not meant to stand-alone. Instead it defines common 83 helpers used by all Google API clients. 84 ''; 85 homepage = "https://github.com/googleapis/python-api-core"; 86 changelog = "https://github.com/googleapis/python-api-core/blob/${src.tag}/CHANGELOG.md"; 87 license = lib.licenses.asl20; 88 maintainers = with lib.maintainers; [ 89 sarahec 90 ]; 91 }; 92}