Skip to content

delete_records leads up to a crash when using Python 3.14.6 #2275

Description

Hi,

I have an issue with confluent_kafka (latest version 2.14.2) on Python 3.14 (tested with 3.14.6): When I call "delete_records" and then "list_topics", I get a segfault. This is a minimal example to test it:

from confluent_kafka.admin import AdminClient

admin_client = AdminClient({"bootstrap.servers": "localhost:9092"})

from confluent_kafka import TopicPartition
tp = TopicPartition(topic="my_topic", partition=0, offset=100)

print("Deleting records...")
delete_futures = admin_client.delete_records([tp], operation_timeout=10)

for tp, future in delete_futures.items():
    try:
        future.result()
        print(f"Successfully deleted records for {tp.topic}-{tp.partition} up to offset {tp.offset}")
    except Exception as e:
        print(f"Failed to delete records for {tp.topic}: {e}")

print("\nListing topics...")
cluster_metadata = admin_client.list_topics(timeout=10)

for topic_name in cluster_metadata.topics:
    print(f"- {topic_name}")

Crashes at the "list_topics" call:
Segmentation fault (core dumped)

This is on Linux, don't know what happens on Mac/Windows.

Works fine with Python 3.12 and 3.13, just 3.14 seems to be problematic.

Best, Ralph

Metadata

Metadata

Assignees

No one assigned

    Labels

    status:plannedPlanned for implementation on our roadmap

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions