Skip to content

Issues processing x-lal buffers from appsink in GStreamer 1.18+

When trying to run this on a pipeline which uses these from_buffer methods, e.g. gstlal_inspiral:

Traceback (most recent call last):
  File "/home/patrick/.conda/envs/gstlal-dev/lib/python3.7/site-packages/gstlal/pipeparts/__init__.py", line 851, in new_sample_handler
    return self.pull_buffers(elem)
  File "/home/patrick/.conda/envs/gstlal-dev/lib/python3.7/site-packages/gstlal/pipeparts/__init__.py", line 890, in pull_buffers
    self.appsink_new_buffer(elem_with_oldest)
  File "/home/patrick/.conda/envs/gstlal-dev/lib/python3.7/site-packages/gstlal/lloidhandler.py", line 1100, in appsink_new_buffer
    events.extend(SnglInspiral.from_buffer(mapinfo.data))
TypeError: argument 1 must be read-only bytes-like object, not memoryview

My understanding is this is due to these objects (GSTLALSnglInspiral) not supporting the buffer protocol.