Skip to content
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

Youtube live chat does populate without 30 sec delay on live streams #25694

Open
snowbound opened this issue Sep 29, 2022 · 37 comments
Open

Youtube live chat does populate without 30 sec delay on live streams #25694

snowbound opened this issue Sep 29, 2022 · 37 comments
Labels
feature/shields/fingerprint The fingerprinting (aka: "device recognition") protection provided in Shields google OS/Desktop priority/P4 Planned work. We expect to get to it "soon". webcompat/not-shields-related Sites are breaking because of something other than Shields.
Projects

Comments

@snowbound
Copy link

snowbound commented Sep 29, 2022

Description

When one brings up a Live YouTube stream that also has a live chat. the live chat remains blank for 30 seconds

Steps to Reproduce

  1. Open up link to Live YouTube stream
  2. The chat window is blank even though video stream is playing

Actual result:

Expected result:

The live chat should display comments at the same time the live video starts playing

Reproduces how often:

Go to this stream for example

Brave version (brave://version info)

Version 1.45.75 Chromium: 106.0.5249.65

Version/Channel Information:

  • Can you reproduce this issue with the current release? Yes
  • Can you reproduce this issue with the beta channel? Yes
  • Can you reproduce this issue with the nightly channel? Do not know

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields? No
  • Does the issue resolve itself when disabling Brave Rewards? Always Disabled
  • Is the issue reproducible on the latest version of Chrome? No

Miscellaneous Information:

Outlined here in this [thread](https://community.brave.com/t/youtube-live-chat-30-sec-delay/432842/25

I have tried so many things over the past two weeks to narrow this issue down) at Brave Community

This issue is more noticeable when dealing with actual LIVE streams.

Yes, I have a new profile that has no extensions in it. I have tried the first 3 streams that Saoiray posted in that thread on the Brave community.

The first 2 streams are live streams and the chat takes 30 seconds to load. If I force a page to reload on these 2 streams it makes no difference. The 3rd stream, The Ramsey show is a recorded stream. That chat also takes 30 seconds to load HOWEVER once it gets into the cache then the chat loads fine when the page has a forced reload done on it. If you clear the browser's cache the issue comes back. I am on a 500Mbps symmetrical fibre connection.

I noticed this issue with LIVE streams in September. Before then the LIVE stream chats populated fine. This is not the first time however that this issue has happened in Brave.

[IAmDinkAMA in Brave's subreddit mentioned in a thread I started over there re this issue that he noticed that going to brave://net-internals/#dn and performing the clearing of host cache twice seemed to fix the issue when reloading of the page would cause the live chat to take 30 seconds to populate.

Alas that did not seem to fix the issue. I have tried this numerous times in an empty profile and whenever I cleared the browser cache in that profile the loading of the live chat takes 30 seconds or so. What I did notice was that during these 30 seconds Brave showed waiting for fonts.gstatic.com

P.S. I am using this live stream for my testing

@snowbound
Copy link
Author

Still happening on [Version 1.45.78 Chromium: 106.0.5249.65 (Official Build) beta (64-bit)

@ryanbr
Copy link

ryanbr commented Oct 8, 2022

I saw a brief delay then showed, then when I refresh the site it showed instantly (like caching the page). So works for me?

This is a Clean Brave Beta profile. No extensions.

@snowbound
Copy link
Author

It is like a 20 sec delay on all live streams here before the live chat populates.

@snowbound
Copy link
Author

I have attached the output from Devtools when I initiated a reload of my test stream
Brave YT Chat issue.txt

@snowbound
Copy link
Author

Is anyone from Brave Dev going to bother looking at the dump or should I just go back to MS Edge or Chrome the latter has no issues with chat populating properly?

@snowbound
Copy link
Author

Further testing results https://community.brave.com/t/youtube-live-chat-30-sec-delay/432842/49?u=fedup if this was something on this computer outside of the browser then why is Chrome, Firefox and MS Edge Beta not experiencing this delay?

@snowbound
Copy link
Author

snowbound commented Nov 8, 2022

This is a screen capture that I did in a new profile on Brave Beta. The issue is happening on a brand new WIndows10 computer here with Brave with a new profile. This new computer has no security software or antivirus other than the stock Windows10.

To have the issue occur

  1. Open empty tab.
  2. Clear cache.
  3. Paste in the URL for this test screen.
  4. Problem occurs.

This problem not occurring in Google Chrome, MS Edge or Firefox. I notice on occasion the browser is waiting for a gstatic or other google servers to respond.

Version 1.46.99 Chromium: 107.0.5304.91 (Official Build) beta (64-bit)

Brave.Live.Chat.Lag.mp4

@snowbound
Copy link
Author

Version 1.47.91 Chromium: 108.0.5359.48 (Official Build) nightly (64-bit)](https://brave.com/latest/)

@snowbound
Copy link
Author

snowbound commented Nov 26, 2022

On a clean install of Version 1.48.5 Chromium: 108.0.5359.48 (Official Build) nightly (64-bit) with no extensions, if the Brave shields are down a non-skippable ad plays followed by a skippable ad plays. The chat does not populate until the skippable ad is skipped. With Brave shields up and the tab reloads the video plays but the live chat is delayed by about 20 secs.

@snowbound
Copy link
Author

This issue is indeed a Brave one. I installed Vivaldi with the same extensions and settings as those in Brave and Vivaldi has no issue with the YT Tube live streams chat populating as soon as the video stream starts.

@lukemulks
Copy link

Hi @snowbound - taking a look into this one as well.

@lukemulks
Copy link

Just attempted to reproduce from Win10 on:

1.48.32 Chromium: 108.0.5359.94 (Official Build) nightly (64-bit)

Chat loads within 2-3 seconds of page load for me.

Testing from this page provided at top of issue: https://www.youtube.com/watch?v=jfKfPfyJRdk

Going to update and attempt to repro from latest version of Nightly.

@lukemulks
Copy link

I was able to reproduce in:

1.48.41 Chromium: 108.0.5359.99 (Official Build) nightly (64-bit)

  • Observed livestream playback without the chat, for longer than 10 seconds.
  • Opened dev tools (in separate / detached window)
  • Switched tab to brave://version to copy the version info.
  • Switched back to YT tab: video was blank, chat was blank, then within ~3 seconds, both the stream and the chat displayed as expected.

Seemed like switching tabs triggered the live chat to display.

Going to attempt to get a console print from refresh to see if there are any clues there, and will tag in some folks from the team to dig in deeper.

@lukemulks
Copy link

Was able to get some more info on refresh - I think I may have some indication of what could be going on here. Going to summon some bigger brains than mine on this one to double check.

I don't think it's an issue related to our filter lists for ad blocking.

When I refreshed, here's what I saw, which aligns with what @snowbound reported.

  • Livestream began playing following initial page load.
  • Chat was blank and not displaying concurrently with livestream (unexpected)
  • When I toggled back to Dev tools, and then returned to the tab with the YT stream, both the livestream and the chat flashed and displayed as expected. Note, this was not toggling from one tab to another, but changing in-focus view from YT tab to Dev Tools window, and then back to YT tab in focus (just in case that matters, compared to engaging from tab to tab from the same window).

I captured some interesting messages printed to the console.

Disregard the red errors, as those appear to be the shields doing their thing.

Here's the full print from refresh to when the chat began to work as expected
brave-yt-investigation-12092022-console-print-full

Here's a close-up of the area that jumped out at me when reviewing the console
brave-yt-investigation-12092022-console-print-details

Tagging in @bsclifton @rebron who may know who best to tag in to put some eyeballs to test this theory, but here's what appears may be happening.

It looks like I'm seeing some timeouts with event handlers that may be taking place ahead of when GreaseLion loads.

Could be a race condition or some other conflict that's causing the chat not to initially load, but then begin displaying as expected when switching back and forth (alt+tab on win or command+tab on macos) between tabs.

Not 100% sure, but seems like it's a load order issue with how GreaseLion functions in this scenario - don't suspect it's filter list related, as if it were, I'd observe consistent behavior when toggling between tabs. Wouldn't expect the chat to begin displaying concurrently with video if this was a filter/shield issue.

Hope this helps - but one to dig in on given it's YT and Windows.

@rebron rebron added google webcompat/not-shields-related Sites are breaking because of something other than Shields. feature/shields/fingerprint The fingerprinting (aka: "device recognition") protection provided in Shields labels Dec 10, 2022
@rebron rebron added this to Untriaged Backlog in General Dec 13, 2022
@rebron rebron added the priority/P4 Planned work. We expect to get to it "soon". label Dec 13, 2022
@Brave-Matt
Copy link

User left dev tools data dump info for review:
Clean profile:
Brave YouTube live chat issue dump1.txt
Users regular profile:
Brave YouTube live chat issue dump regular profile2.txt

cc @rebron @spylogsster

@snowbound
Copy link
Author

Is there any more information Brave devs need from me for this 6+ month old issue? It is still happening on Version 1.49.91 Chromium: 110.0.5481.77

@snowbound
Copy link
Author

This issue may be YT running preroll ads on live streams. I fired up MS Edge Beta today and it had what seemed to be a 30-60 second ad on a live stream. During the first 20 seconds of the ad the live chat would not populate. Once the ad reached a certain point the live chat showed up.

@ghost
Copy link

ghost commented Mar 15, 2023

happens to me too on windows10 and brave [Version 1.49.120 Chromium: 111.0.5563.64 (Official Build) (64-bit)]

it appears to be random: sometimes it happens, and sometimes it doesn't.

@snowbound
Copy link
Author

snowbound commented Mar 15, 2023

@sbernecchia the random is could be due to 2 issues.

The stream may not have any preroll non-skippable ads OR the stream has to be paused then the browser cache has to be cleared and the YT page for the stream has to be reloaded sometimes to see the effect. What I have discovered is that if one has UBlock installed in Brave using the standard block lists (with Brave shields down) you see the preroll ad that is causing the issue. If however, you have Brave shields enabled with ad blocking (aggressive or not) then the preroll ad is blocked HOWEVER the live chat populating is delayed until the 20-second mark of the non-skippable preroll ad gets to the 20-second mark.

Even if Brave has no additional filter list items checked it is still blocking the preroll ad but can not fix the live chat populating until the 20-second mark. This issue has existed since early Sept 2022 in Brave all builds. Others are no doubt seeing this issue but do not realize the chat issue is caused by preroll non-skippable ads.

Vivavaldi even with UBlock Origin installed using the same settings as UBlock in Brave does not have this chat issue. I see the chat populate right away

@ScrapBlox
Copy link

Happens to me to. View this post for my brave/windows setup

@snowbound
Copy link
Author

@ScrapBlox
Thanks for adding your voice to this bug in Brave. So frustrating to see a browser like Vivaldi have no such issue yet Brave does no matter what rules or rule set you select for ad blocking.

@snowbound
Copy link
Author

It is up to Brave Devs to figure this bug out. I had a YT stream where I disabled all ad blocking and saw no ads yet I saw the 20 second delay in loading the chat. I as an end user can only do so much. I have seen this happen on countless systems here some with a brand new clean install on a clean Win10 install with no extensions. I have had friends having the same issue with YT chat.

I give up @lukemulks

@ScrapBlox
Copy link

Yup I've already given up on brave browser as I need youtube live and chats. As a viewer and broadcaster I need it. I now use vivaldi

@snowbound
Copy link
Author

@ScrapBlox especially when you have to moderate live chats 20 seconds seems like an eternity.

@snowbound
Copy link
Author

snowbound commented Apr 26, 2023

@rebron
This issue is not only happening in Live YT streams but recordings which have YT chats included in the recording. One example is https://www.youtube.com/watch?v=FqSg1tykt2s

You see this just before chat does load

vTools failed to load source map: Could not load content for https://www.youtube.com/s/desktop/945ad0b2/jsbin/web-animations-next-lite.min.vflset/web-animations-next-lite.min.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
/generate_204?2GK2A:1 GET https://www.youtube.com/generate_204?_2GK2A net::ERR_BLOCKED_BY_CLIENT
Image (async)
eval @ VM6459:1
GJ @ watch:1
eval @ watch:1
Rl @ watch:1
li @ watch:1
N @ watch:1
d
@ watch:1
C @ watch:1
Y.IxX_ @ watch:1
eq @ watch:1
$e @ watch:1
Xj @ base.js:773
oJa @ base.js:4108
(anonymous) @ base.js:4107
(anonymous) @ spf.js:24
r @ spf.js:19
Db @ spf.js:24
Pb @ spf.js:33
(anonymous) @ spf.js:18
setTimeout (async)
g @ spf.js:34
load (async)
Rb @ spf.js:34
Nb @ spf.js:32
ec @ spf.js:41
(anonymous) @ base.js:2237
pJa @ base.js:4107
(anonymous) @ base.js:9372
wJa @ base.js:4115
(anonymous) @ base.js:4128
(anonymous) @ base.js:4145
Promise.then (async)
PJa @ base.js:4145
(anonymous) @ base.js:11306
(anonymous) @ base.js:7940
live_chat_polymer.js:2315 LegacyDataMixin will be applied to all legacy elements.
Set _legacyUndefinedCheck: true on element class to enable.
9The resource was preloaded using link preload but not used within a few seconds from the window's load event. Please make sure it has an appropriate as value and it is preloaded intentionally.
base.js:1867 POST https://www.youtube.com/api/stats/qoe?fmt=247&afmt=251&cpn=iP9IkwNZTHTCTkgy&el=detailpage&ns=yt&fexp=23983296%2C23986019%2C24004644%2C24007246%2C24080738%2C24135310%2C24219382%2C24255165%2C24405913%2C24415864%2C24416291%2C24433679%2C24437577%2C24439361%2C24449113%2C24460285%2C24462372%2C24468691%2C24469652%2C24489377%2C24499532%2C24499792%2C24514873%2C24515201%2C24516157%2C24539776%2C24550457%2C24558068%2C39323074&cl=526486891&seq=2&docid=FqSg1tykt2s&ei=_o1JZNL6HYv92_gP6NOruAk&event=streamingstats&plid=AAX6Q1rpSTWSOToT&cbr=Chrome&cbrver=112.0.0.0&c=WEB&cver=2.20230425.08.00&cplayer=UNIPLAYER&cos=Windows&cosver=10.0&cplatform=DESKTOP&cmt=0.044:0.000,2.458:508.827,3.964:508.827,4.820:509.674,10.570:515.425&vps=0.044:B,2.458:S,3.964:PL,10.570:PL&ctmp=mdstm:t.3632;rst4disc.d;cd.0.000;sq.-1,mdstm:t.3740;rst4disc.d;cd.0.000;sq.-1&bh=3.964:1.174,10.570:0.000&bwm=10.570:4884769:3.659&bwe=10.570:782041&bat=10.570:1:1&df=10.570:2 net::ERR_BLOCKED_BY_CLIENT
Gy @ base.js:1867
(anonymous) @ base.js:1852
JYa @ base.js:5752
(anonymous) @ base.js:5766
(anonymous) @ base.js:8179
PYa @ base.js:5765
(anonymous) @ base.js:11020
(anonymous) @ base.js:5770
(anonymous) @ base.js:1821
www.google.com/pagead/lvz?evtid=AAnBwfY-14ojTD6O7qrdCeP7l9zbtE1S7nQdkeFpSPa49vlQyqUiyStGbQ2uflJS8aImSuXrUS3GRVHoLBuFaYdjrhh7aPOfzg&req_ts=1682542078&pg=MainAppBootstrap%3AWatch&az=1&sigh=ADCDuE9adZDcWy_K4Avwl_lRPzGRY7OHXw:1 GET https://www.google.com/pagead/lvz?evtid=AAnBwfY-14ojTD6O7qrdCeP7l9zbtE1S7nQdkeFpSPa49vlQyqUiyStGbQ2uflJS8aImSuXrUS3GRVHoLBuFaYdjrhh7aPOfzg&req_ts=1682542078&pg=MainAppBootstrap%3AWatch&az=1&sigh=ADCDuE9adZDcWy_K4Avwl_lRPzGRY7OHXw net::ERR_BLOCKED_BY_CLIENT
Image (async)
Era @ desktop_polymer.js:1866
$m @ desktop_polymer.js:1863
UFc @ desktop_polymer.js:22019
P @ scheduler.js:30
V @ scheduler.js:39
(anonymous) @ scheduler.js:35
(anonymous) @ web-animations-next-lite.min.js:96
requestAnimationFrame (async)
(anonymous) @ web-animations-next-lite.min.js:96
(anonymous) @ scheduler.js:40
Q @ scheduler.js:26
pa @ scheduler.js:45
(anonymous) @ desktop_polymer.js:1571
sAb @ desktop_polymer.js:9927
tAb @ desktop_polymer.js:9931
(anonymous) @ desktop_polymer.js:9930
vl @ desktop_polymer.js:1565
requestRenderChunk_ @ desktop_polymer.js:11509
(anonymous) @ desktop_polymer.js:11508
(anonymous) @ desktop_polymer.js:3442
fHa @ desktop_polymer.js:3134
characterData (async)
run @ desktop_polymer.js:3141
(anonymous) @ desktop_polymer.js:3802
attached @ desktop_polymer.js:10233
(anonymous) @ desktop_polymer.js:3832
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
insertBefore @ webcomponents-sd.js:64
(anonymous) @ webcomponents-sd.js:121
stampDomArraySplices_ @ desktop_polymer.js:10208
rendererStamperApplyChangeRecord_ @ desktop_polymer.js:10204
rendererStamperObserver_ @ desktop_polymer.js:10201
THa @ desktop_polymer.js:3255
Yq @ desktop_polymer.js:3237
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3281
(anonymous) @ desktop_polymer.js:3304
eIa @ desktop_polymer.js:3262
Zq @ desktop_polymer.js:3263
(anonymous) @ desktop_polymer.js:3299
fillRange_ @ desktop_polymer.js:11507
renderChunk_ @ desktop_polymer.js:11511
(anonymous) @ desktop_polymer.js:9925
P @ scheduler.js:30
V @ scheduler.js:39
(anonymous) @ scheduler.js:35
(anonymous) @ web-animations-next-lite.min.js:96
requestAnimationFrame (async)
(anonymous) @ web-animations-next-lite.min.js:96
(anonymous) @ scheduler.js:40
Q @ scheduler.js:26
pa @ scheduler.js:45
(anonymous) @ desktop_polymer.js:1571
sAb @ desktop_polymer.js:9927
tAb @ desktop_polymer.js:9931
(anonymous) @ desktop_polymer.js:9930
vl @ desktop_polymer.js:1565
requestRenderChunk_ @ desktop_polymer.js:11509
(anonymous) @ desktop_polymer.js:11508
(anonymous) @ desktop_polymer.js:3442
fHa @ desktop_polymer.js:3134
characterData (async)
run @ desktop_polymer.js:3141
(anonymous) @ desktop_polymer.js:3802
attached @ desktop_polymer.js:10233
(anonymous) @ desktop_polymer.js:3832
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
insertBefore @ webcomponents-sd.js:64
(anonymous) @ webcomponents-sd.js:121
stampDomArraySplices_ @ desktop_polymer.js:10208
rendererStamperApplyChangeRecord_ @ desktop_polymer.js:10204
rendererStamperObserver_ @ desktop_polymer.js:10201
THa @ desktop_polymer.js:3255
Yq @ desktop_polymer.js:3237
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3281
(anonymous) @ desktop_polymer.js:3304
eIa @ desktop_polymer.js:3262
Zq @ desktop_polymer.js:3263
(anonymous) @ desktop_polymer.js:3299
fillRange_ @ desktop_polymer.js:11507
renderChunk_ @ desktop_polymer.js:11511
(anonymous) @ desktop_polymer.js:9925
P @ scheduler.js:30
V @ scheduler.js:39
(anonymous) @ scheduler.js:35
(anonymous) @ web-animations-next-lite.min.js:96
requestAnimationFrame (async)
(anonymous) @ web-animations-next-lite.min.js:96
(anonymous) @ scheduler.js:40
Q @ scheduler.js:26
pa @ scheduler.js:45
(anonymous) @ desktop_polymer.js:1571
sAb @ desktop_polymer.js:9927
tAb @ desktop_polymer.js:9931
(anonymous) @ desktop_polymer.js:9930
vl @ desktop_polymer.js:1565
requestRenderChunk_ @ desktop_polymer.js:11509
(anonymous) @ desktop_polymer.js:11508
(anonymous) @ desktop_polymer.js:3442
fHa @ desktop_polymer.js:3134
characterData (async)
run @ desktop_polymer.js:3141
(anonymous) @ desktop_polymer.js:3802
attached @ desktop_polymer.js:10233
(anonymous) @ desktop_polymer.js:3832
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
insertBefore @ webcomponents-sd.js:64
(anonymous) @ webcomponents-sd.js:121
stampDomArraySplices_ @ desktop_polymer.js:10208
rendererStamperApplyChangeRecord_ @ desktop_polymer.js:10204
rendererStamperObserver_ @ desktop_polymer.js:10201
THa @ desktop_polymer.js:3255
Yq @ desktop_polymer.js:3237
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3281
(anonymous) @ desktop_polymer.js:3304
eIa @ desktop_polymer.js:3262
Zq @ desktop_polymer.js:3263
(anonymous) @ desktop_polymer.js:3299
fillRange_ @ desktop_polymer.js:11507
renderChunk_ @ desktop_polymer.js:11511
(anonymous) @ desktop_polymer.js:9925
P @ scheduler.js:30
V @ scheduler.js:39
(anonymous) @ scheduler.js:35
(anonymous) @ web-animations-next-lite.min.js:96
requestAnimationFrame (async)
(anonymous) @ web-animations-next-lite.min.js:96
(anonymous) @ scheduler.js:40
Q @ scheduler.js:26
pa @ scheduler.js:45
(anonymous) @ desktop_polymer.js:1571
sAb @ desktop_polymer.js:9927
tAb @ desktop_polymer.js:9931
(anonymous) @ desktop_polymer.js:9930
vl @ desktop_polymer.js:1565
requestRenderChunk_ @ desktop_polymer.js:11509
(anonymous) @ desktop_polymer.js:11508
(anonymous) @ desktop_polymer.js:3442
fHa @ desktop_polymer.js:3134
characterData (async)
run @ desktop_polymer.js:3141
(anonymous) @ desktop_polymer.js:3802
attached @ desktop_polymer.js:10233
(anonymous) @ desktop_polymer.js:3832
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
insertBefore @ webcomponents-sd.js:64
(anonymous) @ webcomponents-sd.js:121
stampDomArraySplices_ @ desktop_polymer.js:10208
rendererStamperApplyChangeRecord_ @ desktop_polymer.js:10204
rendererStamperObserver_ @ desktop_polymer.js:10201
THa @ desktop_polymer.js:3255
Yq @ desktop_polymer.js:3237
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3281
(anonymous) @ desktop_polymer.js:3304
eIa @ desktop_polymer.js:3262
Zq @ desktop_polymer.js:3263
(anonymous) @ desktop_polymer.js:3299
fillRange_ @ desktop_polymer.js:11507
renderChunk_ @ desktop_polymer.js:11511
(anonymous) @ desktop_polymer.js:9925
P @ scheduler.js:30
V @ scheduler.js:39
(anonymous) @ scheduler.js:35
(anonymous) @ web-animations-next-lite.min.js:96
requestAnimationFrame (async)
(anonymous) @ web-animations-next-lite.min.js:96
(anonymous) @ scheduler.js:40
Q @ scheduler.js:26
pa @ scheduler.js:45
(anonymous) @ desktop_polymer.js:1571
sAb @ desktop_polymer.js:9927
tAb @ desktop_polymer.js:9931
(anonymous) @ desktop_polymer.js:9930
vl @ desktop_polymer.js:1565
requestRenderChunk_ @ desktop_polymer.js:11509
(anonymous) @ desktop_polymer.js:11508
(anonymous) @ desktop_polymer.js:3442
fHa @ desktop_polymer.js:3134
characterData (async)
run @ desktop_polymer.js:3141
(anonymous) @ desktop_polymer.js:3802
attached @ desktop_polymer.js:10233
(anonymous) @ desktop_polymer.js:3832
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
attachShadow @ webcomponents-sd.js:95
(anonymous) @ webcomponents-sd.js:123
(anonymous) @ desktop_polymer.js:3361
(anonymous) @ desktop_polymer.js:3360
(anonymous) @ desktop_polymer.js:3283
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3287
(anonymous) @ desktop_polymer.js:3359
(anonymous) @ desktop_polymer.js:3669
(anonymous) @ desktop_polymer.js:3769
(anonymous) @ desktop_polymer.js:3831
(anonymous) @ desktop_polymer.js:3159
(anonymous) @ desktop_polymer.js:3758
(anonymous) @ desktop_polymer.js:3179
(anonymous) @ desktop_polymer.js:3358
(anonymous) @ desktop_polymer.js:3670
(anonymous) @ desktop_polymer.js:3760
insertBefore @ webcomponents-sd.js:64
(anonymous) @ webcomponents-sd.js:121
stampDomArraySplices_ @ desktop_polymer.js:10208
rendererStamperApplyChangeRecord_ @ desktop_polymer.js:10204
rendererStamperObserver_ @ desktop_polymer.js:10201
THa @ desktop_polymer.js:3255
Yq @ desktop_polymer.js:3237
(anonymous) @ desktop_polymer.js:3289
(anonymous) @ desktop_polymer.js:3160
(anonymous) @ desktop_polymer.js:3281
(anonymous) @ desktop_polymer.js:3304
eIa @ desktop_polymer.js:3262
Zq @ desktop_polymer.js:3263
(anonymous) @ desktop_polymer.js:3299
fillRange_ @ desktop_polymer.js:11507
renderChunk_ @ desktop_polymer.js:11511
(anonymous) @ desktop_polymer.js:9925
P @ scheduler.js:30
V @ scheduler.js:39
(anonymous) @ scheduler.js:35
(anonymous) @ web-animations-next-lite.min.js:96
www.google.ca/pagead/lvz?evtid=AAnBwfY-14ojTD6O7qrdCeP7l9zbtE1S7nQdkeFpSPa49vlQyqUiyStGbQ2uflJS8aImSuXrUS3GRVHoLBuFaYdjrhh7aPOfzg&req_ts=1682542078&pg=MainAppBootstrap%3AWatch&az=1&sigh=ADCDuE9adZDcWy_K4Avwl_lRPzGRY7OHXw:1 GET https://www.google.ca/pagead/lvz?evtid=AAnBwfY-14ojTD6O7qrdCeP7l9zbtE1S7nQdkeFpSPa49vlQyqUiyStGbQ2uflJS8aImSuXrUS3GRVHoLBuFaYdjrhh7aPOfzg&req_ts=1682542078&pg=MainAppBootstrap%3AWatch&az=1&sigh=ADCDuE9adZDcWy_K4Avwl_lRPzGRY7OHXw net::ERR_BLOCKED_BY_CLIENT
Image

@snowbound
Copy link
Author

snowbound commented Apr 28, 2023

@Brave-Matt

Sigh. This is even happening in Brave Version 1.53.5 Chromium: 113.0.5672.53 (Official Build) nightly (64-bit). If you go to https://www.youtube.com/watch?v=jfKfPfyJRdk and force a reload of the page the chat will take 20+ seconds to show up. Out of 10 forced reloads on the page 6 of the 10 reloads caused the chat to take 20+ seconds to populate!!

If that is normal for Brave please will someone from Brave here tell me so and I will ditch Brave from all my systems and mobile. Imagine being a content creator on YouTube and having to wait 20+ seconds before you see the chat or before your moderators can start their moderation. Twenty seconds can feel like an eternity.

@snowbound
Copy link
Author

snowbound commented May 2, 2023

This is from the stream I use for testing https://www.youtube.com/watch?v=jfKfPfyJRdk on Windows10

image

Where the arrow is about where the live chat finally decided to populate properly. This is from Brave
Version 1.53.10 Chromium: 113.0.5672.63 (Official Build) nightly (64-bit)

This issue is across all 3 versions of Brave. If the issue does not occur the first time a stream in YT is played then repeated reloading of that live stream will cause the issue to occur. I have yet to see a live stream does not exhibit this issue.

@snowbound
Copy link
Author

snowbound commented May 10, 2023

If a live stream has an issue loading the chat when one starts playing the stream, the symptom also occurs if you then hide the chat and then try to show the chat. You have to wait 20+ seconds for the chat to show up. If the stream has no such issue when initially playing it then hiding and show chat works as expected.

@bsclifton
Copy link
Member

bsclifton commented May 10, 2023

When testing with @ryanbr, it seemed to show (for both of us) on average every 1/10 times. The other 9 times the chat loads fine. I did find a request which took a long time to process... this might be a good clue

Basically, with the Dev Tools / Network tab open, I waited until the 1. The issue reproduced 2. The chat showed itself after 20-30 seconds.

Then looked for the long running requests. I narrowed down to the outbound request I had for:

https://www.youtube.com/live_chat?continuation=0ofMyAN-Gl5DaWtxSndvWVZVTlRTalJuYTFaRE5rNXlka2xKT0hWdGVuUm1NRTkzRWd0cVprdG1VR1o1U2xKa2F4b1Q2cWpkdVFFTkNndHFaa3RtVUdaNVNsSmtheUFCTUFBJTNEMAGCAQYIBBgCIACIAQGgAZirmIz06_4CqAEAsgEA

Had the following stats:
image

You can see it took 20 seconds to resolve. I also noticed some weird service worker activity taking place right before this outbound call was made (these are requests in sequential order; first made ones towards top).
image

So https://www.youtube.com/live_chat?continuation was hit- seems it failed. Then (the gear icon) the service worker is also red. Those both are marked as Stalled. The service worker one has 1.8 minutes as the run time.
image

@pes10k could anything about our service workers (any deviations we have from Chromium) cause this?

@snowbound
Copy link
Author

snowbound commented May 10, 2023

I can say that this is happening across all 3 of Brave builds, release, beta and nightly more than 1 out of 10 times for me during regular viewing of the live streams with chats. It is rare for me to have a chat load properly. Today from 4 different live chats 3 out of 4 failed.

I have found that repeatedly force reloading the stream will cause the issue to occur. Also pausing the stream and then force reloading the stream can also duplicate the issue. I am not the only end-user seeing this issue. Something happened back in early Sept 2022 that caused this issue to occur.

@bsclifton
Copy link
Member

bsclifton commented May 11, 2023

@snowbound repeatedly force reloading is consistent with what I'm seeing. Although, I get good results when opening dev tools (F12) and checking the box Disable cache (should be at the top of the dev tools). With the dev tools open, I can only reproduce the issue when this box is unchecked.
image

With that checked, I'm curious if you can reproduce the issue. You can try reloading the page and dev tools will stay open. Let me know

@snowbound
Copy link
Author

snowbound commented May 11, 2023

@bsclifton I have over the past 8 months tried disabling the cache several times and that did not solve the issue. I can not remember if I had Dev tools open on each instance. I have Nightly installed and I can not find that option.

Update
I finally found the setting whose location changed in Dev Tools compared to Beta when I used it last. Will try disabling cache w Dev tools open and see if that provides any relief.

@bsclifton
Copy link
Member

bsclifton commented May 11, 2023

@snowbound awesome - let us know if keeping dev tools open and then having Disable cache fixes the issue for you every time.

This isn't the proper solution of course - but if that works 100% of the time, it does help narrow the problem down for us. With that enabled, I gave up after reloading the page about 50 times because it worked each time.

@snowbound
Copy link
Author

@bsclifton After 2 days of getting notifications and rather than clicking on the notification, I went to my YT subscriptions page and did a F12 and only then clicked on a Livestream the chats all loaded promptly.

Another end user on the Brave subreddit back in Nov or Dec 2022 mentioned disabling the cache but they said it did not always work. I tried it at that time but did not at the time realize that the Dev window had to be open for the disabled cache to be active

@snowbound
Copy link
Author

@bsclifton
It appears that using F12 Developers console and disabling cache no longer works to allow the live YT chat to populate properly. I guess it is fitting on the one year "celebration of this bug.

@cyfung1031
Copy link

cyfung1031 commented Nov 11, 2023

@snowbound @bsclifton
Here is an unofficial solution - https://greasyfork.org/en/scripts/474214-fix-brave-bug-for-youtube-live-chat
Also See https://community.brave.com/t/youtube-live-chat-30-sec-delay/432842

There is an issue for Brave to load the iframe content and the url will become about:blank with an empty body.
YouTube modifies the DOM element creation and Brave injects scriptlets (no disable option in Brave) for every webpage including iframe content. I believe it is due to the conflict with iframe creation and scriptlet injection.
For example, the scriptlet runs some coding which is not allowed at the initial stage so the iframe content loading is stopped.

The 30s is set by YouTube's engine. YouTube can detect if the content is not displayed then refresh the iframe. This is not implemented by Brave.

@snowbound
Copy link
Author

@cyfung1031 Yes I am the original poster for that Brave Community thread and have been using that thread which you fixed earlier this week. There is also another issue with Brave in live YT chats blanking out the posting area in the chat

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature/shields/fingerprint The fingerprinting (aka: "device recognition") protection provided in Shields google OS/Desktop priority/P4 Planned work. We expect to get to it "soon". webcompat/not-shields-related Sites are breaking because of something other than Shields.
Projects
General
  
Untriaged Backlog
Development

No branches or pull requests

8 participants