List index out of range - rsudp crashes

This is a follow-up to a post I made a while back about RSUDP crashing on my mac-mini whenever alerts are triggered. I migrated to using a raspberry pi5 with 8gb of ram to avoid the issue, but it appears that my alert issues are still causing the program to crash. I am showing 3 channels for the raspberry shake 3d with waveform and spectrogram with a short viewing window. The settings are default. It appears to only freeze when an event is registered that messes with the STA/LTA calculation. This is the message in the terminal when the program freezes/crashes:

run(settings, debug=debug)
File “/home/science/miniforge3/envs/rsudp/lib/python3.12/site-packages/rsudp/client.py”, line 417, in run
start()
File “/home/science/miniforge3/envs/rsudp/lib/python3.12/site-packages/rsudp/client.py”, line 124, in start
CONTROLLER.run()
File “/home/science/miniforge3/envs/rsudp/lib/python3.12/site-packages/rsudp/c_plot_controller.py”, line 90, in run
results.append(plot.main(i, u))
^^^^^^^^^^^^^^^^
File “/home/science/miniforge3/envs/rsudp/lib/python3.12/site-packages/rsudp/c_plots.py”, line 844, in main
self.update_plot()
File “/home/science/miniforge3/envs/rsudp/lib/python3.12/site-packages/rsudp/c_plots.py”, line 730, in update_plot
mean = int(round(np.mean(self.stream[i].data)))
File “/home/science/miniforge3/envs/rsudp/lib/python3.12/site-packages/obspy/core/stream.py”, line 646, in getitem
return self.traces.getitem(index)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
IndexError: list index out of range

2026-02-07 20:12:11 [Alert] Threshold: 3.95; Current max STA/LTA: 0.0966

Hello, and welcome back!

Thank you for the traceback of the error and the new details about the hardware you are using.

I’ll have to try and replicate it on my RSUDP installation to see if there is something else that escaped our previous analysis of the issue.

I will update you as soon as I know more. Thank you for your patience.

Hello again,

I tried to replicate the issue as per my last message, but I was unable to on either my PC, RPi4, or RPi5.

So, I re-checked the code and your traceback, and I have a hypothesis: the crash could be caused by the plotter expecting all three traces (that you are displaying) but sometimes getting a smaller number within the current time window (probably caused by brief dropouts/gaps). When that happens, then it crashes while computing the mean for the missing channel.

If you can do me a favour, could you close RSUDP, reboot the Shake and turn on RSUDP again? Then:

  • “play” with it, simulating an alert activation
  • keep track at what timestamp the alert went on
  • activate at least three alerts (restarting RSUDP every time, due to the current crashes)
  • then download the logs from the Shake and send all the above timestamps and logs to me

I would like to see if the combined info can give us more insight into what is happening.

Thank you.

I will do that and get back to you. Thank you for the suggestion.

1 Like