HOW TO: synchronise your last.fm playback stats with foobar, ...works with CUI and DUI |
![]() ![]() |
HOW TO: synchronise your last.fm playback stats with foobar, ...works with CUI and DUI |
Nov 18 2011, 12:28
Post
#676
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
i'd check your system for nasties. getting the proxy changed like that is not good....
|
|
|
|
Nov 19 2011, 01:05
Post
#677
|
|
![]() Group: Members Posts: 31 Joined: 27-August 10 Member No.: 83420 |
Database entry update on mass scrobble?
When using foobar ipod manager it imports the play counts, audioscrobbler then scrobbles them on the next submit. afaik the songs scrobbled this way do not update on your database. Any chance of that? |
|
|
|
Nov 19 2011, 02:08
Post
#678
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
i don't think this would be possible. i can fetch a user's entire last.fm library OR individual track details with user info. i don't have access to an ipod and even if i did, i believe it would be extremely cumbersome fetching info for a subset of tracks each time.
|
|
|
|
Nov 19 2011, 12:28
Post
#679
|
|
|
Group: Members Posts: 9 Joined: 29-April 11 Member No.: 90191 |
Hi marc,
I have a question... Is there an option to update the LastFM playcount info on loading a track in a playlist automatically? I often scrobble from my phone, and i'd like, if its possible, the foobar to update the info from lastFM without updating the whole database manually from Library import... Now actually it auto updates playcount only when the track plays for a few second (may be when scrobbles?). Thank you in advance! |
|
|
|
Nov 20 2011, 05:12
Post
#680
|
|
|
Group: Members Posts: 85 Joined: 12-March 10 Member No.: 78963 |
Hi marc, couldn't help but notice the discussions about updating the database to sync with scrobbles from other devices. I too often scrobble from my Windows Mobile device, and got to admit it would be cool if I could sync just the last played tracks instead of the whole library.
Wouldn't it be possible then to perform an (optional) check on startup for the last, let's say, 50 scrobbled tracks and update the database accordingly by syncing track-by-track? Perhaps just adding a menu item on the Un/Love Button do to it instead of / in addition to doing it automatically on startup would be better since it may be slow, but that's a matter of testing. Since the API does provide the list of last played tracks (http://www.last.fm/api/show?service=278), it may be worth a shot. This post has been edited by BrutuZ: Nov 20 2011, 05:14 -------------------- http://www.last.fm/user/BrutuZ
|
|
|
|
Nov 20 2011, 09:47
Post
#681
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
i'm not keen on using that API because instead of getting the real playcount value, i'd have to keep running totals (given a track could appear multiple times) and then add the values to my database. i'd have no way to verify the final values are accurate - well other than making a list of artist/titles and sending an individual request to the trackinfo method for each one but that would be a bit crap....
i'll think about it. |
|
|
|
Nov 30 2011, 16:06
Post
#682
|
|
|
Group: Members Posts: 6 Joined: 22-March 11 Member No.: 89211 |
Hey marc, I've been using your scripts for a long time, but after upgrading WSH to 1.5.0 and your Last.fm script to the latest version something broke.
It's been a couple of weeks, I was waiting to see if anyone else had this problem or to a new version to be release; but since neither happened I'm writing for help. It throws this error message: Scripting Engine Initialization Failed (Playcount Sync by marc2003, CODE: 0x80020101) The relevant console log: CODE WSH Panel Mod ({AC02127E-FD87-4354-8BFE-673DB837A5D4}): Parsing file "C:\Users\for4saken\AppData\Roaming\foobar2000\marc2003\common.js" WSH Panel Mod ({AC02127E-FD87-4354-8BFE-673DB837A5D4}): Parsing file "C:\Users\for4saken\AppData\Roaming\foobar2000\marc2003\tooltip_buttons.js" WSH Panel Mod ({AC02127E-FD87-4354-8BFE-673DB837A5D4}): initialized in 16 ms WSH Panel Mod (Playcount Sync by marc2003): Parsing file "C:\Users\for4saken\AppData\Roaming\foobar2000\marc2003\common4.js" WSH Panel Mod (Playcount Sync by marc2003): Parsing file "C:\Users\for4saken\AppData\Roaming\foobar2000\marc2003\tooltip_buttons.js" Error: WSH Panel Mod (Playcount Sync by marc2003): Erro em tempo de execução do Microsoft JScript: O servidor de automação não pode criar objeto File: C:\Users\for4saken\AppData\Roaming\foobar2000\marc2003\common4.js Ln: 375, Col: 1 <source text only available at compile time> The line in question: var vb = new ActiveXObject('ScriptControl'); Any other script of yours that imports common4.js fails with the same error. I'm using a heavily customized version of MonolitePlus, which imports an old version of common.js and it's working. Any help would be immensely appreciated. |
|
|
|
Nov 30 2011, 16:32
Post
#683
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
if you clear the panel completely and have just this one line of code, i'm assuming it will also crash??
CODE var vb = new ActiveXObject('ScriptControl'); if that's the case then there must be something wrong with your windows setup and i have no idea what that could be? maybe some internet explorer security settings or files have been stripped away during a custom install?? i'm just guessing though.... that code is only required for the input dialogs so assuming you've already got your username and api key set, you could comment it out as a temporary workaround. the line following needs to be commented out also, like this... CODE //var vb = new ActiveXObject('ScriptControl'); //vb.Language = 'VBScript'; selecting any menu item that spawns an input dialog would also cause the panel to crash but for normal usage it should be fine. |
|
|
|
Nov 30 2011, 18:57
Post
#684
|
|
|
Group: Members Posts: 6 Joined: 22-March 11 Member No.: 89211 |
This workaround helped!
Thank you. I cannot imagine what could be the problem, as I've said, I've been using your scripts for a couple years and besides updating WSH noting relevant changed system-wise. I tried a clean foobar install, clean reinstall of the scripts; nothing. That's why I've cried for help |
|
|
|
Jan 19 2012, 14:16
Post
#685
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
updated: http://dl.dropbox.com/u/22801321/playcount%20sync.zip
added option to auto-updates submenu: only update tracks in library. the default is off (update all tracks) which is the current behaviour. |
|
|
|
Jan 23 2012, 21:44
Post
#686
|
|
|
Group: Members Posts: 8 Joined: 9-September 11 Member No.: 93601 |
Hi Marc. Great script. Really well done. I was wondering, does the script still work if you remove the WSH Panel Mod panel? It's a little bit out of place in my foobar setup.
|
|
|
|
Jan 23 2012, 22:13
Post
#687
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
no, you can't remove the panel. how else would it work?
possible workarounds: if using columns UI, you can highlight it in the layout tab and hide it. using default UI, you could put in a tab that you rarely use. again using default UI, you could put your whole layout in the top half of top/bottom splitter. then put the WSH panel in bottom half. it might look something like this.... http://dl.dropbox.com/u/22801321/lastfm%20...nt%20before.png now drag the splitter down as far as it will go and you'll end up with this. you can notice a gap between the seekbar and status bar but i think it blends in well. http://dl.dropbox.com/u/22801321/lastfm%20...unt%20after.png you can then right click on the splitter and lock the bottom panel so it stays hidden even when resizing foobar. edit: corrected columns UI instructions. This post has been edited by marc2003: Jan 23 2012, 22:20 |
|
|
|
Jan 23 2012, 23:52
Post
#688
|
|
|
Group: Members Posts: 8 Joined: 9-September 11 Member No.: 93601 |
Did it by hiding in Columns UI. Perfect. Thanks.
|
|
|
|
Jan 27 2012, 17:40
Post
#689
|
|
![]() Group: Members Posts: 81 Joined: 8-August 07 Member No.: 46047 |
edit: nevermind, had an outdated version of the wsh panel
This post has been edited by radecke: Jan 27 2012, 17:45 -------------------- --> neugablonz.de ;)
|
|
|
|
Jan 30 2012, 05:57
Post
#690
|
|
|
Group: Members Posts: 5 Joined: 30-January 12 Member No.: 96796 |
updated: http://dl.dropbox.com/u/22801321/playcount%20sync.zip added option to auto-updates submenu: only update tracks in library. the default is off (update all tracks) which is the current behaviour. Just to report, I found a little issue with this version when used with Columns UI + ELPlaylist. Previously Loved tracks get unloved when the tracks Last.FM Playcount gets updated. To fix, just comment out the line "if (old_userloved == 1) fb.RunContextCommandWithMetadb("Customdb Love 0", g_metadb, 8);"in "function process() " |
|
|
|
Jan 30 2012, 06:30
Post
#691
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
i didn't put that line in by mistake. i need to remove the record from the database before updating the playcount. i then set it back to loved straight away. i use ELplaylist myself and it always updates properly. if yours doesn't then you could try adding this at line 195:
CODE fb.RunMainMenuCommand("View/ELPlaylist/Refresh");
This post has been edited by marc2003: Jan 30 2012, 06:33 |
|
|
|
Feb 28 2012, 21:01
Post
#692
|
|
|
Group: Members Posts: 1 Joined: 28-February 12 Member No.: 97468 |
Thanks a lot for this script Marc. I am usually not a person who posts on forums, but this time I just have to clarify how awesome this script is and why it beats stuff like playback statistcs.
In my honest opinion, playback statistics doesn't say anything about the amount of music you are listening to. Most of the people are listening to the music through their portable devices (mp3 player, smartphone, etc.). Due to this fact I spent a lot of time trying to synchronize my mp3 tags with the same mp3 files on my portable device. After days of research I figured out, that the best method of synchronization is in using an online database. That also implies things like replacing old file tracks with some better quality ones without loosing the playcount. (I stored playcounts directly in mp3 tags) So finally I found this thread and decided to give it a try. I have to admit that I had to replace my whole portable version of foobar to a new one. But after a clean setup it worked pretty well. Though in the beginning I was afraid of a following scenario: Day 1: track A has 6 plays on my personal last.fm (last.fm = 6; custom_db = 0) Day 2: after installing your script I am listening to track A one more time (last.fm = 7; custom_db = 7) Day 3: durring the bus drive I am listening to track A for additional 2 times offline on my Sansa Clip+ with Rockbox. (last.fm = 7; custom_db = 7) Day 4: I am uploading my last.fm scrobble listfile from my MP3 player to last.fm (last.fm = 9; custom_db = 7) Day 5: I am listening to the track A at home using foobar (last.fm = 10; custom_db = 8?) It is true that the track count is on 7 instead of the actual 10, but after playing the song one more time in foobar it retrives the correct playcount. (means including my mp3 player counts) After a couple of weeks I can still decide to import the whole last.fm data again, in order to display more accurate countvalues. What I actually wanted to say - even though this thread seems to be pretty inconspicuous, it was the one and only solution for my picky perceptions of statistics. This way I can sort and play the best tracks on our flat parties according to my total overall listening experience. This post has been edited by Cпутник: Feb 28 2012, 21:04 |
|
|
|
Feb 28 2012, 22:39
Post
#693
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
^glad you find it useful.
a little update.... http://dl.dropbox.com/u/22801321/playcount%20sync.zip the icons can now be changed via the context menu. there is a choice of the original tango icon which is the same 32px in size and if you choose the silk icon, it will be 20px. existing users, make sure the marc2003 folder gets extracted again so you get the required images - but people who use my other samples will already have them. EDIT: i just re-uploaded to squish a little bug i introduced. this only applies to the new version from 30 minutes ago. This post has been edited by marc2003: Feb 28 2012, 23:13 |
|
|
|
Mar 1 2012, 14:58
Post
#694
|
|
|
Group: Members Posts: 29 Joined: 17-June 08 Member No.: 54499 |
I'm runnig fb2k through WINE on Linux Mint 12 and I'm gettting this error on launch:
![]() There is nothing in the console. EDIT: after I did "winetricks wsh56" i get the following: Scripting Engine Initialization Failed (Playcount Sync by marc2003, CODE: 0x80020101) Check the console for more information (Always caused by unexcepted script error). from the console: Error: WSH Panel Mod (Playcount Sync by marc2003): Microsoft JScript runtime error: Automation server can't create object File: Z:\media\4E362CDE362CC8B3\Dropbox\Applications\foobar2000-linux\marc2003\common4.js Ln: 396, Col: 1 This post has been edited by enigmatik: Mar 1 2012, 15:34 |
|
|
|
Mar 1 2012, 15:38
Post
#695
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
here's an old post listing all the winetricks stuff i installed...
http://www.hydrogenaudio.org/forums/index....st&p=744005 |
|
|
|
Mar 1 2012, 15:59
Post
#696
|
|
|
Group: Members Posts: 29 Joined: 17-June 08 Member No.: 54499 |
Tried to do winetricks ie6 but it said it can't find it (broken link or something) so I did winetricks ie7 and all the rest on your list but still same error.
|
|
|
|
Mar 1 2012, 16:05
Post
#697
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
and you disabled safe mode in the WSH panel mod preferences?
|
|
|
|
Mar 1 2012, 16:07
Post
#698
|
|
|
Group: Members Posts: 29 Joined: 17-June 08 Member No.: 54499 |
Yes.
|
|
|
|
Mar 1 2012, 16:09
Post
#699
|
|
![]() Group: Members Posts: 3339 Joined: 27-January 05 From: England Member No.: 19379 |
in that case, i have no idea.
|
|
|
|
Mar 1 2012, 16:09
Post
#700
|
|
|
Group: Members Posts: 29 Joined: 17-June 08 Member No.: 54499 |
I actually did something wrong with ie... I'll report back.
|
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 19th June 2013 - 09:19 |