-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
xcode 16 beta3 - ambiguous use of 'evaluateJavaScript(_:completionHandler:_)' build error #2221
Comments
NOTE: This comment is auto-generated. Are you sure you have already searched for the same problem? Some people open new issues but they didn't search for something similar or for the same issue. Please, search for it using the GitHub issue search box or on the official inappwebview.dev website, or, also, using Google, StackOverflow, etc. before posting a new one. You may already find an answer to your problem! If this is really a new issue, then thank you for raising it. I will investigate it and get back to you as soon as possible. Please, make sure you have given me as much context as possible! Also, if you didn't already, post a code example that can replicate this issue. In the meantime, you can already search for some possible solutions online! Because this plugin uses native WebView, you can search online for the same issue adding Following these steps can save you, me, and other people a lot of time, thanks! |
same here |
Same error also occurs in flutter_inappwebview_macos (macOS 15 Beta, Xcode 16 Beta 3) |
+1 |
+1 Broken build on iOS |
FYI, this is specifically an incompatibility with xcode16 and not iOS18. Xcode 16 is needed to install iOS18 simulators, however iOS18 simulators will run on xcode15. I was able to bypass the issue by rolling back xcode16 to 15.4 and running iOS18 there. |
Yes, this is a temporary solution, next year the appstore will force the use of xcode16, will still face this problem, the library has been more than half a year without merging code! |
Is this being fixed? |
I updated Mac OS to beta versions and it won't let me downgrade to Xcode 15.4 now. I am stuck with Xcode 16, Any help would be appreciated. |
@ConnorDykes this should work dependency_overrides:
url_launcher_ios: 6.3.1 |
same error, the dependency override didn't work for me, any update on this issue? Package doesn't seem compatible with xcode 16 |
I clicked on the error, and I deleted one like this, then it worked!
|
just updated to beta 6 and im getting this issue again, I had to edit the funciton to look like this: open override func evaluateJavaScript(_ javaScriptString: String, completionHandler: (@mainactor (Any?, Error?) -> Void)? = nil) {
it will build from Xcode directly but not VScode |
+1 |
I noticed someone put out a fix for this, which is to update the signature of For now I'm overriding with it in
|
Just like what tinaroh commented. I make a little different changes based on other pr. I keep the override function Also can use like following:
|
the xcode16 release is available, so this issue is a kind of critical. any updates? |
Same problem here, any updates? |
same issue after updating to Mac OS sequoia. |
Seconding this. I'm now encountering this issue after XCode just auto-updated. Until a fix comes out, it appears that downgrading to XCode 15.4 will work around the issue. For those mentioning the fork made by andychucs, it doesn't seem like it works (or I set it up wrong). I still got the exception even after adding the fork as a dependency override. |
are you able to downgrade the xcode? i cannot, as my macos also updated to sequoia. it just shows an error 'in order to use xcode you need to update to the latest version' |
I was about to come back to comment on this. I was talking to a colleague who said that he could not downgrade because he'd updated his OS version. If you've already upgraded it, then you'll need another solution. (As such, I'm now trying to get things working with XCode 16.0 again... 15.4 is a very temporary solution) |
I have the same issue, this temporary solution works for me, thank you 🚀
|
For those looking for a fast workaround for Credit and thanks go to @andychucs Add the following to your dependencies:
# rest of your dependencies ...
flutter_inappwebview: ^6.0.0
# Add the following dependency overrides for iOS & macOS, as needed -->
dependency_overrides:
flutter_inappwebview_ios:
git:
url: https://github.com/andychucs/flutter_inappwebview.git
ref: master
path: flutter_inappwebview_ios
flutter_inappwebview_macos:
git:
url: https://github.com/andychucs/flutter_inappwebview.git
ref: master
path: flutter_inappwebview_macos
# <-- |
+1 |
I also cleaned project, even added dependency overrides, pinned versions...and still nothing :( |
I was able to update the dependencies of the https://github.com/pichillilorenzo/flutter_browser_app app and I didn't have any problems on iOS.
and run your app on iOS. |
still got the issue in 6.1.0+1 |
@pichillilorenzo it does not work. It's 100% sure. I triple checked everything, and your flutter_inappwebview package cannot be used on Xcode 15.x. It's that simple (and I'm sorry for it). The error is invariably:
I tried resetting Xcode in all possible and imaginable ways, upgrading to Ventura 13.7 (released yesterday), of course recreating all Pods and everything, all I managed to do was to get the above-mentioned error, with the addition of the following errors, too:
The only (not really cool) workaround is to use this solution: making sure Again, I am not mentioning here a problem with Xcode 16, just Xcode 15.x. Your package no longer works with Xcode 15 as it is currently published in pub.dev. Can I suggest that you look at the above listed 'xcode-15-fix' fix, and apply it to your codebase, in addition to the fix for Xcode 16. Many people still use Xcode 15 and still will for a while. |
@pichillilorenzo if I can help (testing on my setup), let me know. The thing is, I am not too familiar with iOS/Swift programming. My iPhoneOS.platform SDK version is 17.2 (latest version available for Xcode on Ventura), as shown in
Maybe you are using a different SDK version? I wonder if conditional compilation directives couldn't be used here? |
@andynewman10 currently the new version works only with XCode >= 16.0, so it won't work on XCode 15.x Currently, I haven't found a compilation directive to check XCode versions or if there is something that could be used to support both XCode 15 and 16. |
Maybe |
Moved to: #2288 |
Released new You can run |
Stucked in the same situatuin, if you find any solution, please let me know. |
@akshayAtDWI update the |
EDIT: I've found the solution here #2201 (comment) thanks! pardon to resurrect the issue @pichillilorenzo, but is there any other alternative to upgrading The thing is to update the pub package require us to upgrade Flutter, which we cannot do in the meantime. Thanks before |
This is the best solution, it works for me. |
Has anyone tried to solve it, please? Flutter 3.19.6 • channel stable • https://github.com/flutter/flutter.git |
@Aladdin-Shaker the latest plugin works with Flutter 3.24+. If you can update Flutter, then you can update also the plugin. |
Thanks, do you mean flutter_inappwebview ? |
@Aladdin-Shaker yes 👍 |
Thanks :) |
This is worked me. Thanks ❤️ |
is there new plugin update with this fix? |
No, I have upgraded the Flutter version with the packages |
Yes, you need to update the plugin @qwertylolman
|
i have upgraded dependencies and flutter to latest and it is running but not working properly. |
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 and a minimal reproduction of the issue. |
Environment
Device information:
Description
Expected behavior:
Build successful
Current behavior:
Notes
This is specifically an incompatibility with xcode16 and not iOS18. Xcode 16 is needed to install iOS18 simulators, however iOS18 simulators will run on xcode15. I was able to bypass the issue by rolling back xcode16 to 15.4 and running iOS18 there.
The text was updated successfully, but these errors were encountered: