question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Webview Not Responding - Bug in iOS 12 and other versions

See original GitHub issue

Bug Description

Webview becomes unresponsive suddenly (buttons, links and scrolling won’t work). Apparently it’s random but i noticed that it occurs after some ajax call.

The bug is very hard to reproduce due to its intermittency. I had a meeting with the team in order to reproduce it in a controlled environment and I noticed that when the freezing occurs, it generates no exception and there are no errors in the Xcode log.

Apparently the Webview freezes but changing the orientation works (the scrolling and buttons still unresponsive but we can see the orientation changing)

I noticed that the freezing occurs after some ajax request.

My guess for this bug is:

Before calling the ajax process, I call the dialog preloader just like the code below:

app.dialog.preloader('Loading...');

After the ajax call is processed, I close the preloader with the following code:

app.dialog.close();

The dialog box disappears but the scrolling, buttons and controls still unresponsive.

So I guess the bug is related to the dialog closing process. The box disappears but the page stills unresponsive just like when the preloader box is active.

When the Webview freezes, if the user leaves the app and open some app push notification that will redirects it to another page, the app performs the redirection correctly and it becomes responsive again. So we know that the app did not freeze. It’s only the Webview that becames unresponsive.

Here’s a video recorded by a team member demonstrating the issue:

https://youtu.be/eMo2mLAeO18

To Reproduce

Due to its intermittency it is very hard to reproduce the error and there is no specific way to reproduce it.

Expected behavior

No webview freezing

Actual Behavior

Webview becomes unresponsive suddenly

Video

You can see the video demo here: https://youtu.be/eMo2mLAeO18

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
nolimits4webcommented, Jul 22, 2019

For me it seems like app doesn’t freeze but there is a transparent overlay that is still there that blocking all touch gestures. I can recommend you the following, attach device with your dev app installed from XCode, run the app, open Safari browser on Mac and inspect/debug device’s webview to see what happens there

0reactions
davidtoledocommented, Aug 8, 2019
  1. Баг с заморозкой бывает ну очень редко
  2. В v1 была проблема при открытии Photo Browser с определенным типом
  3. Используйте wkwebview, на многих устройствах проверено - заморозки нет

I did as @shastox has suggested. I’ve updated the app to use wkwebview and the problem is now solved. Thank you very much Sergey!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Safari, WKWebview Crash in iOS 15 Beta2 - Apple Developer
It was not a problem in iOS 14, but in iOS 15 beta2, it is forcibly terminated shortly after entering the lobby. Safari...
Read more >
Wkwebview not working in ios 12 and application gets crashed
I am working on wkwebview and testing my app in ios 12 but it's not working. ... But not working on IOS below...
Read more >
Here's how to fix those mysterious Android WebView crashes
Tap the three-dot menu at the top right of this screen, then select "Uninstall updates." This won't uninstall Android System WebView completely— ...
Read more >
Android System WebView - Apps on Google Play
Android WebView is a pre-installed system component from Google that allows Android apps to display web content. Updated on. Dec 13, 2022.
Read more >
FIX Android System WebView issue! - YouTube
Google #Android #WebViewGoogle confirms an issue with WebView is crashing many Android apps. Check the video for a quick fix if you are ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found