-
Notifications
You must be signed in to change notification settings - Fork 41
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
Mark (local) episode as watched when playing next #77
base: master
Are you sure you want to change the base?
Conversation
This comment has been minimized.
This comment has been minimized.
b720728
to
88924e5
Compare
This is now confirmed to be working. With the new settings we can actually use a large notification time (i.e. 60 secs) for very short episode (e.g. 7 mins) to easily test this. The default cutoff time for Marking as Watched is 8% which would be 32 secs for a 7 min episode. So if you would click on "Watch Now" the current episode would not be marked as watched, but be marked as unfinished. This is now fixed, and on top of that, batched JSONRPC queries work as well and are very efficient. |
2a5f690
to
53edfd2
Compare
3ed467c
to
4d345ba
Compare
This PR includes: - Mark the current episode as watched - Reset resume_time for next episode so it starts from beginning
4d345ba
to
122aca8
Compare
sleep(200) | ||
|
||
# Mark the current episode as watched and reset position | ||
jsonrpc(dict(method='VideoLibrary.SetEpisodeDetails', params=dict(episodeid=current_episodeid, playcount=1, resume=dict(position=0)))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We probably want to increase the existing playcount, rather than set it to 1 to indicate watched.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not to sure, from memory I think Kodi only cares about it being either 0 or 1 and I think some addons possibly check for it actually being 1 to mark as watched.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correct if you only consider the Watched flag. But I just recently made a pull request to add this information to the Video info pane so it is exposed to the user in Kodi Matrix 🙄
So we might as well do the right thing here. Especially since we already have the playcount IIRC.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool so my memory was correct! Yeah let’s go for it then 😉
I've just noticed that I've been having this problem, too - I'm looking forward to turning on this PR |
@notoco This is just for local media, we are waiting for changes in Kodi (see xbmc/xbmc#17202) to be accepted. That would allow us to do the same for VOD content (plugin:// URLs). Which would be a neat feature for Up Next to have! |
This PR includes:
Reset resume position of the next episode before playingThis fixes #64 for local media.