Skip to content

iOS: Blank screen in running my flutter app in release mode #36247

Open

Description

@hesham91fci

Currently when running my app either from the terminal through the command flutter run -d "iPhone" --release or directly from xcode in release mode I got blank screen, and when inspecting the logs I can find the following error.
Runner[3296:651656] [VERBOSE-2:engine.cc(116)] Engine run configuration was invalid. Runner[3296:651656] [VERBOSE-2:FlutterEngine.mm(294)] Could not launch engine with configuration.
Kindly find below the output of flutter doctor

- Doctor summary (to see all details, run flutter doctor -v):
- [✓] Flutter (Channel stable, v1.2.1, on Mac OS X 10.14.5 18F132, locale en-EG)
- [✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
- [!] iOS toolchain - develop for iOS devices (Xcode 10.2.1)
-     ✗ CocoaPods not installed.
-         CocoaPods is used to retrieve the iOS platform side's plugin code that
-         responds to your plugin usage on the Dart side.
-         Without resolving iOS dependencies with CocoaPods, plugins will not work
-         on iOS.
-         For more info, see https://flutter.io/platform-plugins
-       To install:
-         brew install cocoapods
-         pod setup
- [✓] Android Studio (version 3.2)
- [✓] Connected device (2 available)

Any help would be appreciated,
thanks in advance :)

Activity

  1. hesham91fci commented on Jul 16, 2019

    @hesham91fci
    Author

    @jamesderlin any help would be appreciated
    Thanks in advance

  2. shinayser commented on Jul 16, 2019

    @shinayser

    Check this: #22188 (comment)

  3. juanjoserodrigolazaro commented on Jul 16, 2019

    @juanjoserodrigolazaro

    Same here, any solution? I dont have doctor issues!

  4. hesham91fci commented on Jul 17, 2019

    @hesham91fci
    Author

    Check this: #22188 (comment)

    I tried flutter build ios --release then flutter run -d "iPhone" --release but same behavior happens (Blank screen)
    @shinayser
    @zoechi Please any help would be appreciated

  5. leonardop21 commented on Jul 17, 2019

    @leonardop21

    GoogleService-Info inside the runner/runner folder inserted through x-code, I followed all the recommended steps, even though the application when sent to production gets the white screen when starting.

    Flutter clean
    flutter build ios --release

    Xcode
    Product -> Clean
    Archive
    Upload App Store

    But I have the same problem. Any idea what that might be?

  6. dnfield commented on Jul 17, 2019

    @dnfield
    Contributor

    Can you try this on the latest stable, and make sure to thoroughly clean your project?

    This error normally means that something is off with the AOT blob. It could be that it was built with the wrong version of Dart somehow, or it could be that the build system got confused and isn't giving you the right artifact. 1.2.1 is two stable releases behind the latest stable at this point though,s o it would be good to try on latest stable first.

  7. added
    engineflutter/engine related. See also e: labels.
    c: crashStack traces logged to the console
    t: xcode"xcodebuild" on iOS and general Xcode project management
    toolAffects the "flutter" command-line tool. See also t: labels.
    platform-iosiOS applications specifically
    on Jul 17, 2019
  8. added this to the milestone on Jul 17, 2019
  9. steelhearts commented on Jul 18, 2019

    @steelhearts

    I have the same problem

    In my case it happened after updating from 1.5.x to 1.7.8 + hotfix.3

    I thought that trash was accumulated in the build folder etc.

    So I deleted the build folder and the Derived Data folder, but the result did not change

    Jul 18 14:30:42 ALEXANDER Runner(Flutter)[11428] <Notice>: [VERBOSE-2:engine.cc(118)] Engine run configuration was invalid.
    Jul 18 14:30:42 ALEXANDER Runner(Flutter)[11428] <Notice>: [VERBOSE-2:FlutterEngine.mm(308)] Could not launch engine with configuration.
    

    Execution result of Flutter doctor

    Doctor summary (to see all details, run flutter doctor -v):
    [✓] Flutter (Channel stable, v1.7.8+hotfix.3, on Mac OS X 10.14.5 18F132, locale ja-JP)
     
    [!] Android toolchain - develop for Android devices (Android SDK version 29.0.1)
        ✗ Android licenses not accepted.  To resolve this, run: flutter doctor --android-licenses
    [✓] Xcode - develop for iOS and macOS (Xcode 10.2.1)
    [✓] iOS tools - develop for iOS devices
    [✓] Android Studio (version 3.4)
    [✓] Connected device (1 available)
    

    it worked fine until last week. . .

  10. dnfield commented on Jul 18, 2019

    @dnfield
    Contributor

    Another possibility is that the cache is out of sync.

    Try removing the bin/cache folder from you flutter checkout. It should automatically regenerate and may fix this.

  11. steelhearts commented on Jul 26, 2019

    @steelhearts

    Try it in a local environment and it works well.

    But the flutter project on CircleCI also has the same problem...

    It happens with ipa files output to circleci artifacts. . .

  12. 66 remaining items

  13. TheMkrage commented on Jan 28, 2021

    @TheMkrage

    I got this problem with my app tonight.

    But the interesting thing is that the release build, uploaded to Apple and then served to test devices via TestFlight, worked normally on all my 3 phones (iPhone 8 & 2x iPhone 11 with iOS 13.3). But after it was promoted for App Store Review it was rejected with the black screen message.

    flutter clean, etc, mentioned above in this thread, did not help and all subsequent builds were rejected by Apple with the same feedback. (And again, they all worked via TestFlight on all my devices). Very weird and frustrating.

    I have this exact same issue. I cannot recreate this issue no matter how I get the app on my device( VSCode, TestFlight, or Xcode). Did you ever solve this @livotov ? I have also created #74843

  14. naoyanickf commented on Nov 23, 2021

    @naoyanickf
  15. dsp1589 commented on Jan 3, 2022

    @dsp1589
  16. OM-Tecnologia commented on Jun 15, 2022

    @OM-Tecnologia

    i'm with the same issue, any permanent solution?
    I created a new flutter project (flutter create my_app) and implement firebase push notification, the notifications are working fine, but it show a blank screen.

  17. OM-Tecnologia commented on Jun 15, 2022

    @OM-Tecnologia

    i'm with the same issue, any permanent solution? I created a new flutter project (flutter create my_app) and implement firebase push notification, the notifications are working fine, but it show a blank screen.

    i'm go trying add loading indicator

  18. OM-Tecnologia commented on Jun 15, 2022

    @OM-Tecnologia

    My problem i think was specific, i comment some of the code above, now it works fine.

    void main() {
    
      //await PushNotificationService().setupInteractedMessage();
      HttpOverrides.global = new MyHttpOverrides();
    
      runApp(MyApp());
    
      //RemoteMessage initialMessage = await FirebaseMessaging.instance.getInitialMessage();
    
      //if (initialMessage != null) {
    
        // App received a notification when it was killed
    
      //}
    
    }
    
  19. Dharmeshkatariya commented on Jul 27, 2023

    @Dharmeshkatariya

    same isssue

  20. itahirmasood commented on Jul 28, 2023

    @itahirmasood

    I had the same issue while running my app & it was stuck at Blue Screen which was FIXED by adding GoogleService-info.plist in the project. It can be added in xCode or in ios folder.

    Please check logs if it's attempting to connect to firebase or has any firebase dependencies. If it does then check if you have added GoogleService-info.plist? You might be missing that.

    Edit: You will have to Clean build folder after doing that and build & run the app. Hopefully it will work fine.

  21. 3kdeveloper commented on Nov 8, 2023

    @3kdeveloper

    hesham91fci Run your app on profile mode then test the whole app manually. or In the debug mode when you run your app, open the terminal, and then start testing your app hopefully you will get an issue Like Incorrect Use of Parent Widget Mostly this issue was caused by Expanded widgets when we used them in the wrong place.

  22. waqaskhanroghani commented on Mar 25, 2024

    @waqaskhanroghani

    I solved the problem.

    1. Open the project in Xcode.
    2. Go to Build Phases.
    3. In 'Bundle React Native code and images,' remove the code."
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 listc: crashStack traces logged to the consolecustomer: crowdAffects or could affect many people, though not necessarily a specific customer.engineflutter/engine related. See also e: labels.platform-iosiOS applications specificallyt: xcode"xcodebuild" on iOS and general Xcode project managementteam-iosOwned by iOS platform teamtoolAffects the "flutter" command-line tool. See also t: labels.triaged-iosTriaged by iOS platform team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions