about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/google_api_core/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/google_api_core/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/google_api_core/default.nix42
1 files changed, 42 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/google_api_core/default.nix b/nixpkgs/pkgs/development/python-modules/google_api_core/default.nix
new file mode 100644
index 000000000000..1efec99d8f72
--- /dev/null
+++ b/nixpkgs/pkgs/development/python-modules/google_api_core/default.nix
@@ -0,0 +1,42 @@
+{ lib, buildPythonPackage, fetchPypi, pythonOlder, isPy27
+, google_auth, protobuf, googleapis_common_protos, requests, setuptools, grpcio
+, mock
+}:
+
+buildPythonPackage rec {
+  pname = "google-api-core";
+  version = "1.17.0";
+  disabled = isPy27; # google namespace no longer works on python2
+
+  src = fetchPypi {
+    inherit pname version;
+    sha256 = "12fn05x2fdhqmcaspjkkny2lh66hnnl0xf6pz3idxhlx8w5jl274";
+  };
+
+  propagatedBuildInputs = [
+    googleapis_common_protos protobuf
+    google_auth requests setuptools grpcio
+  ];
+
+  # requires nox
+  doCheck = false;
+  checkInputs = [ mock ];
+
+  pythonImportsCheck = [
+    "google.auth"
+    "google.protobuf"
+    "google.api"
+  ];
+
+  meta = with lib; {
+    description = "Core Library for Google Client Libraries";
+    longDescription = ''
+      This library is not meant to stand-alone. Instead it defines common
+      helpers used by all Google API clients.
+    '';
+    homepage = "https://github.com/googleapis/python-api-core";
+    changelog = "https://github.com/googleapis/python-api-core/blob/v${version}/CHANGELOG.md";
+    license = licenses.asl20;
+    maintainers = with maintainers; [ ];
+  };
+}