Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

"Swift Compiler Error (Xcode): Method does not override any method from its superclass" error after updating Xcode

After updating my macOS version to 15.0 and updating Xcode to Version 16.0, my application can't get compiled and shows me this error:

Swift Compiler Error (Xcode): Method does not override any method from its superclass
/Users/userName/.pub-cache/hosted/pub.dev/flutter_inappwebview-5.8.0/ios/Classes/InAppWebView/InAppWebView.swift:1235:25

Could not build the application for the simulator.
Error launching application on iPad Air 13-inch (M2).

For sure it's because of the new Xcode update, but how do I solve it?

I tried:

  • changing some code in InAppWebView.swift:1235:25 file that I think can work.
  • cleaning the project.

Both did not help.

like image 895
Harry.R Jafari Avatar asked Apr 27 '26 00:04

Harry.R Jafari


1 Answers

To solve the error on iOS (Android requires more changes):

  1. upgrade to the latest flutter version: flutter upgrade
  2. then run flutter pub upgrade --major-versions: this will get the most updated and compatibility versions of the packages in Android and IOS and flutter
  3. then just run flutter clean && flutter pub get
like image 143
Harry.R Jafari Avatar answered Apr 29 '26 19:04

Harry.R Jafari



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!