LiveTL / HyperChat

Improved YouTube chat with CPU/RAM optimizations, customization options, and cutting-edge features!

Home Page:https://livetl.app/hyperchat

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Delayed messages

KentoNishi opened this issue · comments

Checklist

  • This is an issue for Hyperchat, not LiveTL. I will go to the LiveTL repo to report an issue with LiveTL.
  • This issue is not a matter of opinion. If it is, I will use the feature suggestion issue template.
  • I have checked for a duplicate or similar issue. I made sure to check closed issues as well.
  • I am still able to reproduce the issue after I reinstall the extension.
  • I have clear instructions to reproduce the bug, even on another machine.
  • I am not suggesting a feature. If I am, I will use the feature suggestion issue template.
  • By submitting this issue, you agree to follow our Code of Conduct

Describe the bug

Apparently, many users are experiencing a thing where all messages are delayed in a live environment. This sounds like an issue of us adding too much of a delay once the chunk is received. Since live chat chunks are so frequent, can we just not add any delay to live messages? We can keep it for archived chats, but for live ones, we can just show messages instantly without worrying about timing,

Steps To Reproduce

To find users complaining about this, just go to the Hololive fan discord and search "hyperchat."

Expected behavior

no delay

What browsers are you seeing the problem on?

Firefox, Chrome, Microsoft Edge, Other (Put it in the "Anything else?" section)

Anything else?

No response

I think the issue is here? It's probably stacking up a lot of delays over time

HyperChat/src/ts/queue.ts

Lines 194 to 199 in 32597d9

/**
* Extra delay is calculated based on previous chunk delay, and will only
* be applied if the current chunk is also delayed.
* Hopefully this reduces chat freezing for subsequent late chunks, while
* not adding extra delay when chunks arrive normally.
*/

Yeah I guess we can remove that. I added that to prevent visual chat "freezes" because YTC is dumb and can sometimes send message chunks later than they're supposed to arrive, which means chat will stop between the last message in the previous chunk until the next (late) chunk arrives.

I guess I could've been fixing a non-existent issue there, and just leave chat be when that happens.