Application: nginx, php, mariadb - custom application.
oAuth is based on https://github.com/overtrue/socialite (server side flow):
mypage.com/auth/start/google (302) => https://accounts.google.com/o/oauth2/v2/auth?... (302) => mypage.com/auth/redirect/google?... (handle login etc)
Problem: intermittent issue after clicking the oauth login button (simple link) on iPhone SE and iPad, Chrome (latest). Everything works fine on desktop browsers, responsive mode and virtual devices.
Sometimes when I click the login button to go to mypage.com/auth/start/google the browser is stuck "loading". The browser is completely unresponsive at this point, but it is not in a redirect loop.
Interestingly when I check the background network activity with e.g. mitmproxy I can see that actually the authentication process has finished successfully and I see the requests/responses - but mobile chrome doesn't update. As if I would see a static version of my website. Even more confusingly I can even click on links that were visible on the stuck login page (where I clicked the login button) and I can see that the requests and responses arrive, but there are no changes in the page rendering. I have to close the browser and reopen the page (where I am sure enough logged in).
What I've tried:
My css is not 100% valid, I could spend a few hours fixing small issues. There is nothing in app, nginx or php logs - request happen properly in the background! I don't have a Mac.
It is quite hard to reproduce consistently and I could not find a pattern. I couldn't find any similar issues online and I am stuck. What should I try? Does it seem like a client (js, css) or server side (redirect) issue?