Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(Crash) NullPointerException at in_app_browser.InAppBrowserActivity.close #1278

Closed
4 tasks done
appcapsergen opened this issue Aug 10, 2022 · 2 comments
Closed
4 tasks done
Labels
bug Something isn't working

Comments

@appcapsergen
Copy link

appcapsergen commented Aug 10, 2022

Environment

Technology Version
Flutter version 3.0.5
Plugin version 5.4.3+7
Android version 12/11
iOS version -
Xcode version 13.4.1

Description

Android Flutter app crash. Got this report from crashlytics in Google Play Console.

Stacktrace/Logcat

Exception java.lang.NullPointerException:
  at com.pichillilorenzo.flutter_inappwebview.in_app_browser.InAppBrowserActivity.close (InAppBrowserActivity.java:299)
  at com.pichillilorenzo.flutter_inappwebview.in_app_browser.InAppBrowserActivity.onKeyDown (InAppBrowserActivity.java:287)
  at android.view.KeyEvent.dispatch (KeyEvent.java:3624)
  at android.app.Activity.dispatchKeyEvent (Activity.java:4147)
  at androidx.core.app.ComponentActivity.superDispatchKeyEvent (ComponentActivity.java:124)
  at androidx.core.view.KeyEventDispatcher.dispatchKeyEvent (KeyEventDispatcher.java:86)
  at androidx.core.app.ComponentActivity.dispatchKeyEvent (ComponentActivity.java:142)
  at androidx.appcompat.app.AppCompatActivity.dispatchKeyEvent (AppCompatActivity.java:599)
  at androidx.appcompat.view.WindowCallbackWrapper.dispatchKeyEvent (WindowCallbackWrapper.java:59)
  at androidx.appcompat.app.AppCompatDelegateImpl$AppCompatWindowCallback.dispatchKeyEvent (AppCompatDelegateImpl.java:3090)
  at com.android.internal.policy.DecorView.dispatchKeyEvent (DecorView.java:758)
  at android.view.ViewRootImpl$ViewPostImeInputStage.processKeyEvent (ViewRootImpl.java:7365)
  at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess (ViewRootImpl.java:7191)
  at android.view.ViewRootImpl$InputStage.deliver (ViewRootImpl.java:6595)
  at android.view.ViewRootImpl$InputStage.onDeliverToNext (ViewRootImpl.java:6652)
  at android.view.ViewRootImpl$InputStage.forward (ViewRootImpl.java:6618)
  at android.view.ViewRootImpl$AsyncInputStage.forward (ViewRootImpl.java:6786)
  at android.view.ViewRootImpl$InputStage.apply (ViewRootImpl.java:6626)
  at android.view.ViewRootImpl$AsyncInputStage.apply (ViewRootImpl.java:6843)
  at android.view.ViewRootImpl$InputStage.deliver (ViewRootImpl.java:6599)
  at android.view.ViewRootImpl$InputStage.onDeliverToNext (ViewRootImpl.java:6652)
  at android.view.ViewRootImpl$InputStage.forward (ViewRootImpl.java:6618)
  at android.view.ViewRootImpl$InputStage.apply (ViewRootImpl.java:6626)
  at android.view.ViewRootImpl$InputStage.deliver (ViewRootImpl.java:6599)
  at android.view.ViewRootImpl$InputStage.onDeliverToNext (ViewRootImpl.java:6652)
  at android.view.ViewRootImpl$InputStage.forward (ViewRootImpl.java:6618)
  at android.view.ViewRootImpl$AsyncInputStage.forward (ViewRootImpl.java:6819)
  at android.view.ViewRootImpl$ImeInputStage.onFinishedInputEvent (ViewRootImpl.java:7007)
  at android.view.inputmethod.InputMethodManager$PendingEvent.run (InputMethodManager.java:3624)
  at android.view.inputmethod.InputMethodManager.invokeFinishedInputEventCallback (InputMethodManager.java:3163)
  at android.view.inputmethod.InputMethodManager.finishedInputEvent (InputMethodManager.java:3154)
  at android.view.inputmethod.InputMethodManager$ImeInputEventSender.onInputEventFinished (InputMethodManager.java:3601)
  at android.view.InputEventSender.dispatchInputEventFinished (InputEventSender.java:143)
  at android.os.MessageQueue.nativePollOnce (MessageQueue.java)
  at android.os.MessageQueue.next (MessageQueue.java:335)
  at android.os.Looper.loop (Looper.java:206)
  at android.app.ActivityThread.main (ActivityThread.java:8653)
  at java.lang.reflect.Method.invoke (Method.java)
  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:602)
  at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1130)```
@appcapsergen appcapsergen added the bug Something isn't working label Aug 10, 2022
@github-actions
Copy link

👋 @appcapsergen

NOTE: This comment is auto-generated.

Are you sure you have already searched for the same problem?

Some people open new issues but they didn't search for something similar or for the same issue. Please, search for it using the GitHub issue search box or on the official inappwebview.dev website, or, also, using Google, StackOverflow, etc. before posting a new one. You may already find an answer to your problem!

If this is really a new issue, then thank you for raising it. I will investigate it and get back to you as soon as possible. Please, make sure you have given me as much context as possible! Also, if you didn't already, post a code example that can replicate this issue.

In the meantime, you can already search for some possible solutions online! Because this plugin uses native WebView, you can search online for the same issue adding android WebView [MY ERROR HERE] or ios WKWebView [MY ERROR HERE] keywords.

Following these steps can save you, me, and other people a lot of time, thanks!

@Manuito83
Copy link
Contributor

I'm also experiencing this, same version.

pichillilorenzo added a commit that referenced this issue Oct 19, 2022
…rowser option, Fixed iOS InAppBrowserOptions.hideProgressBar when getting options, Fixed missing implementation InAppBrowser.isHidden method on Android and iOS, Removed unnamed constructors for all Singleton classes to avoid incorrect usage
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants