Skip to content

ANR Android createAndRunEngine #173087

@rahul4slice

Description

@rahul4slice

Steps to reproduce

In Application onCreate, We are doing createAndRunEngine on FlutterEngineGroup.
Happening on App-Launch

Expected results

ANR should not be experience by user

Actual results

ANR is Experienced by lots of users(thousands) as per firebase and play-console.

Code sample

flutterEngine = flutterEngineGroup?.createAndRunEngine(options)

Screenshots or Video

No response

Logs

Logs
  #00  pc 0x000000000004d56c  /apex/com.android.runtime/lib64/bionic/libc.so (syscall+28)
  #01  pc 0x0000000000051ff0  /apex/com.android.runtime/lib64/bionic/libc.so (__futex_wait_ex+144)
  #02  pc 0x00000000000b3b80  /apex/com.android.runtime/lib64/bionic/libc.so (pthread_cond_wait+80)
  #03  pc 0x000000000097bd50  /data/app/~~H6ZHTV_37dQ_1VFi7-Q73A==/indwin.c3.shareapp-HfFVgQ_obyEjMdWONOmKug==/lib/arm64/libflutter.so (BuildId: 3031bbbe81d7b590351f632cfe5b0209afd516bd)
  #04  pc 0x000000000072dc74  /data/app/~~H6ZHTV_37dQ_1VFi7-Q73A==/indwin.c3.shareapp-HfFVgQ_obyEjMdWONOmKug==/lib/arm64/libflutter.so (BuildId: 3031bbbe81d7b590351f632cfe5b0209afd516bd)
  #05  pc 0x00000000007f218c  /data/app/~~H6ZHTV_37dQ_1VFi7-Q73A==/indwin.c3.shareapp-HfFVgQ_obyEjMdWONOmKug==/lib/arm64/libflutter.so (BuildId: 3031bbbe81d7b590351f632cfe5b0209afd516bd)
  #06  pc 0x00000000007f2b3c  /data/app/~~H6ZHTV_37dQ_1VFi7-Q73A==/indwin.c3.shareapp-HfFVgQ_obyEjMdWONOmKug==/lib/arm64/libflutter.so (BuildId: 3031bbbe81d7b590351f632cfe5b0209afd516bd)
  #07  pc 0x0000000000806190  /data/app/~~H6ZHTV_37dQ_1VFi7-Q73A==/indwin.c3.shareapp-HfFVgQ_obyEjMdWONOmKug==/lib/arm64/libflutter.so (BuildId: 3031bbbe81d7b590351f632cfe5b0209afd516bd)
  #08  pc 0x0000000000805fa8  /data/app/~~H6ZHTV_37dQ_1VFi7-Q73A==/indwin.c3.shareapp-HfFVgQ_obyEjMdWONOmKug==/lib/arm64/libflutter.so (BuildId: 3031bbbe81d7b590351f632cfe5b0209afd516bd)
  #09  pc 0x0000000000496284  /data/app/~~H6ZHTV_37dQ_1VFi7-Q73A==/indwin.c3.shareapp-HfFVgQ_obyEjMdWONOmKug==/lib/arm64/libflutter.so (BuildId: 3031bbbe81d7b590351f632cfe5b0209afd516bd)
  at io.flutter.embedding.engine.FlutterJNI.nativeRunBundleAndSnapshotFromLibrary (FlutterJNI.java)
  at io.flutter.embedding.engine.FlutterJNI.runBundleAndSnapshotFromLibrary (FlutterJNI.java:1001)
  at io.flutter.embedding.engine.dart.DartExecutor.executeDartEntrypoint (DartExecutor.java:146)
  at io.flutter.embedding.engine.FlutterEngineGroup.createAndRunEngine (FlutterEngineGroup.java:166)
  at com.xyz.android.platform.xyz.flutter.FlutterManager.setCoreFlutterEngine (FlutterManager.kt:106)
  at com.xyz.android.platform.xyz.flutter.FlutterManager.setDartEntrypointConfig (FlutterManager.kt:97)
  at com.xyz.android.platform.xyz.flutter.FlutterManager.initFlutterEngine (FlutterManager.kt:56)

Flutter Doctor output

Android Target SDK -35
Flutter SDK - 3.29.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    a: productionIssues experienced in live production appsc: crashStack traces logged to the consolec: fatal crashCrashes that terminate the processengineflutter/engine related. See also e: labels.needs repro infoAutomated crash report whose cause isn't yet knownplatform-androidAndroid applications specificallyr: invalidIssue is closed as not validteam-engineOwned by Engine team

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions