dwyl/learn-flutter

Could not build the application for the simulator. Error launching application on iPhone

nelsonic opened this issue · 3 comments

Just tried to run our App on localhost with:

flutter run

Got:

Launching lib/main.dart on iPhone SE (3rd generation) in debug mode...
Running Xcode build...
Xcode build done.                                            4.7s
Failed to build iOS app
Error (Xcode): type argument 'nw_proxy_config_t' (aka 'struct nw_proxy_config *') is neither an Objective-C object nor a block type
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator17.0.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKWebsiteDataStore.h:119:46


Parse Issue (Xcode): Could not build module 'WebKit'
/app/build/ios/Debug-iphonesimulator/flutter_inappwebview/flutter_inappwebview.framework/Headers/flutter_inappwebview-Swift.h:285:8


Parse Issue (Xcode): Could not build module 'WebKit'
/app/build/ios/Debug-iphonesimulator/flutter_inappwebview/flutter_inappwebview.framework/Headers/flutter_inappwebview-Swift.h:893:8

Uncategorized (Xcode): Command SwiftEmitModule failed with a nonzero exit code

Could not build the application for the simulator.
Error launching application on iPhone SE (3rd generation).

@LuchoTurtle were you able to run the App on the Simulator using iOS 17?

I'm using the physical iPhone S for testing. But I can get it to work on my simulator.
Have you tried this comment? pichillilorenzo/flutter_inappwebview#1735 (comment)

This seems to be related to the unwarranted XCode upgrade that was mentioned a few weeks ago.

Use the latest version of flutter_inappwebview. ie. flutter_inappwebview: ^5.8.0.
They have fixed the issue in the latest version

@navdeep22 thanks very much for letting us know. ❤️