-
-
Notifications
You must be signed in to change notification settings - Fork 270
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
Attempt to invoke virtual method 'float android.view.MotionEvent.getX()' on a null object reference #21
Comments
@PedroBarbosaPT Can you provide device details and os details. |
@nisrulz Android Emulator - Nexus 5 API 23 |
@PedroBarbosaPT I have yet to reproduce this issue. Just so you know this issue isn't abandoned. 😅 Will update you when I am able to replicate and provide a possible solution. |
@nisrulz No problem. The error never happened again, so ... 😅 |
Hmm.. good to know that. I am closing this issue until it resurfaces again. |
I have the same problem. From my stats on Fabric it looks like it occurs only on Samsung (94%) and Huawei(6%) devices. I wasn't able to replicate the problem myself. It's the most occurring bug in my app right now, Is there any solution to this? |
Hi @Patra89 |
Stats from Fabric: Samsung devices: Galaxy S4, SM-G950U, Galaxy S7 Edge, SM-G950F, SM-A320FL, Galaxy S7, Galaxy S6, SM-N950F, SM-N950F, Galaxy Note4, Galaxy S6 Edge, Galaxy A7(2016), Galaxy S6 Edge+ Huawei devices: P9, P8 Lite Operating systems: Device statistics: Raport on the same problem from my Google Play Console: Devices: Operating systems: Android 7.0 | 58,8% |
Have the same bug here on my test Device. Stack trace: 2020-10-14 15:07:32.521 18965-18965/de.sipgate.app.satellite V/ProfileListEntry: [2020-10-14 15:07:32:517] [18965] [VERBO] [ProfileListEntry]: Event was ACTION_MOVE Device is a HUAWEI Mate 9 - Model MHA-L29 I created a view with a on touch listener to animate the swipe and used the swipe detection of sensey. It appears during a delete animation when the user touches or lift his finger on the view animations. So it seems there is a race condition, the view is allready destroyed but there a still running some event calculation in background. Heres a video when i try to recreate the bug: |
My temporary fix is a big try catch around sensey's setup method. It works, but is not a reliable solution. override fun dispatchTouchEvent(event: MotionEvent?): Boolean {
// Setup onTouchEvent for detecting type of touch gesture
try {
Sensey.getInstance().setupDispatchTouchEvent(event)
} catch (e: Exception){
Timber.e(e, "Sensey got an exception. try to ignore it")
}
return super.dispatchTouchEvent(event)
} |
I don't know if it's related but I've gotten a couple of somewhat similar crashes. Please let me know if you'd prefer that UI open a new issue for it. See below:
Device was a Samsung Galaxy J7 Neo running Android 9 (SDK 28). Any idea how I could investigate the source of this error? Thanks! |
It works, but sometimes it shows this error:
(Double Tap)
I don't know how to replicate tho :/
The text was updated successfully, but these errors were encountered: