After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 705070 - Last.fm/libre.fm integration
Last.fm/libre.fm integration
Status: RESOLVED FIXED
Product: gnome-music
Classification: Applications
Component: general
unspecified
Other Linux
: Normal enhancement
: 3.18
Assigned To: gnome-music-maint
gnome-music-maint
: 742336 (view as bug list)
Depends on: 728621
Blocks:
 
 
Reported: 2013-07-29 11:44 UTC by Vadim Rutkovsky
Modified: 2015-09-17 13:49 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Vadim Rutkovsky 2013-07-29 11:44:36 UTC
A tracking bug for last/libre.fm integration.

TODO:
1) Authentication
2) Scrobbling
3) Last.fm stats
4) last.fm radio
Comment 1 Felipe Borges 2013-08-13 22:32:55 UTC
I have talked to Debarshi Ray about having LastFM as a gnome-online-accounts provider[0]. Since GOA is a core GNOME service, it would enable other apps to authenticate against LastFM on the GNOME Desktop.

In the meantime, we are discussing with the GNOME Board what are the legal issues/restrictions we could face by supporting LastFM in GOA[1]. As soon as we receive an 'OK' to go ahead, we will write this provider.

By having a LastFM Goa provider, Music only needs to care about scrobbling (which is easy to implement due to LastFM's API[2]), and I'm currently looking at to bring this feature to Music.

In terms of design, IMO we don't need to add any dialog to set the Scrobbler. If it's set to scrobble on the gnome-online-accounts preference dialog, we should scrobble automatically. This is basically what GNOME Documents does for Google Drive Sync (if it is enabled on Goa, then it syncs automatically).

In the future we can think about having Profile Stats, Radios and etc... on the UI.

[0] https://developer.gnome.org/goa/stable/ch08.html
[1] http://www.lastfm.com.br/api/tos
[2] http://www.lastfm.com.br/api
Comment 2 Felipe Borges 2014-04-20 19:15:46 UTC
It's been a long time since we discussed the LastFM support in GNOME Music. As I initially proposed, we should let GOA (gnome-online-accounts) handle the authentication part. I've just proposed a patch to GOA which includes LastFM authentication[0]. After that, I'll write a Scrobbler to GNOME Music.

We still need (want), as vrutkovs listed above:
3) Last.fm stats
4) Last.fm radio

[0] https://bugzilla.gnome.org/show_bug.cgi?id=728621
Comment 3 Vadim Rutkovsky 2014-04-20 20:26:48 UTC
(In reply to comment #2)
> It's been a long time since we discussed the LastFM support in GNOME Music. As
> I initially proposed, we should let GOA (gnome-online-accounts) handle the
> authentication part.
Nice work, Felipe!

> We still need (want), as vrutkovs listed above:
> 3) Last.fm stats
> 4) Last.fm radio
I guess this should be implemented as a grilo-plugin, but I'm sure we can think this through later on.
Comment 4 Vadim Rutkovsky 2015-01-06 11:26:08 UTC
*** Bug 742336 has been marked as a duplicate of this bug. ***
Comment 5 Nil Gradisnik 2015-06-22 17:48:10 UTC
I like the idea of GOA Last.fm integration. This way Last.fm session token can  be obtained from GOA in order to make authenticated requests.

My patch from bug 742336 was just a workaround to have a working Last.fm integration.

The only UI element needed is to enable/disable scrobbling.
Comment 6 Felipe Borges 2015-06-22 19:57:43 UTC
Hey Nil,

It's great to see that you have been working on the Last.fm scrobbling support on Music. I will land a GOA provider for lastfm soon. I haven't touched that code in a long time since we weren't in need of this feature.

About the UI discussion you were having in bug 742336, I guess it can be handled on GOA's side. We'd have a switch for Music in the LastFM provider settings dialog just like we already have for other services (as you can see in the discussion we had on bug 728621). In doing so, there's no need for any UI element on Music.
Comment 7 Allan Day 2015-06-23 11:04:50 UTC
(In reply to Felipe Borges from comment #6)
> ... In doing so, there's no need for
> any UI element on Music.

We could consider adding a control in Music scrobbling to be temporarily disabled. This would essentially be a privacy mode, in case you want to listen to something that you don't want others to know about.
Comment 8 Age Bosma (IRC: Forage) 2015-06-23 15:37:39 UTC
I'm not against a quick switch in Music itself. Temporary music for quick listening/testing isn't uncommon to me. This I wouldn't like to scrobble.

Something could be said about using a different program for that at the same time. Having to enable it in GOA as well as Music under certain circumstances can also be a source of confusion.
Comment 9 Allan Day 2015-07-03 15:30:02 UTC
I'm working on mockups for the configuration side of things, and the question of whether we support Libre.fm as well as Last.fm is looming.

I don't really know about Libre.fm, and I don't know anyone who uses it. All the discussion in this bug is about Last.fm.
Comment 10 Felipe Borges 2015-07-04 05:13:25 UTC
Ok, the patch is on bug 728621.

In case you need some code reference for the Goa integration, I've written a python script to post a message on an user's "shoutbox" using Goa credentials[0]. You can also see the C example on Goa source code at /src/examples/lastfm-shout.c.

In case you guys decide there's no need for a UI for it on Music, you'd just need to check whether the MUSIC_ENABLED property is toggled in the GoaAccount object.

https://gist.github.com/felipeborges/e4ce49970d2681ae04d2
Comment 11 Vadim Rutkovsky 2015-07-14 15:58:21 UTC
(In reply to Felipe Borges from comment #10)
> Ok, the patch is on bug 728621.

Thanks! Since https://git.gnome.org/browse/gnome-music/commit/?id=6a12183 Music will have Last.fm integration.

Keeping the bug open until GOA patch is pushed