react-native-picker / picker

Picker is a cross-platform UI component for selecting an item from a list of options.
MIT License
1.54k stars 292 forks source link

[Android] Picker is switching without user activity, making the app crash. #150

Open enrickdl opened 4 years ago

enrickdl commented 4 years ago

Bug Report

Summary

Picker is switching when the component loads and after a while, it makes the application crash. This is only happening is a few Android Devices (Not happening on AVD for I could test it out).

Environment info

"@react-native-community/picker": "^1.6.6",
"react-native": "0.63.0",

Behavior

Evidence_country

enrickdl commented 4 years ago

No one?

enrickdl commented 4 years ago

Attaching a log from Sentry:

com.facebook.react.bridge.ReadableNativeArray in getMap at line 112
com.facebook.react.bridge.ReadableNativeArray in getMap at line 22
com.reactnativecommunity.picker.ReactPickerManager$ReactPickerAdapter in getItem at line 117
com.reactnativecommunity.picker.ReactPickerManager$ReactPickerAdapter in getView at line 136
com.reactnativecommunity.picker.ReactPickerManager$ReactPickerAdapter in getView at line 127
android.widget.Spinner in makeView at line 763
android.widget.Spinner in layout at line 710
android.widget.AbsSpinner in setSelectionInt at line 306
android.widget.AbsSpinner in setSelection at line 283
com.reactnativecommunity.picker.ReactPicker in setSelectionWithSuppressEvent at line 138
com.reactnativecommunity.picker.ReactPicker in updateStagedSelection at line 124
com.reactnativecommunity.picker.ReactPickerManager in onAfterUpdateTransaction at line 77
com.reactnativecommunity.picker.ReactPickerManager in onAfterUpdateTransaction at line 35
com.facebook.react.uimanager.ViewManager in updateProperties at line 51
com.facebook.react.uimanager.NativeViewHierarchyManager in updateProperties at line 137
com.facebook.react.uimanager.UIViewOperationQueue$UpdatePropertiesOperation in execute at line 94
com.facebook.react.uimanager.UIViewOperationQueue$1 in run at line 917
com.facebook.react.uimanager.UIViewOperationQueue in flushPendingBatches at line 1028
com.facebook.react.uimanager.UIViewOperationQueue in access$2600 at line 48
com.facebook.react.uimanager.UIViewOperationQueue$DispatchUIFrameCallback in doFrameGuarded at line 1088
com.facebook.react.uimanager.GuardedFrameCallback in doFrame at line 29
com.facebook.react.modules.core.ReactChoreographer$ReactChoreographerDispatcher in doFrame at line 175
com.facebook.react.modules.core.ChoreographerCompat$FrameCallback$1 in doFrame at line 85
android.view.Choreographer$CallbackRecord in run at line 984
android.view.Choreographer in doCallbacks at line 764
android.view.Choreographer in doFrame at line 696
android.view.Choreographer$FrameDisplayEventReceiver in run at line 965
android.os.Handler in handleCallback at line 873
android.os.Handler in dispatchMessage at line 99
android.os.Looper in loop at line 214
android.app.ActivityThread in main at line 7073
java.lang.reflect.Method in invoke
com.android.internal.os.RuntimeInit$MethodAndArgsCaller in run at line 494
com.android.internal.os.ZygoteInit in main at line 965
hkar19 commented 3 years ago

out of curiosity, on what android API level are you testing the app on?

and can you share some code snippet?