Kodi Community Forum
[RELEASE] Trakt Utilities (addon for Trakt.tv usage) - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Program Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=151)
+---- Thread: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) (/showthread.php?tid=98582)



RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - Death-Axe - 2012-08-29

Thank you sir.


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - SpoBo - 2012-08-29

(2012-08-28, 23:05)seadog Wrote: Yeah the bar's next on my list, just trying to see if I can improve the json performance at all

edit: Just pushed a version with the progress bar into the feature/frodo branch, still trying to find a way to make the JSON RPC faster though...

Thx Smile Performance isn't that big of a deal if the user is aware something is happening.

Once all your old stuff is synced next syncs will be very vast. So it doesn't latter that much.

The only optimisation imo is to mark everything as watched in 1 big call. But I guess that's not possible yet in XBMC's API. Don't worry about it too much yet Smile Features are more important than speed for now. Besides, that's why there is an API in XBMC now. Stuff can be optimised inside of XBMC and not inside the scripts. It's just a bit silly that it's so slow for now.


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - seadog - 2012-08-29

It is possible, but there are a couple of problems, first of all it takes basically as long, there's a small gain but it's really not very much, and doing it that way (I tried sending updates in batches of 100) also stops me being able to update the % counter except after the batch of 100, so you get a situation where there are minutes between updates and it goes from 0% -> 37% or whatever in one jump.


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - SpoBo - 2012-08-29

Ok got it. So it's definitely something that has to be sped up by the XBMC devs. The way the script does it at the moment is perfectly fine then Smile I saw you started on TV syncing as well. Nice :p


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - DejaVu - 2012-08-30

(2012-08-29, 01:20)seadog Wrote: Fair enough, I'll remove them all when I've finished fixing frodo syncing
Did I just read that right?

Do you have a version of TU syncing with Trakt from a Frodo build?
I rolled back to Eden purely because I needed to sync my Library (MySQL).

If so, how far have you got? Is it usable yet? Can I test it from your Github?
Or still a WIP and a lot of issues?



RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - seadog - 2012-08-30

(2012-08-30, 00:28)DejaVu Wrote:
(2012-08-29, 01:20)seadog Wrote: Fair enough, I'll remove them all when I've finished fixing frodo syncing
Did I just read that right?

Do you have a version of TU syncing with Trakt from a Frodo build?
I rolled back to Eden purely because I needed to sync my Library (MySQL).

If so, how far have you got? Is it usable yet? Can I test it from your Github?
Or still a WIP and a lot of issues?

Movie syncing works, tv syncing works too though I'm redoing it at the moment so it's using the old code (which is fine in that it works, it's just a bit of a mess), the only problem is it's slow because I can't do direct DB access anymore (though this really only matters for the first sync, after that it's fine). If you want to try it just make sure you grab https://github.com/seadog/script.traktutilities/zipball/feature/frodo which is the correct branch,

Everything else is pretty much the same in terms of working or not, the change to frodo didn't really break much at all (though I still need to re-add eden support in the version I just linked to, so it'll only work in frodo atm)


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - seadog - 2012-08-30

OK, _hopefully_ TV Syncing (but not cleaning!) should now work with the new algorithm, I've just pushed it to the feature/frodo branch again, tomorrow I'll finish testing it properly, add eden support in again, then probably integrate my advanced rating patches


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - SpoBo - 2012-08-30

It works but after a while it trips up and hangs. Happened 3 times already. First time at 2% then 6% and now 11%. When it isn't stuck it actually moves pretty fast.

Here is a pastebin when it was stuck at 11%: http://pastebin.com/6wV2UVFH


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - seadog - 2012-08-30

It only increments the % after each show's been synced, trying it here doesn't hang, if you're using linux run tail -f ~/.xbmc/temp/xbmc.log before running it to see the stream of what's happening, if it does actually hang on a trakt call that's rather weird... (did you restart xbmc after installing the addon?)

Oh weird I think I just hit a hang too, very odd indeed...


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - SpoBo - 2012-08-30

My pastebin is the xbmc.log output. Is there a way to get more output? ;o I do already tail it to see if it's hanging or not. And I did restart xbmc after pulling from git.


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - seadog - 2012-08-30

Hrm I just managed a full sync without any hanging at all, I'll keep looking to see if I'm doing something bad in the code (the only thing I can really think of is maybe I'm using too much memory or trakt is somehow blocking the connection?)
OK, I just pushed a newer version, I've removed the instant_sync code because I think it was interfering (at least here it start running for every added episode from the sync). Hopefully I can re-add the equivalent functionality later if this fixes it.

Nope another crash much later this time, I got a message about the home screen updating just as it crashed though

Hrm, the hang happens while episodes are being set as seen via the JSON API, "18:18:51 T:140504446498560 DEBUG: CRecentlyAddedJob::UpdateTotal() - Running RecentlyAdded home screen update" is output to the log just before everything stops working. It has nothing to do with the trakt connection.


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - SpoBo - 2012-08-30

Nice find! But what to do about it :x


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - seadog - 2012-08-30

I think I'll try filing a bug report with xbmc, since I believe it's a bug in the JSON RPC, though I could be wrong


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - Martijn - 2012-08-30

(2012-08-30, 21:31)seadog Wrote: I think I'll try filing a bug report with xbmc, since I believe it's a bug in the JSON RPC, though I could be wrong

Could also be the progressdialog that hangs.
Be sure to use a official nightly build and provide the crashlog +Debug Log when filing a trac ticket


RE: [RELEASE] Trakt Utilities (addon for Trakt.tv usage) - seadog - 2012-08-30

(2012-08-30, 21:32)Martijn Wrote:
(2012-08-30, 21:31)seadog Wrote: I think I'll try filing a bug report with xbmc, since I believe it's a bug in the JSON RPC, though I could be wrong

Could also be the progressdialog that hangs.
Be sure to use a official nightly build and provide the crashlog +debug log when filing a trac ticket

I just added a print after the executejsonrpc call to test this, what happens is that (as far as I can tell), I send the episodes to be updated over json rpc, they're being updated but then "CRecentlyAddedJob::UpdateTotal() - Running RecentlyAdded home screen update" hits and the executejsonrpc call never returns (as the thing I'm printing after the call never makes it to the logfile), do you think I should file this as a bug?

I've just searched and I can't find any linux nightly builds, if I include the git commit number I've compiled from and compile settings will that be OK?