openmhz / trunk-server

Listen to Trunk Record and explore archived calls. This is the software behind OpenMHz
https://openmhz.com
112 stars 31 forks source link

Autoplay misses calls that have a start time older than the one currently playing #163

Open agausmann opened 3 months ago

agausmann commented 3 months ago

This is easily reproducible every few minutes, on a typical station with overlapping short and long recordings.

For example, 5:32:12 PM was left unread here:

image

What seems to be happening: Recordings are being sorted by start time, and older, longer recordings are inserted before the "now playing" entry that was finished and submitted first:

  1. Receiver A starts recording at 5:32:12
  2. Receiver B starts recording at 5:32:17
  3. Receiver B finishes after 2 seconds, and uploads
  4. Player starts playing from 5:32:17
  5. Receiver A finishes after 12 seconds, and uploads
agausmann commented 3 months ago

I can't assign myself, but I'm currently looking into modifying the CallPlayer to keep its own queue of calls for autoplay, so the autoplay logic is independent of the order in the call list.