NullPointerException in handleOnGetSentenceSuggestionsMultiple (SpellCheckerSession) - android

I got the following exception reported several times in my ACRA reports. It seems to be coming only from devices running Android 4.4.2 but I have no idea where could be the problem.
Did anyone already meet this problem?
Thank you
java.lang.NullPointerException
at android.view.textservice.SpellCheckerSession.handleOnGetSentenceSuggestionsMultiple(SpellCheckerSession.java:222)
at android.view.textservice.SpellCheckerSession.access$100(SpellCheckerSession.java:86)
at android.view.textservice.SpellCheckerSession$1.handleMessage(SpellCheckerSession.java:116)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:149)
at android.app.ActivityThread.main(ActivityThread.java:5061)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:787)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:603)
at dalvik.system.NativeStart.main(Native Method)
UPDATE
There is this thread running: https://code.google.com/p/android/issues/detail?id=161400
Developers on the thread have the exact same problem, on devices running Android 4.4.2 only. It seems to be fixed on the other versions.

What work for me is
_editText.setInputType(InputType.TYPE_TEXT_FLAG_NO_SUGGESTIONS);
you can do this in xml file like
android:inputType="textNoSuggestions"
I thing by default this flag is true thats why it give this exception if give below 23 android version ,abouve 23 work fine
This is not the answer but until someone give answer to this question we can use above shortcut

Turn off suggestions like this:
android:inputType="textNoSuggestions|textVisiblePassword"
works better than just:
android:inputType="textNoSuggestions"

Related

firebaseUI Unique transitionNames are required for all sharedElements

I'm developing an android app using firebase auth and firebaseUI. My problem is that I can't create a new user via the "Sign in via email" flow. However, when logging in with an existing account everything works fine.
In detail this means the app crashes everytime I click the "Continue" button after entering the email address, with the following error in logcat:
E/UncaughtException: java.lang.IllegalArgumentException: Unique transitionNames are required for all sharedElements
at android.support.v4.app.BackStackRecord.addSharedElement(BackStackRecord.java:511)
at com.firebase.ui.auth.ui.email.RegisterEmailActivity.onNewUser(RegisterEmailActivity.java:127)
at com.firebase.ui.auth.ui.email.CheckEmailFragment$2.onSuccess(CheckEmailFragment.java:208)
at com.firebase.ui.auth.ui.email.CheckEmailFragment$2.onSuccess(CheckEmailFragment.java:204)
at com.google.android.gms.tasks.zzj.run(Unknown Source)
at android.os.Handler.handleCallback(Handler.java:725)
at android.os.Handler.dispatchMessage(Handler.java:92)
at android.os.Looper.loop(Looper.java:176)
at android.app.ActivityThread.main(ActivityThread.java:5365)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1102)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:869)
at dalvik.system.NativeStart.main(Native Method)
The problem occurs only since I upgraded
com.android.support:support-v4 from 26.1.0 to 27.0.1 and
com.google.firebase:firebase-auth from 11.4.2 to 11.6.0 .
However, I still use 'com.firebaseui:firebase-ui-auth:3.1.0' since I could not find a later version yet.
Could this be an incompatibility of the named libraries or do I miss something? My android version is 4.2.2.
Thank you in advance,
Dan
UPDATE
Update to 'com.firebaseui:firebase-ui-auth:3.1.2' didn't help. Still the same error which, by the way, does not occur on an api level 25 device.
I had hoped the update would solve the issue but as this doesn't seem to be the case I'm not really sure what to do right now. Any ideas how to troubleshoot this? Please help!
The issue was is solved in 3.1.3. See also this github issue.

E/AndroidRuntime: FATAL EXCEPTION: main java.lang.VerifyError

Guys I am getting the below error in RunTime, what is the root cause of this error?
java.lang.VerifyError: appPackageName at java.lang.Class.newInstanceImpl(Native Method)
at java.lang.Class.newInstance(Class.java:1130)
at android.app.ActivityThread.handleCreateService(ActivityThread.java:2698)
at android.app.ActivityThread.access$1900(ActivityThread.java:148)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1413)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:5457)
at java.lang.reflect.Method.invokeNative(Native Method)
You are probably using or accessing something which is simply supported in higher android SDK, as the error shows here java.lang.Class.newInstanceImpl(Native Method).
I happened to have the same kind of VerifyError while I was using String.isEmplty();. It seems you have same kind of problem as the message showing error in java.lang.Class
Thrown when the "verifier" detects that a class file, though well formed, contains some sort of internal inconsistency or security problem.
Here is official docs
Possible causes:
You might have imported something which is using different support v4/v7 library version.
You are targeting something from a higher SDK version. In that case, update your support repository and SDK build version.
Thanks everyone for your support and answers, may be your answers are right but in my case I used extra variables in one method while I was testing, so this exception appeared. Now I get rid of redundant things in my code and it start working. It may help others.

getting a NoClassDefFoundError on "PlusImageView"

Background
My app has a small PlusOne button in it (using Google-Play-Services rev. 21.0.2) , and recently I got the next crash report from one of the users
java.lang.NoClassDefFoundError: android.os.AsyncTask
at com.google.android.gms.plus.data.internal.PlusImageView.a(SourceFile:60)
at com.google.android.gms.plus.internal.bw.a(SourceFile:917)
at com.google.android.gms.common.internal.v.d(SourceFile:200)
at com.google.android.gms.common.internal.u.handleMessage(SourceFile:136)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:130)
at android.app.ActivityThread.main(ActivityThread.java:3770)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:507)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:670)
at dalvik.system.NativeStart.main(Native Method)
The problem
I've followed all of the instructions of the Play Services for a very long time (including the Proguard part), and never had this issue before.
The weird thing is that I've succeeded running the app on multiple devices without any issue, and there are quite a lot of users out there that use my app . Many also uninstall, but this is the first time I get this crash.
The question
I'm not a Proguard expert, but is it maybe possible that this is the reason for it?
What could be the reason for this issue?
How can I fix this issue?
I've tried to search for this problem and there isn't even a single website that I've found regarding it.

Android - flurry crash with exception

I recently got this crash report from what looks like a flurry library crash on my app:
java.lang.StackOverflowError
at com.flurry.android.FlurryAgent.a(SourceFile:87)
at com.flurry.android.d.run(SourceFile:1152)
at android.os.Handler.handleCallback(Handler.java:587)
at android.os.Handler.dispatchMessage(Handler.java:92)
at android.os.Looper.loop(Looper.java:130)
at android.os.HandlerThread.run(HandlerThread.java:60)
Has anyone seen this or is familiar with it? I don't even know what caused it as it does not say what file caused the problem.
Any thoughts on how to prevent this?
I would recommend you to update to SDK v3.0.5 which includes a fix to prevent crashing of bad phone ids in AndroidSDK 2.2.
(Full disclosure: I work in the Support team at Flurry)

java.lang.NullPointerException - AutoCompleteTextView - HoneyComb

I am getting a weird issue when using AutoCompleteTextView component on a device running on Honeycomb (Android 3.0) (using Motorola Xoom to test). I get a Nullpointer exception with the following stacktrace :
FATAL EXCEPTION: main
java.lang.NullPointerException at
android.widget.PopupWindow.getMaxAvailableHeight(PopupWindow.java:1152)
at
android.widget.ListPopupWindow.buildDropDown(ListPopupWindow.java:1054)
at
android.widget.ListPopupWindow.show(ListPopupWindow.java:516)
at
android.widget.AutoCompleteTextView.showDropDown(AutoCompleteTextView.java:1047)
at
android.widget.AutoCompleteTextView.updateDropDownForFilter(AutoCompleteTextView.java:931)
at
android.widget.AutoCompleteTextView.onFilterComplete(AutoCompleteTextView.java:914)
at
android.widget.Filter$ResultsHandler.handleMessage(Filter.java:285)
at
android.os.Handler.dispatchMessage(Handler.java:99)
at
android.os.Looper.loop(Looper.java:126)
at
android.app.ActivityThread.main(ActivityThread.java:3997)
at
java.lang.reflect.Method.invokeNative(Native
Method) at
java.lang.reflect.Method.invoke(Method.java:491)
at
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:841)
at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:599)
at
dalvik.system.NativeStart.main(Native
Method)
Note that I do not get this exception on any other versions of Android including Gingerbread. Its really hard to debug since I do not have the original source code of Honeycomb code base. I would appreciate if anyone can help me out.
Thanks,
Torri.
I had the exact exception. Everything works in 2.*, but in 3.x there all thrown this exception, and simply try catch didn't work.
Finally I found that, if I remove the below line from the view, then it worked for me:
android:dropDownAnchor="#+id/searchField"
I am not sure if this can help but I had a similarly weird problem with a button. It worked fine on all versions except 3.0
So I did this:
try{
mButton.setOnClickListener(...
//code...
}catch(NullPointerException e){
}
After this no more errors and guess what? The button works fine now on 3.0 !

Categories

Resources