dbvideostriketeam / wubloader

MIT License
15 stars 8 forks source link

thrimbletrimmer: When no end time set, show and auto-refresh chat #456

Open ekimekim opened 2 weeks ago

ekimekim commented 2 weeks ago

We request current time + 1 minute, and re-request every 10 seconds.

If I'm reading the code correctly, everything already correctly handles the chat being replaced by a new fetch (as though we loaded a new video range).

ElementalAlchemist commented 2 weeks ago

Chat can sometimes take a really long time to render (this is why we put it off to a background worker). How long of ranges/much chat was this tested on? Should we do this less frequently than 10 seconds?

ekimekim commented 2 weeks ago

This was not tested.

ekimekim commented 2 weeks ago

My hope was that it would be frequent enough for someone watching live. If that's not feasible without a smart "what changed" algorithm, we can do without.

ElementalAlchemist commented 5 days ago

I just remembered this also: Doesn't the server-side chat functionality only update with new chat once per minute?

ekimekim commented 5 days ago

Yes, chat_archiver only writes out chat to disk once a minute, and even that is on a minute or so's delay.

ElementalAlchemist commented 3 days ago

This won't fix that the chat archiver only updates once per minute, but I believe I've made the chat handling much faster in the SolidJS version (I keep the state progress that videoHumanTimeFromDateTime recalculates for every chat message in the current version). If the chat_archiver thing can be resolved, the SolidJS scheduled package may be of interest. (Even if it can't, we could use that and pull on a longer basis, say, 30-60 seconds.)