Bug 214922 - Last.fm "Listening Now" fails
Summary: Last.fm "Listening Now" fails
Status: RESOLVED UPSTREAM
Alias: None
Product: amarok
Classification: Applications
Component: Services/Last.fm (show other bugs)
Version: 2.3.1-GIT
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Amarok Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-17 05:00 UTC by donotreply
Modified: 2011-01-25 20:38 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description donotreply 2009-11-17 05:00:56 UTC
Version:           2.2.1 (using KDE 4.3.3)
OS:                Linux
Installed from:    Ubuntu Packages

During audio playback in Amarok, the scrobbler for the Last.fm service, specifically its "Listening Now" status, bugs out. Play a few songs with the scrobbler enabled and keep an eye out on the satus on your page. After a track or so, the "Listening Now" status for the current track playing vanishes, and tracks are added after playback, but the "Listening Now" status remains gone until you restart Amarok.
Comment 1 Myriam Schweingruber 2010-02-07 14:10:08 UTC
Please upgrade to Amarok 2.2.2, this should be solved now.
Comment 2 donotreply 2010-02-22 05:28:09 UTC
Still occurs in 2.2.2, and even 2.3 beta. Using a fresh amarok config has yielded negative results as well.
Comment 3 Myriam Schweingruber 2010-02-22 09:11:09 UTC
Are your tracks correctly tagged?
Comment 4 donotreply 2010-02-24 11:01:43 UTC
Yes files are correctly tagged. Testing with Banshee gives a positive result.
Comment 5 Myriam Schweingruber 2010-02-24 13:17:22 UTC
Changing version. Leo, any ideas?
Comment 6 donotreply 2010-03-03 12:21:29 UTC
Another thing I picked up on that might help, I cannot get some intros/short tracks (typically under 30 seconds, a minute max I suppose?) to scrobble either.
Comment 7 Leo Franchi 2010-03-03 19:02:01 UTC
that's  because scrobbling of tracks <30s is not allowed by last.fm
Comment 8 donotreply 2010-03-04 15:35:38 UTC
Oh, did not know that about tracks <30s. Thanks for that tidbit. :)

I looked around and Banshee used to have a similar problem with their old scrobbler that got fixed before they switched to the newer Last.fm scrobbler. Unsure if it helps, but the problems seemed very similar (I used to use Banshee not so long ago), I'll link just in case its of any interest...

Report: https://bugzilla.gnome.org/show_bug.cgi?id=586460
Commit: http://git.gnome.org/browse/banshee/commit/?id=3d93f4d21e6023e3784076e76169eb1f689ba7f7
Comment 9 Michal Petrucha 2010-12-28 15:08:15 UTC
According to my observations, when you start up Amarok and start playing, the first now playing notification gets displayed all right. However, when Amarok finishes the first track and starts playing another one immediately, the notification isn't shown. Also, when you listen to something, stop playing for a while and then start a song from the beginning, the notification is all right.

As I see this, the likely cause is that when changing tracks, Amarok sends both the now playing submission for the new track and the scrobble for the old one at the same time. The server probably picks them up in the wrong order, therefore the now playing submission gets invalidated immediately by the song already finished.

I see two solutions to this:
1) serialize the submissions, i. e. wait for response to the scrobble before sending the notification
2) implement the up-to-date 2.0 scrobbling API (http://www.last.fm/api/scrobbling) – this approach incorporates the notifications and scrobbles into the last.fm web services API.

Personally I'd suggest the second option since version 1.2.1 of the protocol is deprecated (as you can see in the page linked above).

http://www.last.fm/forum/21716/_/656504 and http://www.last.fm/forum/21716/_/656492 might be useful.
Comment 10 Myriam Schweingruber 2011-01-04 00:05:57 UTC
Isn't this solved already since quite some time? I can scrobble correctly here with Amarok 2.4-git
Comment 11 Michal Petrucha 2011-01-19 15:01:00 UTC
Scrobbling was not an issue.

Anyway, on 2.3.90, the now playing notifications have about 47% success rate here. I couldn't find a pattern in the failing notifications, however, I check often and about half the time the notification is shown correctly and about half the time it isn't there. The debug log shows they were all submitted all right to the submission server.
Comment 12 Myriam Schweingruber 2011-01-20 02:09:46 UTC
Sorry if I play dumb, but what "now playing notifications" are you talking about? In last.fm? or in the Amarok status bar?
Comment 13 Michal Petrucha 2011-01-25 19:49:28 UTC
(Sorry, I thought I already replied a few days ago...)

I'm talking about last.fm all the time, by now playing notifications I mean the submissions sent to http://post.audioscrobbler.com:80/np_1.2 and I consider them successful when the profile page shows I'm currently listening to the song.

Hope this is clear enough.
Comment 14 Myriam Schweingruber 2011-01-25 20:38:04 UTC
Yes, you are clear enough. This is likely due to an overload on the last.fm servers, nothing we can do about.