New Scrobbler 2.0
This has been a long-time project of mine. Finally I had the time to implement it and well, it's (almost) done now. :-)
You can get it at https://github.com/Pitxyoki/audacious-plugins/. The source for the plugin itself is at src/scrobbler2.
- The plugin uses version 2.0 of the scrobbling API, which means no more username/password stored in plaintext on the config file (a revokable session key is stored instead).
- Man-in-the-middle/impersonation attacks are a bit more difficult now, though unfortunately this API still has some security flaws. I think we're better with this than we were with the previous version anyway.
- Configuration is now easier too. You only have to click a button, go to your last.fm profile, give permission to Audacious and tell it to re-check permissions.
I've been using it myself since the last weeks without issues.Some relevant things to be done before getting it pulled to Audacious:
- I'm not sure if the configuration window is easy to understand. I did it with a single button (see attachments for the complete flow) - it is simple, but I'm not sure if it isn't excessively simple now. What do you think?
- I saw on other plugins that functions like vfs_fopen, vfs_fclose, etc, from libaudcore/vfs.h are used for file manipulation. Should I be using that for handling the scrobble.log instead of the native fopen/fclose? The scrobble.log is a file on the user's config folder and is only written when a new track is ready to be scrobbled and after a track has been scrobbled, like the old scrobblequeue.txt.
- I'm not sure where and how to put licensing information. Should each source file mention it? I don't mind the license to be GPLv3 and I'd like to keep a mention on the plugin's source files that I am the initial author. Is there a "standard" way of doing this for Audacious' plugins? Each plugin seems to do it on its own way.
- I did not test playing Internet streams. There is probably a regression to the current plugin on this.
There are other minor features remaining to be implemented. You can see them on github: https://github.com/Pitxyoki/audacious-plugins/issues/.
With that said, I'd like to know what you think of the current state of the plugin. Is there anything else you'd like to see improved before pulling it? I'm open to criticism. :)
#1 Updated by John Lindgren over 10 years ago
- Target version set to 3.4
I will have to compile this and give it a try. It looks impressive. Using native fopen() is fine for a file in the user's config folder. http://www.gnu.org/licenses/gpl-howto.html has some cut-and-paste headers you can add to each source file if you want to use GPL3. Audacious itself is under a more permissive (and shorter) license, but of course you're free to use whatever license you like for the plugin.
What do you think of including this new plugin along with the old one for 3.4? That would allow more people to test it while still having the ability to switch back to the old one if something did not work correctly (such as scrobbling of internet streams).
#2 Updated by Luís Picciochi over 10 years ago
Thanks! If the plugin is included along with the old scrobbler, a restriction has to be made that both plugins must not be loaded at the same time, or you can be scrobbling twice to the same account without noticing. Is there an easy way to know the list of currently loaded plugins in runtime?
I'll be able to get my hands on this again probably by next week and close some of the needed enhancements. I didn't investigate what's special about streams on the old scrobbler but I can test them and see if anything needs to be done on this version (Do you have any particular URL with special features to test?). I guess in two or three weeks the plugin could be all polished and shiny. :-)
#3 Updated by John Lindgren over 10 years ago
I don't scrobble myself, but I believe some of the differences for streaming that had to be solved in the old plugin were (1) multiple titles are played without the "playback begin" hook being called and (2) the length of a song isn't known at the beginning of playback.
#4 Updated by John Lindgren over 10 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
Added in Git master.