Possible bug found - "Listening now" notification disappears after listening to songs longer than 10 minutes

Hello, I noticed some curious behaviour on the ListenBrainz user homepage that I perceive to be a bug.

This happens both when scrobbling from Quod Libet (with the AudioScrobbler Submission) plugin enabled and from Rhythmbox, so I assume it to be client-independent. The issue must lie on LB’s site.

Steps to reproduce:

  1. Start listening to a really long song (must be at least longer than 10 mins)
  2. This notification should pop up:
  3. (Optional:) Refresh the web page as often as you like, the notification should still remain unchanged
  4. Now wait until the track crosses the 10:00 minute mark and refresh the tab

Actual result
The notification mysteriously disappears, although the song is still running

Expected result
The notification should remain visible the full duration of the song

Is there any explanation for this phenomenon? The 10 minute cutoff point seems too deliberate to just happen by accident, I tested it with 5-6 different songs and it occurs consistently. But if a song is played for 1 full hour, the “Now Listening to” info should also be shown for one full hour, I would argue

PS. After the song ends, the scrobble is correctly added into the " Recent listens" section, even with the “Listening now” previously missing.

1 Like

Hi! I took a look into this. The issue here is that the listen in question does not have a duration field so we default to a value of 10 minutes. However, I see we do have a recording mbid available so we could probably look it up from MB. I’ll open a ticket to discuss with others if this is feasible and what approach to take if we do so.

1 Like

Hi, thanks for the answer.
Just for clarification: Assuming your described approach would be implemented, would that mean that a song that is not in the MB database would never get a correct “Listening now” notification the full songs length?

If the user submitted listen has the duration or duration_ms field available it will be used. Otherwise we’ll try to lookup the length from MB. If its not found, a default length will be used.

In any case, the listening now notification will always be shown. The duration for which it is shown maybe wrong though depending on whether data was found or not and whether it was accurate.