Skip to content

Example app crashing in Release scheme #131

Closed
@dawidb-appdate

Description

@dawidb-appdate

Describe the bug
hey, when building android app using standard command 'flutter build apk --release' package is created, but when loaded to actual phone it crashes every time. I was managed to figure out that it's the very first line is crashing 'final _ble = FlutterReactiveBle();', so basically loading/initializing the library.
When running in debug on the same device it works well.
Have you guys had similar problems? What could be causing the problem.

To Reproduce
Steps to reproduce the behavior:

  1. Build release scheme with command 'flutter build apk --release'
  2. Load the app to actual device
  3. Run app and see it crashing

Smartphone / tablet

  • Device: Mi MIX 2s
  • Android 9

Additional context
Android studio 4.0.2
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 1.22.1, on Mac OS X 10.15.7 19H2, locale en-PL)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 12.0.1)
[✓] Android Studio (version 4.0)

Log from phone:
d.b.z.d: The exception was not handled due to missing onError handler in the subscribe() method call. Further reading: https://github.com/ReactiveX/RxJava/wiki/Error-Handling | java.lang.RuntimeException: Field status_ for c.d.a.a.c not found. Known fields are [private static final c.d.a.a.c c.d.a.a.c.e, private static volatile c.a.a.b1 c.d.a.a.c.f] at d.b.b0.b.a$h.a(Unknown Source:2) at d.b.b0.b.a$h.f(Unknown Source:2) at d.b.b0.d.h.b(Unknown Source:13) at d.b.b0.d.h.e(Unknown Source:25) at d.b.b0.e.e.i0$a.l(Unknown Source:47) at d.b.b0.e.e.i0$a.run(Unknown Source:8) at d.b.x.b.b$b.run(Unknown Source:2) at android.os.Handler.handleCallback(Handler.java:873) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:201) at android.app.ActivityThread.main(ActivityThread.java:6806) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:547) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:873) Caused by: java.lang.RuntimeException: Field status_ for c.d.a.a.c not found. Known fields are [private static final c.d.a.a.c c.d.a.a.c.e, private static volatile c.a.a.b1 c.d.a.a.c.f]

Metadata

Metadata

Assignees

No one assigned

    Labels

    AndroidAndroid-specific ticketbugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions