I'm getting an AssertionError when running the following code. It seems to be a combination of gevent + opentelemetry. Originally reported in https://github.com/pydantic/logfire/issues/63
Minimal reproduction:
import gevent.monkey
gevent.monkey.patch_all()
from opentelemetry.sdk.trace.export import BatchSpanProcessor, SpanExporter
processor = BatchSpanProcessor(SpanExporter(), schedule_delay_millis=500)
# doing this import shows the error
import magic
Output looks like this:
$ python app.py
Traceback (most recent call last):
File "src/gevent/_abstract_linkable.py", line 287, in gevent._gevent_c_abstract_linkable.AbstractLinkable._notify_links
File "src/gevent/_abstract_linkable.py", line 333, in gevent._gevent_c_abstract_linkable.AbstractLinkable._notify_links
AssertionError: (None, <callback at 0x7f72a5936040 args=([],)>)
2024-05-01T14:26:07Z <callback at 0x7f72a5936040 args=([],)> failed with AssertionError
I'm getting an
AssertionError
when running the following code. It seems to be a combination ofgevent
+opentelemetry
. Originally reported in https://github.com/pydantic/logfire/issues/63Minimal reproduction:
Output looks like this:
Environment:
dependencies: