codemonument / deno_audio_logbook

A deno fresh server, with a telegram bot to receive audio messages and a website to show all messages of a user in a calendar
2 stars 0 forks source link

Preview Bot Login Widget fails to show up 80% of reloads #26

Closed bjesuiter closed 1 year ago

bjesuiter commented 1 year ago

I've a strange error with the preview bot page at: https://deno-audio-logbook-preview.deno.dev/auth/login

State: I'm NOT logged in

  1. I open the url: https://deno-audio-logbook-preview.deno.dev/auth/login Result:

    Bildschirmfoto 2023-04-06 um 21 23 35
  2. I klick nothing and reload the page 2 - 10. times

Observation

Sometimes the widget loads and some time it doesn't.

Screenshot when it doesn't load:

Bildschirmfoto 2023-04-06 um 21 25 31

Other Things tried

I tried to replicate that bug with the main url: https://deno-audio-logbook.deno.dev/auth/login But even after 10 tries, the widget is shown every time.

Bildschirmfoto 2023-04-06 um 21 26 52
Bloodiko commented 1 year ago

image Request seems to be cancelled by SOMETHING,

But i cannot seem to find a pattern, why and when

bjesuiter commented 1 year ago

Probable Explanation:

The TelegramLogin Island Component will be server rendered, sent to the client and then hydrated with preact. Before hydration, the server render will successfully load the telegram login iframe, but as soon as preact gets hydrated, it overwrites the dom inside itself, basically killing the iframe