1{ 2 lib, 3 buildPythonPackage, 4 fetchPypi, 5 google-api-core, 6 google-auth, 7 grpcio, 8 mock, 9 pytestCheckHook, 10 pythonOlder, 11}: 12 13buildPythonPackage rec { 14 pname = "google-cloud-core"; 15 version = "2.4.1"; 16 format = "setuptools"; 17 18 disabled = pythonOlder "3.7"; 19 20 src = fetchPypi { 21 inherit pname version; 22 hash = "sha256-m3dJJyqBK95Y//KIaNDF4vWFuC834JofbtLU0Q8TQHM="; 23 }; 24 25 propagatedBuildInputs = [ 26 google-auth 27 google-api-core 28 ]; 29 30 passthru.optional-dependencies = { 31 grpc = [ grpcio ]; 32 }; 33 34 nativeCheckInputs = [ 35 mock 36 pytestCheckHook 37 ] ++ passthru.optional-dependencies.grpc; 38 39 # prevent google directory from shadowing google imports 40 preCheck = '' 41 rm -r google 42 ''; 43 44 pythonImportsCheck = [ "google.cloud" ]; 45 46 meta = with lib; { 47 description = "API Client library for Google Cloud: Core Helpers"; 48 homepage = "https://github.com/googleapis/python-cloud-core"; 49 changelog = "https://github.com/googleapis/python-cloud-core/blob/v${version}/CHANGELOG.md"; 50 license = licenses.asl20; 51 maintainers = with maintainers; [ ]; 52 }; 53}