- Saved searches
- Use saved searches to filter your results more quickly
- java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.lang.Iterable.iterator()’ on a null object reference #2786
- java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.lang.Iterable.iterator()’ on a null object reference #2786
- Comments
- Saved searches
- Use saved searches to filter your results more quickly
- java.lang.NullPointerException: Attempt to invoke virtual method ‘java.util.Iterator java.util.ArrayList.iterator()’ on a null object reference [ANDROID] #384
- java.lang.NullPointerException: Attempt to invoke virtual method ‘java.util.Iterator java.util.ArrayList.iterator()’ on a null object reference [ANDROID] #384
- Comments
- Saved searches
- Use saved searches to filter your results more quickly
- java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference #1020
- java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference #1020
- Comments
- Step 1: Describe your environment
- Step 2: Describe the problem:
- Steps to reproduce:
- Observed Results:
- Relevant Code:
- Saved searches
- Use saved searches to filter your results more quickly
- java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference #51
- java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference #51
- Comments
Saved searches
Use saved searches to filter your results more quickly
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.
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
java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.lang.Iterable.iterator()’ on a null object reference #2786
java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.lang.Iterable.iterator()’ on a null object reference #2786
Comments
"react": "16.8.6", "react-native": "0.58.5", react-native-maps: 0.23.0
It is happening in Android native side. Application crashed in a class named AirMapPolyline.java
at com.google.android.gms.maps.model.PolylineOptions.addAll(Unknown Source)
It happenned when I want to draw a polyline. It works in Ios, however it does not work in android
Is there any solution ?
The text was updated successfully, but these errors were encountered:
For anyone that comes across this issue it is not a bug.
The error is thrown whenever a Polyline or Polygon is given passed undefined to the coordinates prop.
Use something like .filter() to remove any undefined items before trying to render them and the error will be eliminated.
Someone just emailed me asking for further explanation, this was my response:
Polyline or Polygon elements expect an array of LatLng objects, like this:
Now if instead of a LatLng object you have an element which is undefined, like this:
This will create an error.
To eliminate the error, you could do something like this:
// identity when used as a predicate coerces undefined or null values to false
const identity = item => item
const filteredData = data.filter(identity)
No more null object reference 🙂
Saved searches
Use saved searches to filter your results more quickly
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.
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
java.lang.NullPointerException: Attempt to invoke virtual method ‘java.util.Iterator java.util.ArrayList.iterator()’ on a null object reference [ANDROID] #384
java.lang.NullPointerException: Attempt to invoke virtual method ‘java.util.Iterator java.util.ArrayList.iterator()’ on a null object reference [ANDROID] #384
Comments
When I use it on Android the app crashes and I’ve got this error from logcat
Process: com.******, PID: 18659 java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.Iterator java.util.ArrayList.iterator()' on a null object reference at com.wenkesj.voice.VoiceModule.onResults(VoiceModule.java:348) at android.speech.SpeechRecognizer$InternalListener$1.handleMessage(SpeechRecognizer.java:459) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:223) at android.app.ActivityThread.main(ActivityThread.java:7664) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)```
The text was updated successfully, but these errors were encountered:
Saved searches
Use saved searches to filter your results more quickly
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.
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
java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference #1020
java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference #1020
Comments
Step 1: Describe your environment
- Android device: OnePlus 7 Pro (GM1913)
- Android OS version: 10
- Google Play Services version: 19.6.29
- Firebase/Play Services SDK version: 19.2.0
Step 2: Describe the problem:
Trying to save Object to Firebase DB
java.lang.RuntimeException: java.lang.reflect.InvocationTargetException java.lang.NullPointerException: Attempt to invoke interface method 'java.util.Iterator java.util.List.iterator()' on a null object reference 0 = "java.lang.reflect.Method.invoke(Native Method)" 1 = "com.google.firebase.database.core.utilities.encoding.CustomClassMapper$BeanMapper.serialize(com.google.firebase:firebase-database@@19.2.0:657)" 2 = "com.google.firebase.database.core.utilities.encoding.CustomClassMapper.serialize(com.google.firebase:firebase-database@@19.2.0:167)" 3 = "com.google.firebase.database.core.utilities.encoding.CustomClassMapper.convertToPlainJavaTypes(com.google.firebase:firebase-database@@19.2.0:60)" 4 = "com.google.firebase.database.DatabaseReference.setValueInternal(com.google.firebase:firebase-database@@19.2.0:282)" 5 = "com.google.firebase.database.DatabaseReference.setValue(com.google.firebase:firebase-database@@19.2.0:159)"
Steps to reproduce:
Reproduced on Emulator with Android 10 also
Observed Results:
Relevant Code:
DatabaseReference db = FirebaseDatabase.getInstance().getReference(); db.child("profile").child("name@last").setValue(userProfileObj)
The text was updated successfully, but these errors were encountered:
Saved searches
Use saved searches to filter your results more quickly
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.
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
java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference #51
java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference #51
Comments
java.lang.RuntimeException: Unable to create application com.stub.StubApp: java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5677)
at android.app.ActivityThread.-wrap2(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1637)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:156)
at android.app.ActivityThread.main(ActivityThread.java:6523)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:942)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:832)
Caused by: java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference
at xiaofei.library.hermeseventbus.HermesEventBus.b(SourceFile)
at xiaofei.library.hermeseventbus.HermesEventBus.a(SourceFile)
at xiaofei.library.hermeseventbus.HermesEventBus.init(SourceFile)
at com.****.Application.onCreate(SourceFile)
at com.stub.StubApp.onCreate(SourceFile:111)
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1028)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5658)
. 8 more
java.lang.NullPointerException: Attempt to invoke interface method ‘java.util.Iterator java.util.List.iterator()’ on a null object reference
at xiaofei.library.hermeseventbus.HermesEventBus.b(SourceFile)
at xiaofei.library.hermeseventbus.HermesEventBus.a(SourceFile)
at xiaofei.library.hermeseventbus.HermesEventBus.init(SourceFile)
at com..****Application.onCreate(SourceFile)
at com.stub.StubApp.onCreate(SourceFile:111)
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1028)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5658)
at android.app.ActivityThread.-wrap2(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1637)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:156)
at android.app.ActivityThread.main(ActivityThread.java:6523)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:942)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:832)
The text was updated successfully, but these errors were encountered: