Just like a lot of other Rhythmbox users I like to scrobble my played tracks to last.fm. Unfortunately Rhythmbox provides no way to love a track. The last.fm plug-ins for Windows and OS X have been modified to scrobble through the last.fm client some time ago but the Rhythmbox plug-in still submits directly. That is until now…
I have written a new last.fm plug-in for Rhythmbox today. Instead of scrobbling directly like the old one, it submits tracks via the lastfm
client application. The client displays additional information about the currently playing song and you can love and tag the song with it.
The source code is available as a patch against Rhythmbox 2.90.1 (git snapshot 20120108): scrobbler-v3t.patch
You can apply this patch with:
patch -NEp1 < ~/scrobbler-v3t.patch
Ubuntu Oneiric Ocelot users can get precompiled packages from my APT repositories by running these commands in a terminal:
$ sudo add-apt-repository \ '/static/debian/rhythmbox/ main' $ wget /static/gpg.asc -O - | \ sudo apt-key add - $ sudo apt-get update $ sudo apt-get install rhythmbox rhythmbox-plugins lastfm
To enable the new plug-in go to Edit » Plugins
. Disable the “Last.fm” plug-in and enable the “New Style Last.fm Scrobbler”.
If you enable this scrobbler plug-in, you have to disable the old Last.fm plug-in! Otherwise you will have two plug-ins which will both submit to last.fm at the same time. Only use one at a time!
Note that this first version of the plug-in does not start the lastfm
client automatically! It will scrobble only if you start the client manually. I will fix this in the next version.
Feedback, postive as well as negative, is very welcome. If you want to report a bug, please include the output of “rhythmbox -D rb-scrobbler-plugin
” and the tags of the song you wanted to scrobble.
If you want to report a crash, providing a gdb backtrace would be nice.
You might also want to take a look at this thread on the last.fm development forum.
May 20th, 2007: v2 of the plug-in is available now. lastfm
gets launched automatically now.
May 22nd, 2007: v3 is available. The patch and the Ubuntu package have been updated: Changes since v2
May 25th, 2007: v3a: Updated patch and deb for the new Ubuntu Gutsy version of Rhythmbox.
May 29th, 2007: v3b: Updated patch and deb for the new Rhythmbox release.
May 31st, 2007: Updated patch Ubuntu package.
June 1st, 2007: Added APT repositories for Ubuntu Feisty and Gutsy.
June 28th, 2007: v3c: Updated patch and debs for the new Rhythmbox release.
August 16th, 2007: v3d: Updated patch and debs for Rhythmbox 0.11.2.
November 14th, 2007: v3e: Updated patch and debs for Rhythmbox 0.11.3. Add Hardy repository.
November 30th, 2007:Updated gusty and hardy builds. Include fixed Croatian po file from Franko Burolo.
February 7th, 2008: v3f: Updated patch and debs for Rhythmbox 0.11.4. (Thanks to Iain Buchanan for notifying me of the missing patch!)
May 31st, 2008: v3g: Updated patch to apply cleanly to Rhythmbox 0.11.5. (The debs for hardy have been at 0.11.5 for quite a while).
October 15st, 2008: v3h: Updated patch to apply cleanly to Rhythmbox 0.11.6. Ubuntu packages are available for i386, amd64, and lpia now.
October 20st, 2008: v3i: Updated patch to apply cleanly to the real Rhythmbox 0.11.6 release. v3h was for a later version from SVN.
April 24th, 2009: v3j: Update patch to apply cleanly to Rhythmbox 0.12.0. Provide debs for Ubuntu Jaunty.
November 4th, 2009: v3k: Update patch to apply cleanly to Rhythmbox 0.12.5 and provide debs for Ubuntu Karmic.
November 29th, 2009: v3l: Update patch to apply cleanly to Rhythmbox 0.12.6 and provide debs for Ubuntu Lucid too.
April 25th, 2010: v3m: Update patch to apply cleanly to Rhythmbox 0.12.8. Provide debs for Ubuntu Lucid.
Jun 3rd, 2010: v3n: Update patch to apply cleanly to Rhythmbox 0.12.8git20100602. Provide debs for Ubuntu Maverick Meerkat 10.10.
Jun 13th, 2010: v3o: Update patch to apply cleanly to Rhythmbox 0.12.8git20100611. Updated debs for Ubuntu Maverick Meerkat 10.10.
October 10th, 2010: v3p: Update patch to apply cleanly to Rhythmbox 0.13.1. Provide updated debs for Ubuntu Maverick Meerkat 10.10.
April 4th, 2011: v3p: Update patch to apply cleanly to Rhythmbox 0.13.3. Provide debs for Ubuntu Natty Narwhal 11.04.
October 16th, 2011: v3r: Updated patch for new plug-in infrastructure in Rhythmbox 2.90.1. Provide debs for Ubuntu Oneiric Ocelot 11.10.
December 23rd, 2011: v3s: Updated patch. Provide debs for Ubuntu Precise Pangolin 12.04.
January 14th, 2012: v3t: Update patch and debs for Ubuntu Precise.
this really is the plugin i’ve been waiting for! no media players in linux does this kind of last.fm-connection, which all the windows media players do! the advantage of loving or loathing a track is very much appreciated by me!
i haven’t tried it out yet, but i will as soon as i get home from work! thank a very big bunch for making this plugin!
[…] is something I’ve wanted for quite some time: the new style Last.fm plugin takes Last.fm integration to Rhythmbox. Download here. You can install it by following these steps: […]
Nice plugin. I always hate it when a Windows feature doesn’t work on Ubuntu. This one does!!!
[…] integration of Rhythmbox, make sure you only enable one of the two plug-ins! If you want to use the new-style plug-in, you need the lastfm client. The latest beta package for Ubuntu is available on the Last.fm […]
This is cool, GJ!
Im not sure about this: Do you need to have the last.fm client running?
Since the profile updating is kinda odd..
Richard, it depends on which plugin you use. The old plugin doesn’t need the last.fm client, it scrobbles directly. The new plugin, on the other hand, requires that the last.fm client is running.
Make sure you only have one of the two last.fm plugins enabled in the rhythmbox configuration.
A million of Thanks!!! :_D
with Ubuntu Gutsy, i’ve followed your manual, installed from that repo ( deb http://blog.blackdown.de/static/debian/rhythmbox/ gutsy main ) the new rhythmbox and then activate the plugin but i can’t see any differebce!
antistress, did you also install the last.fm client from http://www.last.fm/download/?showplatform=Linux ?
Love it and thianks for the feisty apt repo. Is it me or are podcasts not scrobbled?
That’s quite possible, I didn’t test it with podcasts. I’ll take a look at it for the next release.
Wow, this is cool! I never used Last.fm in Windows, so I didn’t even know about this feature, it really is cool! :-) I’ve only noticed a minor unicode problem (I run Ubuntu in croatian language), but it affects ONLY the library tabs, so it’s not really a big problem to me, it just looks a little bit ugly… :-p But they could be unreadable for somebody using a non-latinic alphabet, it could be frustrating to him/her.
For antistress and other Ubuntu Gutsy users not having the original Last.fm client…
The client is available in the Universe repositories. To install it, just write “sudo apt-get install lastfm” in a terminal. ;-)
franko, you mean the library tabs in rhythmbox? Did they display correctly with Ubuntu’s rhythmbox package?
I followed the directions, but for some reason, the plugin isn’t appearing in the list of plugins in rhythmbox.
Yes, I mean those tabs where is written (by letter) “artist” (not the artist ID tag), or “genre” and so on… This 2 examples in croatian would be “izvođač” and “žanr”, but in your version of RB they are not displaying the đ, č nor ž characters… so imagine a non-latinic alphabet… But like I said, it’s not affecting the ID tags nor the menus, just and only the those library tabs (if they are called so).
And yes, the original Ubuntu’s rhythmbox package used to display them correctly on my computer.
franko, I’ll probably need a test case.
I have many tracks with letters like that, as well as Japanese tagged tracks, and tracks using other unicode characters (like →). They all get displayed correctly.
Ben, please check the output of “
dpkg -s rhythmbox | grep Version
“.On gutsy it should say:
Version: 0.11.2-0ubuntu4jk1
It just says Version: 0.11.2-0ubuntu4
I don’t know what step I missed.
Whoo. I got it working now. I’m embarrassed to say it was a typo that messed me up.
:)
Juergen said:
“franko, I’ll probably need a test case.
I have many tracks with letters like that, as well as Japanese tagged tracks, and tracks using other unicode characters (like →). They all get displayed correctly.”
Yes, it’s like I said before, this bug is NOT affecting the ID tags of the tracks, they are displaying correctly here, too. Check up my last comment one more time. It affects ONLY the tabs, more exactly the TABS’ NAMES.
So, it doesn’t really make a big problem, but I thought it would be OK to tell you about.
hmm… maybe if it is still unclear, I could send you a screenshot. It’s a bit difficult to explain what I am talking about…
That would be good. I’m not 100% sure what you mean with TABS.
OK, I will send you a shot as soon as I can.
Can you, please, resend me an e-mail, so I can send you those shots. I lost the last one because I had to reinstall the whole system and I forgot to do a backup of the e-mails… But thanks to this situation I had the chance to compare before and after the installation of RB from your repository. It seems that your version uses a complete different croatian language pack… And maybe that’s where the problem is, maybe the translators fucked up something. Is it possible to change it somehow?
But anyway, it’s strange. Both RB’s say they are v. 0.11.2, so I don’t understand why don’t they use the same version of the translation… Maybe because you compiled it in Feisty and so now RB uses Feisty’s lang pack even on my Gutsy?
The gutsy package should be OK, it was built on gutsy. It might be possible that there’s something broken with build environment though. I’ll check.
Great job men.
10x
Works great, with a little exception:
if i listen a song twice, it scrobbles it only one time
thought you shoult now
I know. It’s no bug though, it’s a “feature” of the last.fm application and happens on all platforms. I can’t remember why they implemented it that way but they probably had a reason…
Einsame Spitze.
Was habe ich mich nach dem Umstieg auf Ubuntu über solche vermeintlichen ‘Kleinigkeiten’ geärgert – aber dieses Plugin ist Klasse, ich fühle mich richtig zuhause wieder… :-)
Bloody good job, thanks a lot for this plugin.
I don’t quite get it. Why is scrobbling through the original client better? After all, that’s one more application running and consuming memory. What’s more, on a Gnome desktop QT stuff kinda feels out of place.
Alexander, the main point for me is that the last.fm client provides more information than the old plugin. It also always you to “love” tracks.
I’d prefer to have that additional functionality integrated in Rhythmbox but, honestly, I don’t have the time to code that.
I’m getting a error with 0.11.3 with the new plugin and Last.fm client 1.4 (beta), you can get here: http://www.last.fm/group/Audioscrobbler+Beta/forum/30705/_/353678 . It will be nice you take a look before 1.4 be final released. Chers!
Will take a look at it. I might need more information though. I haven’t tried the latest beta version yet but the older 1.4 beta versions worked fine for me on Hardy.
Yes, the first beta used to work. When I play a song I get an error box saying that it wasnt possible to listen the socket. Error 99.
I’m using Gutsy by the way. ;-)
I’ve just released updated gutsy and hardy builds. They work fine for me with the current last.fm beta.
Fabio, this error message comes from the last.fm application and not the Rhythmbox plugin. The last.fm application listens on a socket, the plugin connects to that and submits track info.
For some reason the last.fm app seems to have problems on your machine. You might want to check your network configuration (e.g. is the loopback device set up correctly?).
How about a direct link to the plugin instead of a repository? It currently errors out on me because the repository doesn’t have an x64 version. I’d also rather keep my current version of Rhythmbox from the official repositories.
Yea, I’m think about using an add-on package instead of providing a full-blown rhythmbox package. It wouldn’t help you right now though, because the plugin is an IA32 binary. Until I get around to build AMD64 packages your only option is to build it yourself:
Thanks for the instructions, it worked well. If anyone is interested, the package I built is here …
http://ribbed.us/linux/rhythmbox/rhythmbox_0.11.3-0ubuntu3jk1g_amd64.deb
Much thanks again!
Is this possible under Debian? I’m running Lenny, which provides 10.1, however I am able to pull 11.2 from the experimental repo, but there is no 11.3. I would love to be able to use this since my rhythmbox refuses to scrobble anymore using the default plugin.
Andrew, you could try adding the “deb”-lines to /etc/apt/sources.list. If the package doesn’t install because of dependency problems, then just use the “deb-src” line and build the package yourself. See my previous comment on how to do that.
vern, thanks!
Juergen Kreileder, I saw now that the problem is my machine. This problem started when I changed my old router for a wifi one. I will try some hacking here. Thx anyway!!!
Thanks for the patch, this is great.
this is awesome, again thank you for a cool plug-in.
does this have any effect on fingerprint analysis through the new version of the LFM client? I can’t seem to see any fingerprinting being done though the Diagnostics dialog.
Yea, i have to check that. There’s probably a problem with the URI for the file.
Enabling the new style scrobbler in Ubuntu Hardy makes Rhythmbox play nothing… The songs are correctly selected but the counter doesn’t leave the 0:00 mark, the Last.fm client correctly recognizes the song being played and Rhythmbox hangs when closing it. If I change the audio sinks in System>Preferences>Sound to ALSA (Ubuntu is moving to PulseAudio) it works, but breaks a lot of other stuff (eg sound in Flash movies).
Gabriel, ALSA works fine for me (including flash).
I have to test the Last.fm client with PulseAudio. Does Rhythmbox + PulseAudio work without lastfm for you?
Yes, it does work if I disable the New Style scrobbler. I guess the problem is on the Last.fm app’s side though.
First thanks a lot for this plugin. But I need to ask a question since I’m stupidly new to Ubuntu and doesn’t understand much about the terminal and commanding. Whenever I tried to write the command it says that no directory or file found. I also tried to do it with “run with custom command” I know the question is probably idiotic, but can you help?
What’s going on with New Style? Rhythmbox updated itself to 0.11.3 last week and ever since, the New Style plugin won’t work. I can’t for the life of me get Rhythmbox 0.11.4 to work because of random totem plugins that won’t install. Thus, the v3 patch won’t work.
On top of this, the built-in last.fm plugin has crapped out (again) and submits tracks tagged as being played 7 hours in advance. Everything I submit gets flagged as spam.
How do I get New Style working with 0.11.3?