New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Flutter Upgrade - iOS No Longer Compiles #57222
Comments
code's output:
↳
In file included from /.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:7:
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.h:7:45: error: no type or protocol
named 'FlutterPlugin'
@interface FLTURLLauncherPlugin : NSObject <FlutterPlugin>
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:12:28: error: unknown type name
'FlutterResult'
@property(copy, nonatomic) FlutterResult flutterResult;
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:12:1: error: property with 'copy'
attribute must be of object type
@property(copy, nonatomic) FlutterResult flutterResult;
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:25:24: warning: incompatible pointer
to integer conversion assigning to 'int' from '__strong id' [-Wint-conversion]
self.flutterResult = result;
^ ~~~~~~
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:37:23: error: called object type
'int' is not a function or function pointer
self.flutterResult(nil);
~~~~~~~~~~~~~~~~~~^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:39:25: error: use of undeclared
identifier 'FlutterError'
self.flutterResult([FlutterError
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:66:41: error: no type or protocol
named 'FlutterPluginRegistrar'
+ (void)registerWithRegistrar:(NSObject<FlutterPluginRegistrar> *)registrar {
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:74:27: error: expected a type
- (void)handleMethodCall:(FlutterMethodCall *)call result:(FlutterResult)result {
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:74:60: error: expected a type
- (void)handleMethodCall:(FlutterMethodCall *)call result:(FlutterResult)result {
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:110:20: error: expected a type
call:(FlutterMethodCall *)call
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:111:20: error: expected a type
result:(FlutterResult)result {
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:132:53: error: expected a type
- (void)launchURLInVC:(NSString *)urlString result:(FlutterResult)result API_AVAILABLE(ios(9.0)) {
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:144:33: error: expected a type
- (void)closeWebViewWithResult:(FlutterResult)result API_AVAILABLE(ios(9.0)) {
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:67:3: error: use of undeclared
identifier 'FlutterMethodChannel'
FlutterMethodChannel *channel =
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:67:25: error: use of undeclared
identifier 'channel'
FlutterMethodChannel *channel =
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:68:8: error: use of undeclared
identifier 'FlutterMethodChannel'
[FlutterMethodChannel methodChannelWithName:@"plugins.flutter.io/url_launcher"
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:71:14: error: no visible @interface
for 'NSObject' declares the selector 'addMethodCallDelegate:channel:'
[registrar addMethodCallDelegate:plugin channel:channel];
~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:75:24: error: property 'arguments'
not found on object of type '__strong id'
NSString *url = call.arguments[@"url"];
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:76:42: error: property 'method' not
found on object of type '__strong id'
if ([@"canLaunch" isEqualToString:call.method]) {
^
/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.7/ios/Classes/FLTURLLauncherPlugin.m:77:11: error: called object type
'id' is not a function or function pointer
result(@([self canLaunchURL:url]));
~~~~~~^
fatal error: too many errors emitted, stopping now [-ferror-limit=] |
dev was just blown apart for me so I didn't even get that far. |
Yep, has happened to me as well for web on both master/beta |
I'm experiencing this issue also. flutter doctor -v
|
Hi @danielgchap @warriorCoder @knissophiliac |
I changed the channel to stable and upgraded, but the issue persist. flutter upgrade --force
flutter doctor -v
pubspec.yaml
|
Of course! Thank you so much. |
Hi @knissophiliac |
Sorry about that. It's attached here. |
Sorry I forgot that. Here it is. |
Update: I tried to create new project with updated version of Flutter(stable channel). Then, copied
into new project. Then, opened The problem is gone away. |
Hi @danielgchap |
@knissophiliac What parts of the pubspec, and plist files did you omit? @iapicca I haven't been on a mac in a while so that is the reason I've not been able to give you the outputs you're looking for. My sincere apologies. |
Hi @danielgchap |
@iapicca and @TahaTesser I've been able to confirm this issue and a workaround.
If I then try and run another build from the command line, things fall apart and the build fails. |
New update... after creating the new iOS folder I can successfully create a new build from vscode IF xcode is closed. |
|
I also encounter this problem and found this thread. so I dig the files where might the problem. to fix it. just copy existing ios/Flutter/Flutter.framework from other working Flutter projects you have. Reason: EDIT: How to identify if your Flutter.framework got corrupted?
|
Thanks so much sir. it works for me. |
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of |
I performed a 'Flutter Upgrade' and since then, the iOS side won't compile. Not in Visual Studio or in XCode directlly.
I have attached a screenshot.
I have tried the stable and master channels on Flutter. I'll try dev too.
The text was updated successfully, but these errors were encountered: