biome: 1.9.2 -> 1.9.3 (#349335)
[NixPkgs.git] / pkgs / development / python-modules / google-cloud-pubsub / default.nix
blobdae730accaa80f5f8450a39078e8161177dd66fa
2   lib,
3   buildPythonPackage,
4   fetchPypi,
5   google-api-core,
6   google-cloud-testutils,
7   grpc-google-iam-v1,
8   grpcio,
9   grpcio-status,
10   libcst,
11   proto-plus,
12   protobuf,
13   pytest-asyncio,
14   pytestCheckHook,
15   pythonOlder,
16   setuptools,
19 buildPythonPackage rec {
20   pname = "google-cloud-pubsub";
21   version = "2.23.1";
22   pyproject = true;
24   disabled = pythonOlder "3.7";
26   src = fetchPypi {
27     pname = "google_cloud_pubsub";
28     inherit version;
29     hash = "sha256-4f3nm1tktyEpCvTAIpB6/LuDUS2S9OXDNMORz7sCKss=";
30   };
32   build-system = [ setuptools ];
34   dependencies = [
35     google-api-core
36     grpc-google-iam-v1
37     grpcio
38     grpcio-status
39     libcst
40     proto-plus
41     protobuf
42   ] ++ google-api-core.optional-dependencies.grpc;
44   optional-dependencies = {
45     libcst = [ libcst ];
46   };
48   nativeCheckInputs = [
49     google-cloud-testutils
50     pytestCheckHook
51     pytest-asyncio
52   ];
54   preCheck = ''
55     # prevent google directory from shadowing google imports
56     rm -r google
57   '';
59   disabledTestPaths = [
60     # Tests in pubsub_v1 attempt to contact pubsub.googleapis.com
61     "tests/unit/pubsub_v1"
62   ];
64   pythonImportsCheck = [ "google.cloud.pubsub" ];
66   meta = with lib; {
67     description = "Google Cloud Pub/Sub API client library";
68     homepage = "https://github.com/googleapis/python-pubsub";
69     changelog = "https://github.com/googleapis/python-pubsub/blob/v${version}/CHANGELOG.md";
70     license = licenses.asl20;
71     maintainers = [ ];
72     mainProgram = "fixup_pubsub_v1_keywords.py";
73   };