Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 21.05 46 lines 1.0 kB view raw
1{ lib 2, buildPythonPackage 3, fetchPypi 4, pytestCheckHook 5, google-api-core 6, google-cloud-core 7, google-cloud-testutils 8, grpcio 9, libcst 10, mock 11, proto-plus 12, pytest-asyncio 13}: 14 15buildPythonPackage rec { 16 pname = "google-cloud-translate"; 17 version = "3.1.0"; 18 19 src = fetchPypi { 20 inherit pname version; 21 sha256 = "sha256-zVRD2lWRaKtSlZn84Rqpj+a1OT7Wcak524TKsBctueE="; 22 }; 23 24 propagatedBuildInputs = [ google-api-core google-cloud-core libcst proto-plus ]; 25 26 checkInputs = [ google-cloud-testutils mock pytestCheckHook pytest-asyncio ]; 27 28 preCheck = '' 29 # prevent shadowing imports 30 rm -r google 31 ''; 32 33 pythonImportsCheck = [ 34 "google.cloud.translate" 35 "google.cloud.translate_v2" 36 "google.cloud.translate_v3" 37 "google.cloud.translate_v3beta1" 38 ]; 39 40 meta = with lib; { 41 description = "Google Cloud Translation API client library"; 42 homepage = "https://github.com/googleapis/python-translate"; 43 license = licenses.asl20; 44 maintainers = with maintainers; [ SuperSandro2000 ]; 45 }; 46}