-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cleanup SyncLibraryTask #129
Conversation
Hi, thanks ! So this is just a refactor, no functional change? |
Ok thanks. #127 merged in. |
Should I try to follow StyleCop, or try to leave as much code as possible as it is? I'm asking because of Ordering Rules, the diff then looks like this: https://gist.github.com/j2ghz/82ec9662a121aeb66a4a0538556a433a/revisions?diff=split |
If you're going to continue to make improvements to the plugin then you can do what you're most comfortable with. We don't use style cop but if you want to make non-functional code improvements that is fine. I think our number one wish list for this plugin would be to just have it work automatically without the need to manually run scheduled tasks. |
What do you think? |
About not needing manual tasks? is it even possible to make it better? Trakt won't let us know some data changed and anytime something changes in emby it is posted to trakt I think. But I will look into it. |
Or just continuing with the current work you were planning on. I was really just trying to see if this was still moving. Thanks. |
Are these changes stable? |
Fyi, I've moved the trakt plugin to it's own dedicated repo: https://github.com/MediaBrowser/trakt |
The changes are untested, but I didn't make any functional changes. It was mostly just extracting methods. |
I notice the SyncLibraryTask also updates emby watched states. Does this mean the SyncFromTrakt scheduled task is now obsolete? In other words, we now have two scheduled tasks updating watch data on the Emby side. |
With the #127 option disabled (default, same as before): SyncLibraryTask modifies Trakt With the option enabled: SyncLibraryTask resets any watches, that were not scrobbled, but just marked as watched. Scrobbles are processed elsewhere (event handlers), so in this case it doesn't change Trakt data at all. The tasks could (maybe even should) be merged, but SyncFromTrakt is not obsolete. |
I've cleaned up SyncLibraryTask and split it into multiple methods. Should I try to follow StyleCop, or try to leave as much code as possible as it is?
Includes: #108 #127