-
-
Notifications
You must be signed in to change notification settings - Fork 203
Setting to skip post-video ads by force #244
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
base: main
Are you sure you want to change the base?
Conversation
|
This looks really cool, thanks for the PR. I'll take a look soon |
|
If anyone wants to test this, I've pushed an image: |
dmunozv04
left a comment
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.
I haven't checked, but we should make sure that a video ending in a sponsor segment would properly trigger the stop and not attempt to skip the sponsor segment, to be left with the post-video ads
| # Trigger a few frames earlier to avoid the video end event canceling the task | ||
| await asyncio.sleep(time_to - 0.1) | ||
| self.logger.info("Force stopping video, end of expected play time reached") | ||
| await asyncio.create_task(self.lounge_controller._command("stopVideo")) |
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.
This would be better if a new method was created on the YTLounge class
|
Good point, because of how scheduling works i don't believe that would trigger the force stop |
When a video is done YouTube sometimes plays +/- 30 seconds of ads after the video. This PR forcefully stops the video when its play time is over, returning to the app home screen and skipping the ads.