Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / confluent-kafka / default.nix
blobb610f1d405909d26aec9b961fd1f6a667f411a30
1 { lib
2 , avro
3 , buildPythonPackage
4 , fastavro
5 , fetchFromGitHub
6 , jsonschema
7 , protobuf
8 , pyflakes
9 , pyrsistent
10 , pytestCheckHook
11 , pythonOlder
12 , rdkafka
13 , requests
14 , requests-mock
17 buildPythonPackage rec {
18   pname = "confluent-kafka";
19   version = "2.3.0";
20   format = "setuptools";
22   disabled = pythonOlder "3.7";
24   src = fetchFromGitHub {
25     owner = "confluentinc";
26     repo = "confluent-kafka-python";
27     rev = "refs/tags/v${version}";
28     hash = "sha256-sPlLlp0niR45lQPCvVd6NPtGI1cFbmPeQpIF1RnnY0I=";
29   };
31   buildInputs = [
32     rdkafka
33   ];
35   propagatedBuildInputs = [
36     requests
37   ];
39   passthru.optional-dependencies = {
40     avro = [
41       avro
42       fastavro
43     ];
44     json = [
45       jsonschema
46       pyrsistent
47     ];
48     protobuf = [
49       protobuf
50     ];
51   };
53   nativeCheckInputs = [
54     pyflakes
55     pytestCheckHook
56     requests-mock
57   ] ++ lib.flatten (builtins.attrValues passthru.optional-dependencies);
59   pythonImportsCheck = [
60     "confluent_kafka"
61   ];
63   disabledTestPaths = [
64     "tests/integration/"
65     "tests/test_Admin.py"
66     "tests/test_misc.py"
67   ];
69   meta = with lib; {
70     description = "Confluent's Apache Kafka client for Python";
71     homepage = "https://github.com/confluentinc/confluent-kafka-python";
72     changelog = "https://github.com/confluentinc/confluent-kafka-python/blob/v${version}/CHANGELOG.md";
73     license = licenses.asl20;
74     maintainers = with maintainers; [ mlieberman85 ];
75   };