Skip to content
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

[BUG] crash on android #131

Open
zhigang1992 opened this issue Aug 31, 2021 · 4 comments
Open

[BUG] crash on android #131

zhigang1992 opened this issue Aug 31, 2021 · 4 comments
Labels
bug Something isn't working

Comments

@zhigang1992
Copy link

Bug

Crashes tracked from Google Play Store

Crashlog

java.lang.NullPointerException: 
  at android.view.View.requestLayout (View.java:25588)
  at android.widget.ImageView.setImageDrawable (ImageView.java:605)
  at androidx.appcompat.widget.AppCompatImageView.setImageDrawable (AppCompatImageView.java:104)
  at android.widget.ImageView.setImageBitmap (ImageView.java:769)
  at androidx.appcompat.widget.AppCompatImageView.setImageBitmap (AppCompatImageView.java:112)
  at com.mrousavy.blurhash.BlurhashImageView.renderBlurhash (BlurhashImageView.kt:76)
  at com.mrousavy.blurhash.BlurhashImageView.access$renderBlurhash (BlurhashImageView.kt:39)
  at com.mrousavy.blurhash.BlurhashImageView$updateBlurhash$1.invokeSuspend (BlurhashImageView.kt:86)
  at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith (ContinuationImpl.kt:33)
  at kotlinx.coroutines.DispatchedTask.run (DispatchedTask.kt:106)
  at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely (CoroutineScheduler.kt:571)
  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask (CoroutineScheduler.kt:750)
  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker (CoroutineScheduler.kt:678)
  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run (CoroutineScheduler.kt:665)

image

java.lang.NullPointerException: 
  at android.view.View.requestLayout (View.java:27055)
  at android.widget.ImageView.setImageDrawable (ImageView.java:600)
  at androidx.appcompat.widget.AppCompatImageView.setImageDrawable (AppCompatImageView.java:104)
  at android.widget.ImageView.setImageBitmap (ImageView.java:764)
  at androidx.appcompat.widget.AppCompatImageView.setImageBitmap (AppCompatImageView.java:112)
  at com.mrousavy.blurhash.BlurhashImageView.renderBlurhash (BlurhashImageView.kt:76)
  at com.mrousavy.blurhash.BlurhashImageView.access$renderBlurhash (BlurhashImageView.kt:39)
  at com.mrousavy.blurhash.BlurhashImageView$updateBlurhash$1.invokeSuspend (BlurhashImageView.kt:86)
  at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith (ContinuationImpl.kt:33)
  at kotlinx.coroutines.DispatchedTask.run (DispatchedTask.kt:106)
  at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely (CoroutineScheduler.kt:571)
  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask (CoroutineScheduler.kt:750)
  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker (CoroutineScheduler.kt:678)
  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run (CoroutineScheduler.kt:665)

image

Environment

System:
    OS: macOS 12.0
    CPU: (20) x64 Intel(R) Core(TM) i9-10900K CPU @ 3.70GHz
    Memory: 7.45 GB / 64.00 GB
    Shell: 5.8 - /bin/zsh
  Binaries:
    Node: 16.8.0 - /var/folders/v4/8jyh3pp92x58b6gkspmqv7z00000gn/T/yarn--1630417502647-0.8163490576417483/node
    Yarn: 1.22.10 - /var/folders/v4/8jyh3pp92x58b6gkspmqv7z00000gn/T/yarn--1630417502647-0.8163490576417483/yarn
    npm: 7.21.0 - /usr/local/bin/npm
    Watchman: 2021.08.23.00 - /usr/local/bin/watchman
  Managers:
    CocoaPods: 1.10.2 - /usr/local/lib/ruby/gems/3.0.0/bin/pod
  SDKs:
    iOS SDK:
      Platforms: iOS 14.5, DriverKit 20.4, macOS 11.3, tvOS 14.5, watchOS 7.4
    Android SDK: Not Found
  IDEs:
    Android Studio: 2020.3 AI-203.7717.56.2031.7621141
    Xcode: 12.5.1/12E507 - /usr/bin/xcodebuild
  Languages:
    Java: 15.0.2 - /usr/bin/javac
  npmPackages:
    @react-native-community/cli: Not Found
    react: 17.0.2 => 17.0.2
    react-native: 0.64.1 => 0.64.1
    react-native-macos: Not Found
  npmGlobalPackages:
    *react-native*: Not Found
✨  Done in 3.75s.
"react": 17,
"react-native": 0.64,
"react-native-blurhash": 1.1.3
@zhigang1992 zhigang1992 added the bug Something isn't working label Aug 31, 2021
@mrousavy
Copy link
Owner

mrousavy commented Sep 2, 2021

Hi! Sorry for the delay, been really busy with RNEU. That crash seems really weird, I'll take a look. Thanks for the report! 🖤

@mrousavy
Copy link
Owner

mrousavy commented Sep 2, 2021

does that crash happen 100% of the time or just sometimes?

@zhigang1992
Copy link
Author

Congrats on the awesome talk.

Only some times, I also can't reproduce this on my end. It's from PlayStore report.

Figure I post the crash log here see if anyone has any idea.

@henrymoulton
Copy link

hey @zhigang1992 is this something that's still an issue, do you have a rough % of affected users? Looking at trying out this library :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants