Skip to content

Single cached engine can't work with multi FlutterFragment #49950

Open

Description

@littleGnAl

I try to reuse the same cached engine in multi FlutterFragments, and each FlutterFragment host by a standalone Activity, which is named MainActivity in the sample code, here's the sample code:

class MainActivity : AppCompatActivity() {

    private val TAG_FLUTTER_FRAGMENT = "flutter_fragment"

    private var flutterFragment: FlutterFragment? = null

    override fun onCreate(savedInstanceState: Bundle?) {
        Log.setLogLevel(android.util.Log.VERBOSE)
        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_main)

        if (FlutterEngineCache.getInstance().get("cache_engine") == null) {
            val flutterEngine = FlutterEngine(applicationContext)
            flutterEngine.navigationChannel.setInitialRoute("/")
            flutterEngine.dartExecutor
                .executeDartEntrypoint(DartExecutor.DartEntrypoint.createDefault())
            FlutterEngineCache.getInstance().put("cache_engine", flutterEngine)
        }

        // Start a new FlutterFragment which host by MainActivity
        findViewById<AppCompatButton>(R.id.btnAddFragment).setOnClickListener {
            startActivity(Intent(this, MainActivity::class.java))
        }

        // Finish MainActivity
        findViewById<AppCompatButton>(R.id.btnPopFragment).setOnClickListener {
            finish()
        }

        flutterFragment = supportFragmentManager
            .findFragmentByTag(TAG_FLUTTER_FRAGMENT) as? FlutterFragment

        if (flutterFragment == null) {
            val ff: FlutterFragment = FlutterFragment
                .withCachedEngine("cache_engine")
                .transparencyMode(FlutterView.TransparencyMode.transparent)
                .renderMode(FlutterView.RenderMode.texture)
                .build()
            supportFragmentManager
                .beginTransaction()
                .add(
                    R.id.flFlutterFragment,
                    ff as Fragment,
                    TAG_FLUTTER_FRAGMENT
                )
                .commit()
        }
    }

    override fun onPostResume() {
        super.onPostResume()
        flutterFragment?.onPostResume()
    }

    override fun onNewIntent(intent: Intent) {
        flutterFragment?.onNewIntent(intent)
        super.onNewIntent(intent)
    }

    override fun onBackPressed() {
        flutterFragment?.onBackPressed()
    }

    override fun onRequestPermissionsResult(
        requestCode: Int,
        permissions: Array<String?>,
        grantResults: IntArray
    ) {
        flutterFragment?.onRequestPermissionsResult(
            requestCode,
            permissions,
            grantResults
        )
    }

    override fun onUserLeaveHint() {
        flutterFragment?.onUserLeaveHint()
    }

    override fun onTrimMemory(level: Int) {
        super.onTrimMemory(level)
        flutterFragment?.onTrimMemory(level)
    }
}

It works fine if there's only one "MainActivity", but the FlutterFragment seems to be frozen when a new "MainActivity" has been added or resumed by finishing the topmost "MainActivity".

uuuuu

The actual behavior is as follow:

ezgif com-video-to-gif (2)

Here's the sample code that can reproduce the problem. https://github.com/littleGnAl/single-engine-multi-fragments

Steps to Reproduce

  1. Click the bottom-right float action button to count some numbers
  2. Click "ADD NEW ACTIVITY" to add a new Activity
  3. Try click the bottom-right float action button to count some numbers
  4. Click "FINISH" to finish the topmost Activity
  5. Try click the bottom-right float action button to count some numbers

Expected results:
The MainActivity should work fine after resume
Actual results:
The FlutterFragment inside MainActivity has been frozen after resume

Logs

Android studio logcat

2020-02-02 16:53:02.491 29167-29167/? I/nemultifragmen: Late-enabling -Xcheck:jni
2020-02-02 16:53:02.529 29167-29167/? E/nemultifragmen: Unknown bits set in runtime_flags: 0x8000
2020-02-02 16:53:02.891 29167-29167/? W/nemultifragmen: Accessing hidden method Landroid/view/View;->computeFitSystemWindows(Landroid/graphics/Rect;Landroid/graphics/Rect;)Z (greylist, reflection, allowed)
2020-02-02 16:53:02.892 29167-29167/? W/nemultifragmen: Accessing hidden method Landroid/view/ViewGroup;->makeOptionalFitsSystemWindows()V (greylist, reflection, allowed)
2020-02-02 16:53:02.930 29167-29233/? I/ResourceExtractor: Found extracted resources res_timestamp-1-1580633324092
2020-02-02 16:53:02.935 29167-29167/? V/FlutterEngine: Attaching to JNI.
2020-02-02 16:53:02.942 29167-29167/? I/Adreno: QUALCOMM build                   : bc00834, I609ab310b2
    Build Date                       : 04/11/19
    OpenGL ES Shader Compiler Version: EV031.26.07.00
    Local Branch                     : 
    Remote Branch                    : 
    Remote Branch                    : 
    Reconstruct Branch               : 
2020-02-02 16:53:02.942 29167-29167/? I/Adreno: Build Config                     : S L 8.0.6 AArch64
2020-02-02 16:53:02.947 29167-29167/? I/Adreno: PFP: 0x005ff110, ME: 0x005ff066
2020-02-02 16:53:03.016 29167-29167/? V/DartMessenger: Setting handler for channel 'flutter/isolate'
2020-02-02 16:53:03.016 29167-29167/? V/DartExecutor: Attached to JNI. Registering the platform message handler for this Dart execution context.
2020-02-02 16:53:03.018 29167-29167/? V/DartMessenger: Setting handler for channel 'flutter/accessibility'
2020-02-02 16:53:03.019 29167-29167/? V/DartMessenger: Setting handler for channel 'flutter/platform'
2020-02-02 16:53:03.020 29167-29167/? V/DartMessenger: Setting handler for channel 'flutter/textinput'
2020-02-02 16:53:03.022 29167-29167/? V/NavigationChannel: Sending message to set initial route to '/'
2020-02-02 16:53:03.023 29167-29167/? V/DartMessenger: Sending message with callback over channel 'flutter/navigation'
2020-02-02 16:53:03.023 29167-29167/? V/DartExecutor: Executing Dart entrypoint: DartEntrypoint( bundle path: flutter_assets, function: main )
2020-02-02 16:53:03.038 29167-29167/? D/FlutterActivityAndFragmentDelegate: Setting up FlutterEngine.
2020-02-02 16:53:03.039 29167-29167/? D/FlutterActivityAndFragmentDelegate: Attaching FlutterEngine to the Activity that owns this Fragment.
2020-02-02 16:53:03.039 29167-29167/? V/FlutterEnginePluginRegistry: Attaching to an Activity: com.littlegnal.singleenginemultifragment.MainActivity@b635777.
2020-02-02 16:53:03.040 29167-29167/? V/DartMessenger: Setting handler for channel 'flutter/platform_views'
2020-02-02 16:53:03.041 29167-29167/? V/FlutterActivityAndFragmentDelegate: Creating FlutterView.
2020-02-02 16:53:03.044 29167-29167/? V/FlutterView: Initializing FlutterView
2020-02-02 16:53:03.044 29167-29167/? V/FlutterView: Internally using a FlutterTextureView.
2020-02-02 16:53:03.047 29167-29167/? V/FlutterActivityAndFragmentDelegate: onActivityCreated. Giving plugins an opportunity to restore state.
2020-02-02 16:53:03.047 29167-29167/? V/FlutterEnginePluginRegistry: Forwarding onRestoreInstanceState() to plugins.
2020-02-02 16:53:03.048 29167-29167/? V/FlutterActivityAndFragmentDelegate: onStart()
2020-02-02 16:53:03.051 29167-29167/? V/FlutterActivityAndFragmentDelegate: onResume()
2020-02-02 16:53:03.051 29167-29167/? V/LifecycleChannel: Sending AppLifecycleState.resumed message.
2020-02-02 16:53:03.051 29167-29167/? V/DartMessenger: Sending message with callback over channel 'flutter/lifecycle'
2020-02-02 16:53:03.065 29167-29167/? V/FlutterActivityAndFragmentDelegate: Attaching FlutterEngine to FlutterView.
2020-02-02 16:53:03.065 29167-29167/? D/FlutterView: Attaching to a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ed5547d
2020-02-02 16:53:03.065 29167-29167/? V/FlutterTextureView: Attaching to FlutterRenderer.
2020-02-02 16:53:03.066 29167-29167/? V/DartMessenger: Setting handler for channel 'flutter/textinput'
2020-02-02 16:53:03.067 29167-29167/? V/DartMessenger: Sending message with callback over channel 'flutter/textinput'
2020-02-02 16:53:03.075 29167-29167/? W/nemultifragmen: Accessing hidden method Landroid/view/accessibility/AccessibilityNodeInfo;->getSourceNodeId()J (greylist, reflection, allowed)
2020-02-02 16:53:03.075 29167-29167/? W/nemultifragmen: Accessing hidden method Landroid/view/accessibility/AccessibilityRecord;->getSourceNodeId()J (greylist, reflection, allowed)
2020-02-02 16:53:03.075 29167-29167/? W/nemultifragmen: Accessing hidden field Landroid/view/accessibility/AccessibilityNodeInfo;->mChildNodeIds:Landroid/util/LongArray; (greylist, reflection, allowed)
2020-02-02 16:53:03.075 29167-29167/? W/nemultifragmen: Accessing hidden method Landroid/util/LongArray;->get(I)J (greylist, reflection, allowed)
2020-02-02 16:53:03.077 29167-29247/? I/flutter: Observatory listening on http://127.0.0.1:41033/u8VjL_eiyPk=/
2020-02-02 16:53:03.078 29167-29167/? V/SettingsChannel: Sending message: 
    textScaleFactor: 1.0
    alwaysUse24HourFormat: false
    platformBrightness: light
2020-02-02 16:53:03.078 29167-29167/? V/DartMessenger: Sending message with callback over channel 'flutter/settings'
2020-02-02 16:53:03.079 29167-29167/? V/LocalizationChannel: Sending Locales to Flutter.
2020-02-02 16:53:03.079 29167-29167/? V/LocalizationChannel: Locale (Language: zh, Country: CN, Variant: )
2020-02-02 16:53:03.079 29167-29167/? V/LocalizationChannel: Locale (Language: en, Country: US, Variant: )
2020-02-02 16:53:03.079 29167-29167/? V/DartMessenger: Sending message with callback over channel 'flutter/localization'
2020-02-02 16:53:03.079 29167-29167/? V/FlutterRenderer: Setting viewport metrics
    Size: 0 x 0
    Padding - L: 0, T: 0, R: 0, B: 0
    Insets - L: 0, T: 0, R: 0, B: 0
    System Gesture Insets - L: 0, T: 0, R: 0, B: 0
2020-02-02 16:53:03.106 29167-29167/? V/FlutterView: Size changed. Sending Flutter new viewport metrics. FlutterView was 0 x 0, it is now 1440 x 2362
2020-02-02 16:53:03.106 29167-29167/? V/FlutterRenderer: Setting viewport metrics
    Size: 1440 x 2362
    Padding - L: 0, T: 0, R: 0, B: 0
    Insets - L: 0, T: 0, R: 0, B: 0
    System Gesture Insets - L: 0, T: 0, R: 0, B: 0
2020-02-02 16:53:03.116 29167-29167/? V/FlutterTextureView: SurfaceTextureListener.onSurfaceTextureAvailable()
2020-02-02 16:53:03.187 29167-29221/? W/Gralloc3: mapper 3.x is not supported
2020-02-02 16:53:03.193 29167-29167/? V/DartMessenger: Received message from Dart over channel 'flutter/isolate'
2020-02-02 16:53:03.193 29167-29167/? V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:53:03.599 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:53:03.599 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:53:03.600 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemChrome.setApplicationSwitcherDescription' message.
2020-02-02 16:53:04.198 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:53:04.198 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:53:04.198 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemChrome.setSystemUIOverlayStyle' message.
2020-02-02 16:53:04.210 29167-29235/com.littlegnal.singleenginemultifragment W/Gralloc3: allocator 3.x is not supported
2020-02-02 16:55:01.347 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:01.347 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:01.347 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:01.662 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:01.662 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:01.663 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:02.243 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:02.243 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:02.244 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:02.801 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:02.801 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:02.801 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:03.278 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:03.278 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:03.279 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:05.222 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onPause()
2020-02-02 16:55:05.222 29167-29167/com.littlegnal.singleenginemultifragment V/LifecycleChannel: Sending AppLifecycleState.inactive message.
2020-02-02 16:55:05.223 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/lifecycle'
2020-02-02 16:55:05.228 29167-29167/com.littlegnal.singleenginemultifragment W/ActivityThread: handleWindowVisibility: no activity for token android.os.BinderProxy@4fb9607
2020-02-02 16:55:05.260 29167-29167/com.littlegnal.singleenginemultifragment D/FlutterActivityAndFragmentDelegate: Setting up FlutterEngine.
2020-02-02 16:55:05.260 29167-29167/com.littlegnal.singleenginemultifragment D/FlutterActivityAndFragmentDelegate: Attaching FlutterEngine to the Activity that owns this Fragment.
2020-02-02 16:55:05.260 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterEnginePluginRegistry: Attaching to an Activity: com.littlegnal.singleenginemultifragment.MainActivity@7d5ed2.
2020-02-02 16:55:05.260 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterEnginePluginRegistry: Detaching from an Activity: com.littlegnal.singleenginemultifragment.MainActivity@b635777
2020-02-02 16:55:05.260 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Setting handler for channel 'flutter/platform_views'
2020-02-02 16:55:05.261 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: Creating FlutterView.
2020-02-02 16:55:05.261 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterView: Initializing FlutterView
2020-02-02 16:55:05.261 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterView: Internally using a FlutterTextureView.
2020-02-02 16:55:05.262 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onActivityCreated. Giving plugins an opportunity to restore state.
2020-02-02 16:55:05.262 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterEnginePluginRegistry: Forwarding onRestoreInstanceState() to plugins.
2020-02-02 16:55:05.262 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onStart()
2020-02-02 16:55:05.264 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onResume()
2020-02-02 16:55:05.264 29167-29167/com.littlegnal.singleenginemultifragment V/LifecycleChannel: Sending AppLifecycleState.resumed message.
2020-02-02 16:55:05.264 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/lifecycle'
2020-02-02 16:55:05.291 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterView: Size changed. Sending Flutter new viewport metrics. FlutterView was 0 x 0, it is now 1440 x 2362
2020-02-02 16:55:05.291 29167-29167/com.littlegnal.singleenginemultifragment W/FlutterView: Tried to send viewport metrics from Android to Flutter but this FlutterView was not attached to a FlutterEngine.
2020-02-02 16:55:05.297 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterTextureView: SurfaceTextureListener.onSurfaceTextureAvailable()
2020-02-02 16:55:05.304 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: Attaching FlutterEngine to FlutterView.
2020-02-02 16:55:05.304 29167-29167/com.littlegnal.singleenginemultifragment D/FlutterView: Attaching to a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ed5547d
2020-02-02 16:55:05.304 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterTextureView: Attaching to FlutterRenderer.
2020-02-02 16:55:05.304 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterTextureView: Surface is available for rendering. Connecting FlutterRenderer to Android surface.
2020-02-02 16:55:05.316 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Setting handler for channel 'flutter/textinput'
2020-02-02 16:55:05.318 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/textinput'
2020-02-02 16:55:05.322 29167-29167/com.littlegnal.singleenginemultifragment V/SettingsChannel: Sending message: 
    textScaleFactor: 1.0
    alwaysUse24HourFormat: false
    platformBrightness: light
2020-02-02 16:55:05.323 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/settings'
2020-02-02 16:55:05.323 29167-29167/com.littlegnal.singleenginemultifragment V/LocalizationChannel: Sending Locales to Flutter.
2020-02-02 16:55:05.323 29167-29167/com.littlegnal.singleenginemultifragment V/LocalizationChannel: Locale (Language: zh, Country: CN, Variant: )
2020-02-02 16:55:05.323 29167-29167/com.littlegnal.singleenginemultifragment V/LocalizationChannel: Locale (Language: en, Country: US, Variant: )
2020-02-02 16:55:05.323 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/localization'
2020-02-02 16:55:05.323 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterRenderer: Setting viewport metrics
    Size: 1440 x 2362
    Padding - L: 0, T: 0, R: 0, B: 0
    Insets - L: 0, T: 0, R: 0, B: 0
    System Gesture Insets - L: 0, T: 0, R: 0, B: 0
2020-02-02 16:55:05.750 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onStop()
2020-02-02 16:55:05.750 29167-29167/com.littlegnal.singleenginemultifragment V/LifecycleChannel: Sending AppLifecycleState.paused message.
2020-02-02 16:55:05.751 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/lifecycle'
2020-02-02 16:55:05.751 29167-29167/com.littlegnal.singleenginemultifragment D/FlutterView: Detaching from a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ed5547d
2020-02-02 16:55:05.761 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterTextureView: Disconnecting FlutterRenderer from Android surface.
2020-02-02 16:55:05.764 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onSaveInstanceState. Giving plugins an opportunity to save state.
2020-02-02 16:55:05.764 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterEnginePluginRegistry: Forwarding onSaveInstanceState() to plugins.
2020-02-02 16:55:06.942 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:06.942 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:06.942 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:07.198 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:07.198 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:07.198 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:07.416 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:07.416 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:07.417 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:07.626 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:07.626 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:07.626 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:07.848 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:07.848 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:07.848 29167-29167/com.littlegnal.singleenginemultifragment V/PlatformChannel: Received 'SystemSound.play' message.
2020-02-02 16:55:08.789 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onPause()
2020-02-02 16:55:08.789 29167-29167/com.littlegnal.singleenginemultifragment V/LifecycleChannel: Sending AppLifecycleState.inactive message.
2020-02-02 16:55:08.789 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/lifecycle'
2020-02-02 16:55:08.801 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onStart()
2020-02-02 16:55:08.802 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onResume()
2020-02-02 16:55:08.802 29167-29167/com.littlegnal.singleenginemultifragment V/LifecycleChannel: Sending AppLifecycleState.resumed message.
2020-02-02 16:55:08.802 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/lifecycle'
2020-02-02 16:55:08.821 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: Attaching FlutterEngine to FlutterView.
2020-02-02 16:55:08.821 29167-29167/com.littlegnal.singleenginemultifragment D/FlutterView: Attaching to a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ed5547d
2020-02-02 16:55:08.821 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterTextureView: Attaching to FlutterRenderer.
2020-02-02 16:55:08.821 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterTextureView: Surface is available for rendering. Connecting FlutterRenderer to Android surface.
2020-02-02 16:55:08.827 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Setting handler for channel 'flutter/textinput'
2020-02-02 16:55:08.828 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/textinput'
2020-02-02 16:55:08.836 29167-29167/com.littlegnal.singleenginemultifragment V/SettingsChannel: Sending message: 
    textScaleFactor: 1.0
    alwaysUse24HourFormat: false
    platformBrightness: light
2020-02-02 16:55:08.837 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/settings'
2020-02-02 16:55:08.837 29167-29167/com.littlegnal.singleenginemultifragment V/LocalizationChannel: Sending Locales to Flutter.
2020-02-02 16:55:08.837 29167-29167/com.littlegnal.singleenginemultifragment V/LocalizationChannel: Locale (Language: zh, Country: CN, Variant: )
2020-02-02 16:55:08.837 29167-29167/com.littlegnal.singleenginemultifragment V/LocalizationChannel: Locale (Language: en, Country: US, Variant: )
2020-02-02 16:55:08.838 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/localization'
2020-02-02 16:55:08.838 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterRenderer: Setting viewport metrics
    Size: 1440 x 2362
    Padding - L: 0, T: 0, R: 0, B: 0
    Insets - L: 0, T: 0, R: 0, B: 0
    System Gesture Insets - L: 0, T: 0, R: 0, B: 0
2020-02-02 16:55:09.262 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onStop()
2020-02-02 16:55:09.262 29167-29167/com.littlegnal.singleenginemultifragment V/LifecycleChannel: Sending AppLifecycleState.paused message.
2020-02-02 16:55:09.263 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/lifecycle'
2020-02-02 16:55:09.263 29167-29167/com.littlegnal.singleenginemultifragment D/FlutterView: Detaching from a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ed5547d
2020-02-02 16:55:09.268 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterTextureView: Disconnecting FlutterRenderer from Android surface.
2020-02-02 16:55:09.269 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onDestroyView()
2020-02-02 16:55:09.271 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterTextureView: SurfaceTextureListener.onSurfaceTextureDestroyed()
2020-02-02 16:55:09.272 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterActivityAndFragmentDelegate: onDetach()
2020-02-02 16:55:09.272 29167-29167/com.littlegnal.singleenginemultifragment D/FlutterActivityAndFragmentDelegate: Detaching FlutterEngine from the Activity that owns this Fragment.
2020-02-02 16:55:09.272 29167-29167/com.littlegnal.singleenginemultifragment V/FlutterEnginePluginRegistry: Detaching from an Activity: com.littlegnal.singleenginemultifragment.MainActivity@7d5ed2
2020-02-02 16:55:09.272 29167-29167/com.littlegnal.singleenginemultifragment V/LifecycleChannel: Sending AppLifecycleState.detached message.
2020-02-02 16:55:09.272 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Sending message with callback over channel 'flutter/lifecycle'
2020-02-02 16:55:09.727 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:09.727 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:09.901 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:09.901 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:10.087 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:10.088 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:10.298 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:10.298 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.
2020-02-02 16:55:10.510 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Received message from Dart over channel 'flutter/platform'
2020-02-02 16:55:10.510 29167-29167/com.littlegnal.singleenginemultifragment V/DartMessenger: Deferring to registered handler to process message.

flutter doctor

[✓] Flutter (Channel stable, v1.12.13+hotfix.5, on Mac OS X 10.15.1 19B88, locale en-CN)
    • Flutter version 1.12.13+hotfix.5 at /Users/littlegnal/dev/flutter
    • Framework revision 27321ebbad (8 weeks ago), 2019-12-10 18:15:01 -0800
    • Engine revision 2994f7e1e6
    • Dart version 2.7.0

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at /Users/littlegnal/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-29, build-tools 29.0.2
    • ANDROID_HOME = /Users/littlegnal/Library/Android/sdk
    • Java binary at: /Applications/Android Studio 3.6 Preview.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.3.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 11.3.1, Build version 11C504
    • CocoaPods version 1.8.4

[✓] Android Studio (version 3.6)
    • Android Studio at /Applications/Android Studio 3.6 Preview.app/Contents
    • Flutter plugin version 43.0.2
    • Dart plugin version 192.7761
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)

[✓] Android Studio
    • Android Studio at /Applications/Android Studio 4.0 Preview.app/Contents
    • Flutter plugin version 42.1.4
    • Dart plugin version 193.5731
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)

[✓] VS Code (version 1.41.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.7.1

[✓] Connected device (1 available)
    • Pixel 2 XL • 801KPSL1456990 • android-arm64 • Android 10 (API 29)

• No issues found!

Activity

  1. added
    a: existing-appsIntegration with existing apps via the add-to-app flow
    engineflutter/engine related. See also e: labels.
    platform-androidAndroid applications specifically
    on Feb 2, 2020
  2. dnfield commented on Feb 2, 2020

    @dnfield
    Contributor

    You need to re-attach the cached engine to the original fragment.

    I think we could probably be more helpful here if we had some kind of log in FlutterFragment for when it expect interaction or view updates but has no engine attached, but I'm not familiar enough with the Fragment API to know if that's feasible or not. /cc @matthew-carroll or @mklim who probably know

  3. littleGnAl commented on Feb 2, 2020

    @littleGnAl
    ContributorAuthor

    Thanks reply @dnfield .
    I have added some log and update the sample code that hosts a FlutterFragment inside the Activity to clarify the problem more clearly because Fragment's onPause, onResume lifecycle is coupled to the Activity, so these lifecycles would not be called in the previous sample. Sorry for my stupid mistake.

  4. yaminet1024 commented on Sep 13, 2020

    @yaminet1024

    I have the same problem. Has anyone solved it?

  5. littleGnAl commented on Sep 17, 2020

    @littleGnAl
    ContributorAuthor

    Any update on this?

  6. VomPom commented on Sep 22, 2020

    @VomPom

    I have solved this problem by changing the lifecycle code of ActivityFragmentDelegate,this problem caused by Activity or Fragment's lifecycle. As we know that Activity A launch Activity B lifecycle looks like:A.onPause() ->B.onCreate()-> B.onStart() ->B.onResume() ->A.onStop()

    The above of lifecycle will call the flutter engine lifecycle :

    A.onPause() -> flutterEngine.getLifecycleChannel().appIsInactive()
    
    B.onCreate()->  nothing.
    
    B.onStart() -> flutterEngine.getNavigationChannel().setInitialRoute(host.getInitialRoute());
    
    B.onResume() -> flutterEngine.getLifecycleChannel().appIsResumed();
    
    A.onStop()-> flutterEngine.getLifecycleChannel().appIsPaused();
    

    the last step made the flatter engine on pause status, so you should change the ActivityFragmentDelegate's code which makes it in the right lifecycle.

  7. xster commented on Oct 12, 2020

    @xster
    Member

    May or may not be fixed by flutter-team-archive/engine#21272. The sequence of events described in #49950 (comment) sound related to #66192. Worth testing again on master.

  8. littleGnAl commented on Oct 16, 2020

    @littleGnAl
    ContributorAuthor

    Hello @xster ,
    After trying the master branch, steps 1-3 can be worked correctly, but there will be a crash in step 4,

    1. Click the bottom-right float action button to count some numbers
    2. Click "ADD NEW ACTIVITY" to add a new Activity
    3. Try click the bottom-right float action button to count some numbers
    4. Click "FINISH" to finish the topmost Activity

    Here's the log:

    Logs
    
    2020-10-16 14:12:17.836 16457-16457/com.littlegnal.singleenginemultifragment E/AndroidRuntime: FATAL EXCEPTION: main
        Process: com.littlegnal.singleenginemultifragment, PID: 16457
        java.lang.NullPointerException: Attempt to invoke virtual method 'void io.flutter.embedding.android.FlutterActivityAndFragmentDelegate.onStart()' on a null object reference
            at io.flutter.embedding.android.FlutterFragment.onStart(FlutterFragment.java:601)
            at androidx.fragment.app.Fragment.performStart(Fragment.java:2632)
            at androidx.fragment.app.FragmentManagerImpl.moveToState(FragmentManagerImpl.java:915)
            at androidx.fragment.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManagerImpl.java:1238)
            at androidx.fragment.app.FragmentManagerImpl.moveToState(FragmentManagerImpl.java:1303)
            at androidx.fragment.app.FragmentManagerImpl.dispatchStateChange(FragmentManagerImpl.java:2659)
            at androidx.fragment.app.FragmentManagerImpl.dispatchStart(FragmentManagerImpl.java:2619)
            at androidx.fragment.app.FragmentController.dispatchStart(FragmentController.java:257)
            at androidx.fragment.app.FragmentActivity.onStart(FragmentActivity.java:551)
            at androidx.appcompat.app.AppCompatActivity.onStart(AppCompatActivity.java:201)
            at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1435)
            at android.app.Activity.performStart(Activity.java:8024)
            at android.app.ActivityThread.handleStartActivity(ActivityThread.java:3475)
            at android.app.servertransaction.TransactionExecutor.performLifecycleSequence(TransactionExecutor.java:221)
            at android.app.servertransaction.TransactionExecutor.cycleToPath(TransactionExecutor.java:201)
            at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:173)
            at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:97)
            at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2066)
            at android.os.Handler.dispatchMessage(Handler.java:106)
            at android.os.Looper.loop(Looper.java:223)
            at android.app.ActivityThread.main(ActivityThread.java:7656)
            at java.lang.reflect.Method.invoke(Native Method)
            at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
            at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)
    

    I think it is due to the detachFromFlutterEnginebe called when the activity is reattached.

    Here's the reproducible demo: https://github.com/littleGnAl/single-engine-multi-fragments/tree/littlegnal/try-flutter-master

  9. added
    P2Important issues not at the top of the work list
    on Oct 19, 2020
  10. KevinGong2013 commented on Nov 17, 2020

    @KevinGong2013

    Hello @xster ,
    After trying the master branch, steps 1-3 can be worked correctly, but there will be a crash in step 4,

    1. Click the bottom-right float action button to count some numbers
    2. Click "ADD NEW ACTIVITY" to add a new Activity
    3. Try click the bottom-right float action button to count some numbers
    4. Click "FINISH" to finish the topmost Activity

    Here's the log:

    Logs

    
    2020-10-16 14:12:17.836 16457-16457/com.littlegnal.singleenginemultifragment E/AndroidRuntime: FATAL EXCEPTION: main
        Process: com.littlegnal.singleenginemultifragment, PID: 16457
        java.lang.NullPointerException: Attempt to invoke virtual method 'void io.flutter.embedding.android.FlutterActivityAndFragmentDelegate.onStart()' on a null object reference
            at io.flutter.embedding.android.FlutterFragment.onStart(FlutterFragment.java:601)
            at androidx.fragment.app.Fragment.performStart(Fragment.java:2632)
            at androidx.fragment.app.FragmentManagerImpl.moveToState(FragmentManagerImpl.java:915)
            at androidx.fragment.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManagerImpl.java:1238)
            at androidx.fragment.app.FragmentManagerImpl.moveToState(FragmentManagerImpl.java:1303)
            at androidx.fragment.app.FragmentManagerImpl.dispatchStateChange(FragmentManagerImpl.java:2659)
            at androidx.fragment.app.FragmentManagerImpl.dispatchStart(FragmentManagerImpl.java:2619)
            at androidx.fragment.app.FragmentController.dispatchStart(FragmentController.java:257)
            at androidx.fragment.app.FragmentActivity.onStart(FragmentActivity.java:551)
            at androidx.appcompat.app.AppCompatActivity.onStart(AppCompatActivity.java:201)
            at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1435)
            at android.app.Activity.performStart(Activity.java:8024)
            at android.app.ActivityThread.handleStartActivity(ActivityThread.java:3475)
            at android.app.servertransaction.TransactionExecutor.performLifecycleSequence(TransactionExecutor.java:221)
            at android.app.servertransaction.TransactionExecutor.cycleToPath(TransactionExecutor.java:201)
            at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:173)
            at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:97)
            at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2066)
            at android.os.Handler.dispatchMessage(Handler.java:106)
            at android.os.Looper.loop(Looper.java:223)
            at android.app.ActivityThread.main(ActivityThread.java:7656)
            at java.lang.reflect.Method.invoke(Native Method)
            at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
            at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)
    

    I think it is due to the detachFromFlutterEnginebe called when the activity is reattached.

    Here's the reproducible demo: https://github.com/littleGnAl/single-engine-multi-fragments/tree/littlegnal/try-flutter-master

    delegate has been released.

  11. pedromassangocode commented on Dec 2, 2020

    @pedromassangocode

    Hi @littleGnAl
    Can you please provide your flutter doctor -v and a project example that reproduces this issue? The project in the OP does not seems to work (I got compile errors).
    Thank you

  12. 28 remaining items

  13. willlockwood commented on Dec 28, 2021

    @willlockwood
    Contributor

    @blasten and @0xZOne—has this issue been resolved by flutter-team-archive/engine#30202? Or am I misreading that PR and what it accomplishes?

  14. 0xZOne commented on Dec 28, 2021

    @0xZOne
    Member

    @blasten and @0xZOne—has this issue been resolved by flutter/engine#30202? Or am I misreading that PR and what it accomplishes?

    In fact, there are several issues that need to fix in the shared single-engine scenario, including flutter-team-archive/engine#30202, flutter-team-archive/engine#30126, and flutter-team-archive/engine#30208.

    Here is the use case.

  15. ShoaibKakal commented on Sep 28, 2023

    @ShoaibKakal

    any solution so far?

  16. added a commit that references this issue on Feb 24, 2024
  17. added a commit that references this issue on Feb 24, 2024
  18. huycozy commented on Apr 24, 2024

    @huycozy
    Member

    I checked this issue on the latest Flutter stable and master channels, the result has been improved a bit:

    • When adding new activity, FlutterFragment works fine (FAB is clickable)
    • When finish the topmost Activity, FlutterFragment has been frozen
    Demo
    Screen.Recording.2024-04-24.at.18.51.53.mov
    Updated sample code (be compatible with the new flutter version)

    single-engine-multi-fragments.zip

    flutter doctor -v (stable and master)
    [✓] Flutter (Channel stable, 3.19.6, on macOS 14.1 23B74 darwin-x64, locale en-VN)
        • Flutter version 3.19.6 on channel stable at /Users/huynq/Documents/GitHub/flutter
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision 54e66469a9 (31 hours ago), 2024-04-17 13:08:03 -0700
        • Engine revision c4cd48e186
        • Dart version 3.3.4
        • DevTools version 2.31.1
    
    [✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
        • Android SDK at /Users/huynq/Library/Android/sdk
        • Platform android-34, build-tools 34.0.0
        • ANDROID_HOME = /Users/huynq/Library/Android/sdk
        • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
        • Java version OpenJDK Runtime Environment (build 17.0.9+0-17.0.9b1087.7-11185874)
        • All Android licenses accepted.
    
    [✓] Xcode - develop for iOS and macOS (Xcode 15.3)
        • Xcode at /Applications/Xcode15.3.app/Contents/Developer
        • Build 15E204a
        • CocoaPods version 1.15.2
    
    [✓] Chrome - develop for the web
        • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
    
    [✓] Android Studio (version 2023.2)
        • Android Studio at /Applications/Android Studio.app/Contents
        • Flutter plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/9212-flutter
        • Dart plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/6351-dart
        • android-studio-dir = /Applications/Android Studio.app/
        • Java version OpenJDK Runtime Environment (build 17.0.9+0-17.0.9b1087.7-11185874)
    
    [✓] VS Code (version 1.88.1)
        • VS Code at /Applications/Visual Studio Code.app/Contents
        • Flutter extension version 3.86.0
    
    [✓] Connected device (3 available)
        • RMX2001 (mobile) • EUYTFEUSQSRGDA6D • android-arm64  • Android 11 (API 30)
        • macOS (desktop)  • macos            • darwin-x64     • macOS 14.1 23B74 darwin-x64
        • Chrome (web)     • chrome           • web-javascript • Google Chrome 123.0.6312.124
    
    [✓] Network resources
        • All expected network resources are available.
    
    • No issues found!
    [!] Flutter (Channel master, 3.22.0-16.0.pre.39, on macOS 14.1 23B74 darwin-x64, locale en-VN)
        • Flutter version 3.22.0-16.0.pre.39 on channel master at /Users/huynq/Documents/GitHub/flutter_master
        ! Warning: `flutter` on your path resolves to /Users/huynq/Documents/GitHub/flutter/bin/flutter, which is not inside your current Flutter SDK checkout at /Users/huynq/Documents/GitHub/flutter_master. Consider adding /Users/huynq/Documents/GitHub/flutter_master/bin to the front of your path.
        ! Warning: `dart` on your path resolves to /Users/huynq/Documents/GitHub/flutter/bin/dart, which is not inside your current Flutter SDK checkout at /Users/huynq/Documents/GitHub/flutter_master. Consider adding /Users/huynq/Documents/GitHub/flutter_master/bin to the front of your path.
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision 49770cd929 (24 minutes ago), 2024-04-23 22:55:10 -0400
        • Engine revision d4f63383d3
        • Dart version 3.5.0 (build 3.5.0-92.0.dev)
        • DevTools version 2.35.0-dev.8
        • If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades.
    
    [✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
        • Android SDK at /Users/huynq/Library/Android/sdk
        • Platform android-34, build-tools 34.0.0
        • ANDROID_HOME = /Users/huynq/Library/Android/sdk
        • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
        • Java version OpenJDK Runtime Environment (build 17.0.9+0-17.0.9b1087.7-11185874)
        • All Android licenses accepted.
    
    [✓] Xcode - develop for iOS and macOS (Xcode 15.3)
        • Xcode at /Applications/Xcode15.3.app/Contents/Developer
        • Build 15E204a
        • CocoaPods version 1.15.2
    
    [✓] Chrome - develop for the web
        • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
    
    [✓] Android Studio (version 2023.2)
        • Android Studio at /Applications/Android Studio.app/Contents
        • Flutter plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/9212-flutter
        • Dart plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/6351-dart
        • android-studio-dir = /Applications/Android Studio.app/
        • Java version OpenJDK Runtime Environment (build 17.0.9+0-17.0.9b1087.7-11185874)
    
    [✓] VS Code (version 1.88.1)
        • VS Code at /Applications/Visual Studio Code.app/Contents
        • Flutter extension version 3.86.0
    
    [✓] Connected device (2 available)
        • macOS (desktop) • macos  • darwin-x64     • macOS 14.1 23B74 darwin-x64
        • Chrome (web)    • chrome • web-javascript • Google Chrome 124.0.6367.79
    
    [✓] Network resources
        • All expected network resources are available.
    
    ! Doctor found issues in 1 category.
  19. added a commit that references this issue on Jun 22, 2026
    2595eb2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work lista: error messageError messages from the Flutter frameworka: existing-appsIntegration with existing apps via the add-to-app flowengineflutter/engine related. See also e: labels.found in release: 3.19Found to occur in 3.19found in release: 3.22Found to occur in 3.22has reproducible stepsThe issue has been confirmed reproducible and is ready to work onplatform-androidAndroid applications specificallyteam-androidOwned by Android platform teamtriaged-androidTriaged by Android platform team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions