Bump kafka deps versions & fix integration test failures (#1818)

* Bump kafka deps versions

* adjust import

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* added missing tox python 3.12 env for kafka

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
Asif Saif Uddin 2023-11-06 18:13:27 +06:00 committed by GitHub
parent c75c2a0b58
commit 85abaa635a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 6 deletions

View File

@ -69,7 +69,8 @@ from kombu.utils.json import dumps, loads
try:
import confluent_kafka
from confluent_kafka import Consumer, Producer, TopicPartition
from confluent_kafka import (Consumer, KafkaException, Producer,
TopicPartition)
from confluent_kafka.admin import AdminClient, NewTopic
KAFKA_CONNECTION_ERRORS = ()
@ -86,7 +87,7 @@ logger = get_logger(__name__)
DEFAULT_PORT = 9092
class NoBrokersAvailable(confluent_kafka.KafkaException):
class NoBrokersAvailable(KafkaException):
"""Kafka broker is not available exception."""
retriable = True

View File

@ -1 +1 @@
confluent-kafka==2.1.1
confluent-kafka>=2.2.0

View File

@ -4,7 +4,7 @@ envlist =
{pypy3.9,3.8,3.9,3.10,3.11,3.12}-linux-integration-py-amqp
{pypy3.9,3.8,3.9,3.10,3.11}-linux-integration-redis
{pypy3.9,3.8,3.9,3.10,3.11}-linux-integration-mongodb
{3.8,3.9,3.10,3.11}-linux-integration-kafka
{3.8,3.9,3.10,3.11,3.12}-linux-integration-kafka
flake8
apicheck
pydocstyle
@ -29,7 +29,7 @@ deps=
apicheck,pypy3.9,3.8,3.9,3.10,3.11,3.12: -r{toxinidir}/requirements/default.txt
apicheck,pypy3.9,3.8,3.9,3.10,3.11,3.12: -r{toxinidir}/requirements/test.txt
apicheck,pypy3.9,3.8,3.9,3.10,3.11,3.12: -r{toxinidir}/requirements/test-ci.txt
apicheck,3.8-linux,3.9-linux,3.10-linux,3.11-linux: -r{toxinidir}/requirements/extras/confluentkafka.txt
apicheck,3.8-linux,3.9-linux,3.10-linux,3.11-linux,3.12-linux: -r{toxinidir}/requirements/extras/confluentkafka.txt
apicheck,linkcheck: -r{toxinidir}/requirements/docs.txt
flake8,pydocstyle,mypy: -r{toxinidir}/requirements/pkgutils.txt
@ -99,7 +99,7 @@ healthcheck_start_period = 5
environment = ALLOW_ANONYMOUS_LOGIN=yes
[docker:kafka]
image = bitnami/kafka:3.4.0-debian-11-r21
image = bitnami/kafka:latest
ports =
9092:9092/tcp
healthcheck_cmd = /bin/bash -c 'kafka-topics.sh --list --bootstrap-server 127.0.0.1:9092'