Failed to find assets path for "Frameworks/App.framework/flutter_assets"

Viewed 5830

I'm trying to run my flutter app on the simulator ( iPhone 8 ) but when the app lunches all I get is a blank white screen. like this:

enter image description here

Terminal output is:

Running pod install...                                             40.0s
Running Xcode build...                                                  

 ├─Assembling Flutter resources...                          20.4s
 └─Compiling, linking and signing...                        57.0s
Xcode build done.                                           288.8s
        path: satisfied (Path is satisfied), interface: en1
Failed to find assets path for "Frameworks/App.framework/flutter_assets"
Configuring the default Firebase app...
        path: satisfied (Path is satisfied), interface: en1
        path: satisfied (Path is satisfied), interface: en1
Configured the default Firebase app __FIRAPP_DEFAULT.
[VERBOSE-2:engine.cc(127)] Engine run configuration was invalid.
[VERBOSE-2:shell.cc(437)] Could not launch engine with configuration.
https://firebase.google.com/docs/cloud-messaging/ios/client#method_swizzling_in_firebase_messaging
to ensure proper integration.                                           
Syncing files to device iPhone 8...                                     
10,195ms (!)

I'm using the stable version of flutter 1.12.13+hotfix.9, and this issue appears only on ios building.

How can I solve this issue?

4 Answers

I've just managed to solve this issue. I've just followed advise https://github.com/flutter/flutter/issues/29974 and added "$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh" embed to Run script Run script After rebuilding App.framework folder has been added to build directory and problem has gone. Hope this will help someone else.

First, you should write in your android studio terminal this command:

  • rm -rf ios/Flutter/App.framework

  • Then in Xcode select TARGETS then select Runner

  • After that choose the Build Phases from Middle Top options

  • Then Open the Thin Binary

  • Remove the script inside with

/bin/sh "$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh" embed

/bin/sh "$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh" thin

That's Worked for me, Hopefully, work for you also :-)

Further read : https://flutter.dev/docs/development/ios-project-migration

enter image description here

In my case, I need to uncheck the build flag "For install build only" in Build Phrases -> Run Script

Related