Skip to content

Segmentation fault while running integration test. #46

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
samarthg opened this issue Sep 20, 2016 · 4 comments
Closed

Segmentation fault while running integration test. #46

samarthg opened this issue Sep 20, 2016 · 4 comments

Comments

@samarthg
Copy link

I have installed kafka (kafka_2.11-0.10.0.0), confluent-kafka-python and librdkafka properly.
If I run the integration test without testing consumer it works fine. However with "verify_consumer()" it fails with error Segmentation fault (core dumped)

@edenhill
Copy link
Contributor

edenhill commented Oct 6, 2016

What version (or git sha1) of librdkafka are you using?

Can you do this and provide the output?

$ rm core
$ ulimit -c unlimited
$ py.test tests/test_Consumer.py
# wait for it to crash
$ gdb python core
gdb> bt

Thanks

@ryanjmccall
Copy link

ryanjmccall commented Oct 7, 2016

I think by 'integration test' OP means https://github.com/confluentinc/confluent-kafka-python/blob/master/examples/integration_test.py

I can reproduce the problem by specifying an 'on_commit' for the Consumer:
(Using confluent_kafka module version 0.9.1, librdkafka version 0.9.1, and Python 3.5.2)

from confluent_kafka import Consumer
def foo():
... pass
consumer = Consumer({'bootstrap.servers': 'localhost:9092', 'group.id': 'confluent-group','on_commit': foo, 'default.topic.config': { 'auto.offset.reset': 'smallest'}})

consumer.subscribe(["confluent-topic"])
msg = consumer.poll()
consumer.commit(msg, async=False)
Fatal Python error: PyEval_RestoreThread: NULL tstate

Current thread 0x00007fffa1dfc3c0 (most recent call first):
File "", line 1 in
Abort trap: 6 (core dumped)`

@edenhill
Copy link
Contributor

edenhill commented Nov 8, 2016

This was most likely fixed by this commit:
63fcfec

@edenhill
Copy link
Contributor

edenhill commented Nov 8, 2016

integration_test.py passes on master

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants