JohnyP36 / YT-Nonstop

Extension to let YouTube run nonstop with autoplay, autoconfirm and automatic pressing the loopbutton.
GNU General Public License v2.0
14 stars 1 forks source link

Constant Reloading After Ublock/Google Changes to Ads #22

Closed oven8Mitts closed 9 months ago

oven8Mitts commented 10 months ago

Prerequisites

I tried to reproduce the issue when...

Describe the issue

Getting reloading of the video as the page loads, occurs on every single page. Would occur about 50% of days since Google began blocking users who used Adblock. Now occurs every day.

Console log entry when reloading: Could find play button; page got reloaded Disabling the YT Nonstop plugin fixes the reload issue.

Screenshot(s)

No response

Browser & Extension version

Firefox 119.0 64bit

Operating System & Version

Windows 10 22H2

Notes

I use Sponsorblock, Ublock, and an older YT downloader plugin that isn't available anymore. I disabled all 3 to confirm no issues. Also verified anything like Tampermonkey is disabled.

github-actions[bot] commented 10 months ago

Hey @oven8Mitts! Thank you for contributing to my extension. Do you also like to sponsor this project?

JohnyP36 commented 10 months ago

Hi @oven8Mitts. Thanks for your feedback.

Can you follow these steps and report what is happening.

  1. Give me the version number of my extension you are using. Is should be 2.0.9.2.
  2. Go to www.youtube.com
  3. Open your console logger
  4. Click on a random video on the homepage or search for one
  5. Filter your console log on YT Nonstop and copy all messages (right mouse click on one of the log entries)

I got the following console log messages:

[YT Nonstop] 02:40:55 | Could find play button; page got reloaded     www.youtube.com:17:15
[YT Nonstop] 02:40:55 | Autoplay has been disabled     www.youtube.com:17:15
[YT Nonstop v2.0.9.2]                                  autoconfirm.js:48:9
[YT Nonstop] 02:41:03 | Autoplay has been disabled     watch:17:15
[YT Nonstop] 02:41:03 | Autoplay has been disabled     watch:17:15
[YT Nonstop] 02:41:08 | Autoplay has been disabled     watch:17:15
[YT Nonstop] 02:41:08 | Autoplay has been disabled     watch:17:15
[YT Nonstop] 02:41:13 | Autoplay has been disabled     watch:17:15
[YT Nonstop] 02:41:17 | Active Time Reset              watch:5:15

As you see I also got the Couldn't find play button; page got reloaded, but that occurs due to the fact that my extension was faster than Youtube got the video loaded. Normally this only happens the first time you go to YT and play a video, because if you reload the page (F5) the play button is already in the site code of YT and thus you will only get 3 console log messages

[YT Nonstop v2.0.9.2]                              autoconfirm.js:48:9
[YT Nonstop] 02:52:27 | Autoplay has been disabled watch:17:15
[YT Nonstop] 02:52:39 | Active Time Reset          watch:5:15

The above will also happen if you directly open a YT video by pasting a link (e.g. Shuffle Dance Music playlist) and also for Youtube Music. if you enabled loop playlist, you will also see the message Playlist is been looped.


To keep a long story short: Although there have been many reports of Google/Youtube blocking users if they use Adblockers (see https://github.com/uBlockOrigin/uAssets/issues/19976 and please also try what is suggested there) I never encountered this issue and whatever I try I can't reproduce your issue.

oven8Mitts commented 9 months ago

I cannot reproduce at this time. 2.0.9.4. Perhaps there was a patch? Close the issue as needed. Thanks

JohnyP36 commented 9 months ago

I cannot reproduce at this time. 2.0.9.4. Perhaps there was a patch? Close the issue as needed. Thanks

I disabled the try-and-catch method. But the downside of this is that if the extension can't find the play button it will not work properly and you need to manually refresh the page. It's either constant reloading or possible not working properly. I can't fix both issues.