1{ lib 2, buildPythonPackage 3, fetchPypi 4, django 5, flask 6, google-api-core 7, google-cloud-appengine-logging 8, google-cloud-audit-log 9, google-cloud-core 10, google-cloud-testutils 11, mock 12, proto-plus 13, pytestCheckHook 14, pytest-asyncio 15}: 16 17buildPythonPackage rec { 18 pname = "google-cloud-logging"; 19 version = "2.7.0"; 20 21 src = fetchPypi { 22 inherit pname version; 23 sha256 = "5a4ad2832be3b86c8f0fb57b2d382a1f67218137c6f6051372647ac5147d6421"; 24 }; 25 26 postPatch = '' 27 substituteInPlace setup.py \ 28 --replace "google-cloud-appengine-logging >= 0.1.0, < 1.0.0dev" "google-cloud-appengine-logging >= 0.1.0" 29 ''; 30 31 propagatedBuildInputs = [ 32 google-api-core 33 google-cloud-appengine-logging 34 google-cloud-audit-log 35 google-cloud-core 36 proto-plus 37 ]; 38 39 checkInputs = [ 40 django 41 flask 42 google-cloud-testutils 43 mock 44 pytestCheckHook 45 pytest-asyncio 46 ]; 47 48 disabledTests = [ 49 # requires credentials 50 "test_write_log_entries" 51 ]; 52 53 preCheck = '' 54 # prevent google directory from shadowing google imports 55 rm -r google 56 # requires credentials 57 rm tests/system/test_system.py tests/unit/test__gapic.py 58 ''; 59 60 pythonImortsCheck = [ 61 "google.cloud.logging" 62 "google.cloud.logging_v2" 63 ]; 64 65 meta = with lib; { 66 description = "Stackdriver Logging API client library"; 67 homepage = "https://github.com/googleapis/python-logging"; 68 license = licenses.asl20; 69 maintainers = with maintainers; [ SuperSandro2000 ]; 70 }; 71}