Android app crashes after clicking on CardField input sometimes 🐞
See original GitHub issueDescribe the bug Android app crashes after clicking on CardField input sometimes. It happens about one in ten times when I click on CardNumber. input.
To Reproduce Steps to reproduce the behavior:
- Go to CardField component;
- Click on CardNumber input;
- App closes without errors on real device. On emulator I see an error: “System ui isn’t responding”
Expected behavior CardFiled input works correctly.
Smartphone (please complete the following information):
- Device: any Android device or Emulator;
- OS: Android;
- Version: on my real device I have Android 11 RKQ1.201004.002
Additional context package-json:
{
"name": "csnative",
"version": "0.0.1",
"private": true,
"scripts": {
"android": "react-native run-android",
"ios": "react-native run-ios",
"start": "react-native start",
"test": "jest",
"lint": "eslint .",
"test:watch": "npm run test -- --watch",
"esdoc": "./node_modules/.bin/esdoc"
},
"dependencies": {
"@alessiocancian/react-native-actionsheet": "^3.1.1",
"@invertase/react-native-apple-authentication": "^2.1.5",
"@ptomasroos/react-native-multi-slider": "^2.2.2",
"@react-native-community/async-storage": "^1.12.0",
"@react-native-firebase/app": "^12.7.1",
"@react-native-firebase/messaging": "^12.7.1",
"@stripe/stripe-react-native": "^0.11.0",
"@types/lodash": "^4.14.168",
"@types/react-native-snap-carousel": "^3.8.5",
"@types/react-redux": "^7.1.18",
"axios": "^0.19.2",
"base-64": "^0.1.0",
"date-fns": "^2.15.0",
"i18next": "^19.6.3",
"lodash": "^4.17.20",
"react": "16.13.1",
"react-i18next": "^11.7.0",
"react-native": "^0.64.0",
"react-native-actionsheet": "^2.4.2",
"react-native-date-picker": "^3.4.3",
"react-native-device-info": "^8.7.0",
"react-native-dialog": "^9.2.0",
"react-native-extended-stylesheet": "^0.12.0",
"react-native-image-picker": "^4.7.3",
"react-native-keyboard-aware-scroll-view": "^0.9.2",
"react-native-navigation": "^6.11.0",
"react-native-notifications": "^4.1.2",
"react-native-raw-bottom-sheet": "^2.2.0",
"react-native-render-html": "^6.3.4",
"react-native-restart": "^0.0.24",
"react-native-snap-carousel": "^3.9.1",
"react-native-swipeout": "^2.3.6",
"react-native-vector-icons": "^9.1.0",
"react-native-webview": "^11.18.1",
"react-redux": "^7.2.1",
"redux": "^4.0.5",
"redux-logger": "^3.0.6",
"redux-thunk": "^2.3.0",
"tcomb-form-native": "^0.6.20"
},
"devDependencies": {
"@babel/core": "^7.8.4",
"@babel/runtime": "^7.8.4",
"@react-native-community/eslint-config": "^1.1.0",
"@types/jest": "^26.0.20",
"@types/react": "^17.0.2",
"@types/react-native": "^0.63.52",
"@types/react-redux": "^7.1.16",
"@types/react-test-renderer": "^17.0.1",
"babel-jest": "^25.1.0",
"esdoc": "^1.1.0",
"esdoc-ecmascript-proposal-plugin": "^1.0.0",
"esdoc-jsx-plugin": "^1.0.0",
"esdoc-react-plugin": "^1.0.1",
"esdoc-standard-plugin": "^1.0.0",
"eslint": "^7.7.0",
"jest": "^26.4.0",
"metro-react-native-babel-preset": "^0.59.0",
"react-test-renderer": "16.13.1",
"typescript": "^4.1.5"
},
"jest": {
"preset": "react-native"
}
}
Android Studio Bumblebee | 2021.1.1 Patch 3
Project structure:
Android Gradle Plugin Version = "4.0.2"
Gradle Version = "6.7.1"
build.gradle:
buildToolsVersion = "31.0.0"
minSdkVersion = 21
compileSdkVersion = 31
targetSdkVersion = 31
kotlinVersion = "1.6.21"
gradle.properties:
android.useAndroidX=true
android.enableJetifier=true
FLIPPER_VERSION=0.54.0
org.gradle.daemon=true
org.gradle.configureondemand=true
org.gradle.jvmargs=-Xmx4g -XX:MaxPermSize=2048m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
Environment:
System:
OS: macOS 12.3
CPU: (8) x64 Intel(R) Core(TM) i5-1038NG7 CPU @ 2.00GHz
Memory: 68.02 MB / 16.00 GB
Shell: 5.8 - /bin/zsh
Binaries:
Node: 16.14.2 - /usr/local/bin/node
Yarn: 1.22.18 - /usr/local/bin/yarn
npm: 8.5.0 - /usr/local/bin/npm
Watchman: 2022.03.21.00 - /usr/local/bin/watchman
Managers:
CocoaPods: 1.11.3 - /usr/local/bin/pod
SDKs:
iOS SDK:
Platforms: DriverKit 21.4, iOS 15.4, macOS 12.3, tvOS 15.4, watchOS 8.5
Android SDK:
API Levels: 29, 30, 31, 32
Build Tools: 28.0.3, 29.0.2, 30.0.0, 30.0.2, 31.0.0, 32.0.0, 32.1.0, 33.0.0, 33.0.0, 33.0.0
System Images: android-30 | Intel x86 Atom_64, android-30 | Google APIs Intel x86 Atom, android-30 | Google Play Intel x86 Atom, android-31 | Google Play Intel x86 Atom_64, android-32 | Google APIs ARM 64 v8a, android-32 | Google APIs Intel x86 Atom_64, android-32 | Google Play ARM 64 v8a, android-32 | Google Play Intel x86 Atom_64
Android NDK: Not Found
IDEs:
Android Studio: 2021.1 AI-211.7628.21.2111.8309675
Xcode: 13.3.1/13E500a - /usr/bin/xcodebuild
Languages:
Java: 11.0.11 - /usr/bin/javac
npmPackages:
@react-native-community/cli: Not Found
react: 16.13.1 => 16.13.1
react-native: ^0.64.0 => 0.64.0
react-native-macos: Not Found
npmGlobalPackages:
*react-native*: Not Found
Also I have an error in Android Studio problems section:
update failed for ActionGroup: Previous Occurrence (Navigate to the previous occurrence)[Previous Occurrence]
java.util.NoSuchElementException: node has no children
at java.desktop/javax.swing.tree.DefaultMutableTreeNode.getLastChild(DefaultMutableTreeNode.java:900)
at java.desktop/javax.swing.tree.DefaultMutableTreeNode.getLastLeaf(DefaultMutableTreeNode.java:1132)
at java.desktop/javax.swing.tree.DefaultMutableTreeNode.getPreviousNode(DefaultMutableTreeNode.java:751)
at com.intellij.ide.OccurenceNavigatorSupport.findNextNodeAfter(OccurenceNavigatorSupport.java:132)
at com.intellij.ide.OccurenceNavigatorSupport.findNode(OccurenceNavigatorSupport.java:117)
at com.intellij.ide.OccurenceNavigatorSupport.hasPreviousOccurence(OccurenceNavigatorSupport.java:96)
at com.intellij.build.BuildTreeConsoleView.hasPreviousOccurence(BuildTreeConsoleView.java:535)
at com.intellij.ide.actions.PreviousOccurenceAction.hasOccurenceToGo(PreviousOccurenceAction.java:20)
at com.intellij.ide.actions.OccurenceNavigatorActionBase.update(OccurenceNavigatorActionBase.java:74)
at com.intellij.ide.actions.PreviousOccurenceAction.update(PreviousOccurenceAction.java:7)
at com.intellij.openapi.actionSystem.ex.ActionUtil.lambda$performDumbAwareUpdate$1(ActionUtil.java:170)
at com.intellij.util.SlowOperations.lambda$allowSlowOperations$0(SlowOperations.java:77)
at com.intellij.util.SlowOperations.allowSlowOperations(SlowOperations.java:64)
at com.intellij.util.SlowOperations.allowSlowOperations(SlowOperations.java:76)
at com.intellij.openapi.actionSystem.ex.ActionUtil.performDumbAwareUpdate(ActionUtil.java:176)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.doUpdate(ActionUpdater.java:510)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.lambda$new$1(ActionUpdater.java:104)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.callAction(ActionUpdater.java:147)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.lambda$new$2(ActionUpdater.java:105)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.update(ActionUpdater.java:492)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.expandGroupChild(ActionUpdater.java:333)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.lambda$doExpandActionGroup$20(ActionUpdater.java:308)
at com.intellij.util.TimeoutUtil.compute(TimeoutUtil.java:134)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.lambda$doExpandActionGroup$22(ActionUpdater.java:307)
at com.intellij.util.containers.ContainerUtil.concat(ContainerUtil.java:1511)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.doExpandActionGroup(ActionUpdater.java:307)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.expandActionGroup(ActionUpdater.java:199)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.expandActionGroup(ActionUpdater.java:173)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.lambda$expandActionGroupWithTimeout$11(ActionUpdater.java:215)
at com.intellij.openapi.progress.ProgressManager.lambda$runProcess$0(ProgressManager.java:57)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$2(CoreProgressManager.java:178)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:688)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:634)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:64)
at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:165)
at com.intellij.openapi.progress.ProgressManager.runProcess(ProgressManager.java:57)
at com.intellij.openapi.progress.util.ProgressIndicatorUtils.withTimeout(ProgressIndicatorUtils.java:310)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.expandActionGroupWithTimeout(ActionUpdater.java:215)
at com.intellij.openapi.actionSystem.impl.ActionUpdater.expandActionGroupWithTimeout(ActionUpdater.java:207)
at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroup(Utils.java:105)
at com.intellij.openapi.actionSystem.impl.Utils.fillMenu(Utils.java:117)
at com.intellij.openapi.actionSystem.impl.ActionPopupMenuImpl$MyMenu.lambda$show$1(ActionPopupMenuImpl.java:130)
at com.intellij.util.TimeoutUtil.run(TimeoutUtil.java:104)
at com.intellij.openapi.actionSystem.impl.ActionPopupMenuImpl$MyMenu.show(ActionPopupMenuImpl.java:129)
at com.intellij.build.BuildTreeConsoleView$1.invokePopup(BuildTreeConsoleView.java:215)
at com.intellij.ui.PopupHandler.mousePressed(PopupHandler.java:36)
at java.desktop/java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:288)
at java.desktop/java.awt.Component.processMouseEvent(Component.java:6649)
at java.desktop/javax.swing.JComponent.processMouseEvent(JComponent.java:3345)
at com.intellij.ui.treeStructure.Tree.processMouseEvent(Tree.java:392)
at java.desktop/java.awt.Component.processEvent(Component.java:6417)
at java.desktop/java.awt.Container.processEvent(Container.java:2263)
at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:5027)
at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2321)
at java.desktop/java.awt.Component.dispatchEvent(Component.java:4859)
at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4918)
at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Container.java:4544)
at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Container.java:4488)
at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2307)
at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2784)
at java.desktop/java.awt.Component.dispatchEvent(Component.java:4859)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:778)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:727)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:95)
at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:751)
at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:749)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:748)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:969)
at com.intellij.ide.IdeEventQueue.dispatchMouseEvent(IdeEventQueue.java:906)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:836)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$8(IdeEventQueue.java:449)
at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:808)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$9(IdeEventQueue.java:448)
at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:787)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:502)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
Issue Analytics
- State:
- Created a year ago
- Comments:6
Top Results From Across the Web
Why do my apps keep crashing on Android, How to fix it
Another way to fix apps crashing on your phone is to simply restart the device. Restarting the device will kill and then restart...
Read more >Crashes - Android Developers
An Android app crashes whenever there's an unexpected exit caused by an unhandled exception or signal. An app that is written using Java...
Read more >Android app crashes when nothing is entered and button is ...
im just trying to make a message that if field is empty and button is pressed for it not to crash and say...
Read more >Why Do My Apps Keep Crashing on Android? - Avast
Do your Android apps keep crashing? Discover why and learn how to prevent Android apps crashing and freezing by following these methods.
Read more >How to Fix Crashing Apps on an iPhone or Android?
The solution for app keep crashes on your smartphone... I am a developer of iPhone/Android and my app keeps crashing on users phones…...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@MuhammadFaiz54 I will update the react native version to “react-native”: “^0.64.3” than my code working fine
@shubham-snake Thanks its works for me as well.