1{ lib 2, buildPythonPackage 3, fetchPypi 4, pytestCheckHook 5, google-api-core 6, google-cloud-core 7, google-cloud-testutils 8, libcst 9, mock 10, proto-plus 11, pytest-asyncio 12, pythonOlder 13}: 14 15buildPythonPackage rec { 16 pname = "google-cloud-translate"; 17 version = "3.8.4"; 18 format = "setuptools"; 19 20 disabled = pythonOlder "3.7"; 21 22 src = fetchPypi { 23 inherit pname version; 24 hash = "sha256-cptSFyAByZRZ7Dr93skVPeCvUoh0/PMACp3dmOEQfuc="; 25 }; 26 27 propagatedBuildInputs = [ 28 google-api-core 29 google-cloud-core 30 libcst 31 proto-plus 32 ]; 33 34 checkInputs = [ 35 google-cloud-testutils 36 mock 37 pytestCheckHook 38 pytest-asyncio 39 ]; 40 41 preCheck = '' 42 # prevent shadowing imports 43 rm -r google 44 ''; 45 46 pythonImportsCheck = [ 47 "google.cloud.translate" 48 "google.cloud.translate_v2" 49 "google.cloud.translate_v3" 50 "google.cloud.translate_v3beta1" 51 ]; 52 53 meta = with lib; { 54 description = "Google Cloud Translation API client library"; 55 homepage = "https://github.com/googleapis/python-translate"; 56 license = licenses.asl20; 57 maintainers = with maintainers; [ SuperSandro2000 ]; 58 }; 59}