avi12 / youtube-auto-hd

A simple browser extension for changing YouTube videos' quality based on FPS.
https://avi12.com/youtube-auto-hd
GNU General Public License v3.0
235 stars 28 forks source link

[Bug] Quality won't change to the correct one #113

Closed 54m4d closed 1 year ago

54m4d commented 1 year ago

Describe the bug

1440p
30 FPS and below

1080p
31-50 FPS videos

1080p
51-60 FPS videos

How to reproduce

Look above ⬆

Expected behavior

With the configuration above, the video should run at 1440p@30FPS but the actual behaviour is that it's running at 1440p@60FPS

What browser(s) can you reproduce the issue on?

Chrome

What OS does it occur on?

Windows

What's the version you're running?

1.8.1

Make sure the bug wasn't reported before

Additional context

No response

avi12 commented 1 year ago

Sounds like #110

avi12 commented 1 year ago

Does it work: chrome-mv3-prod.zip

54m4d commented 1 year ago

No, it still goes for the 1440p@60PFS.

avi12 commented 1 year ago

Wait, I think I misunderstood Did you expect that a 60FPS video will be converted to 30FPS?

54m4d commented 1 year ago

Sorry, read the expected behaviour again, i mistyped the quality.

If you look at my settings, any video higher than 30fps should stay at 1080p@60FPS if available, and any video that is 30fps or below must play at 1440p if available.

avi12 commented 1 year ago

Can you record your screen reproducing the issue?

54m4d commented 1 year ago

Watch the video.

Same issue also in Firefox.

avi12 commented 1 year ago

Huh, that issue is weird

54m4d commented 1 year ago

Yes, it's an issue started happening a week ago or so.

avi12 commented 1 year ago

After lots of digging, I discovered that the bug is in https://github.com/avi12/youtube-auto-hd/blob/24a3e31825574b1e3b34fba55e9789a1bffac9bd/src/shared-scripts/ythd-utils.ts#L147

Please verify that this version is working correctly: chrome-mv3-prod.zip

54m4d commented 1 year ago

Seems to be the cause yes, everything is working as expected now, i will wait for an update through CS.

Thanks for your great support.