humphd/bridge-troll

Sometimes page never loads

aushakou opened this issue · 10 comments

Sometimes page never loads maybe because geolocation position doesn't load.

Windows 10
Chrome Version 65.0.3325.162 (Official Build) (64-bit)
Node 9.8.0
npm 5.6.0

Fix up in #17 if you want to review

@humphd The same behavior. Works perfectly in Brave browser and Firefox, but in Chrome there is like 5% chance that page will load instantly, 5% chance that page will load after a while, and 90% chance that page will never load.

chrome

Your screenshot above isn't running my new code. Did you git fetch remote and git checkout issue-8 first?

Based on my testing, what seems to fail in Chrome is the reload case: things work, they you reload and it starts failing. I notice this Chromium bug on file:

https://bugs.chromium.org/p/chromium/issues/detail?id=452549

We're using both watchPostion and getCurrentPosition, which might mean we're hitting this bug. We could try and switch away from using getCurrentPosition and only use watchPosition. I'll update my PR, in case that helps.

@humphd My bad, I was testing webpack branch (referring to my last comment).

Ok, I checked issue-8 branch and behavior in chrome is still weird. Mostly, the page loads right after the server starts and sometimes starts failing after reloading. But sometimes the page doesn't load right after the server starts and then works after reloading.

chrome

Nevertheless, it feels like it works better now and the failing rate dropped down.

Try pulling again, I pushed another commit that might help.

@humphd I was about to say that this issue is fixed and then loading failed (infinite loading) a few times.

I think that this, combined with the webpack fix, might cover it all. What if I merge and we file more bugs on top as we test?

Landed on master. If you re-pull master now, you'll get webpack + this, which I hope will help!