How to reproduce: 1) Start PV 2) Load a trace, e.g. sigrok-dumps/uart/hello-world/8n1/hello_world_8n1_1200.sr 3) Add a decoder, e.g. guess_bitrate or timing 4) Assign the channel to the decoder 5) If the decode doesn't crash PV, keep clicking Run after the previous decode finished Expected result: PV never crashes Actual result: srd: Created session 5. srd: Creating new timing instance. srd: Created new timing instance with ID timing-1. srd: Setting channels for instance timing-1 with list of 1 channels. srd: Setting channel mapping: data (index 0) = channel 0. srd: Final channel map: srd: - index 0 = channel 0 (required) srd: Setting session 5 samplerate to 625000. srd: Registering new callback for output type 0. srd: Calling start() on all instances in session 5. srd: Calling start() method on protocol decoder instance timing-1. srd: Instance timing-1 creating new output type 0 for timing-1. srd: Initial pins: 0. srd: Decoding: abs start sample 0, abs end sample 4096 (4096 samples, 4096 bytes, unitsize = 1), instance timing-1. srd: No worker thread for this decoder stack exists yet, creating one: timing-1. srd: NULL/empty condition list, automatic match. srd: Instance timing-1 put 0-389 OUTPUT_ANN on oid 0. srd: SystemError: Protocol decoder instance timing-1: : <built-in method wait of Decoder object at 0xb550718c> returned a result with an error set srd: Instance timing-1 put 389-2472 OUTPUT_ANN on oid 0. srd: Instance timing-1 put 389-2472 OUTPUT_ANN on oid 0. srd: StopIteration: Protocol decoder instance timing-1: : QObject::killTimers: timers cannot be stopped from another thread srd: ['Traceback (most recent call last):\n', ' File "/home/abraxa/repositories/sigrok/build/share/libsigrokdecode/decoders/timing/pd.py", line 111, in decode\n self.last_n.append(t)\n', 'StopIteration\n'] I've also encountered this kind of error for timing: srd: No worker thread for this decoder stack exists yet, creating one: timing-1. srd: NULL/empty condition list, automatic match. srd: SystemError: Protocol decoder instance timing-1: : PyEval_EvalFrameEx returned NULL without setting an error srd: Instance timing-1 put 0-389 OUTPUT_ANN on oid 0. srd: Instance timing-1 put 389-2472 OUTPUT_ANN on oid 0. srd: Instance timing-1 put 389-2472 OUTPUT_ANN on oid 0. srd: Instance timing-1 put 2472-2993 OUTPUT_ANN on oid 0. srd: Instance timing-1 put 2472-2993 OUTPUT_ANN on oid 0. QObject::killTimers: timers cannot be stopped from another thread ...and this one for guess bitrate: srd: Created session 18. srd: Creating new guess_bitrate instance. std: virtual-session: Sending SR_DF_END packet. sr: [00:24.530062] session: bus: Received SR_DF_END packet. srd: Created new guess_bitrate instance with ID guess_bitrate-1. sr: [00:24.530143] session: fd_source_finalize: key 0xffffffff srd: Setting channels for instance guess_bitrate-1 with list of 1 channels. sr: [00:24.530291] session: Stopped. srd: Setting channel mapping: data (index 0) = channel 0. srd: Final channel map: srd: - index 0 = channel 0 (required) srd: Setting session 18 samplerate to 625000. srd: Registering new callback for output type 0. srd: Calling start() on all instances in session 18. srd: Calling start() method on protocol decoder instance guess_bitrate-1. srd: Instance guess_bitrate-1 creating new output type 0 for guess_bitrate-1. srd: Initial pins: 1. srd: Decoding: abs start sample 0, abs end sample 4096 (4096 samples, 4096 bytes, unitsize = 1), instance guess_bitrate-1. srd: No worker thread for this decoder stack exists yet, creating one: guess_bitrate-1. srd: NULL/empty condition list, automatic match. srd: ZeroDivisionError: Protocol decoder instance guess_bitrate-1: : float division by zero The fact that none of these issues appear immediately but only after several runs tell me that there's something broken generally. Now if only I knew what :)
In the mean time I've verified this against a WIP patchset by gsi_ and the crashes are indeed no longer reproducible, which means this is a duplicate of bug #902, marking as such. *** This bug has been marked as a duplicate of bug 902 ***