-
Notifications
You must be signed in to change notification settings - Fork 27k
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
Apple Watch target detection does not work for new Apple Watch targets #99031
Comments
Reproducible on I can confirm the workaround works. See logs below flutter doctor -v
|
/cc @jmagman |
Duplicate of #92294. |
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 |
NOTE
This IS NOT an issue regarding Flutter supporting Apple Watch targets in general. I created #97721 already, but that one was closed as a duplicate. This is NOT a duplicate issue (unless someone beat me to it). Apple Watch targets created by older versions of Xcode used to build fine with Flutter.
Steps to Reproduce
flutter create
flutter build ios
Expected results:
Flutter detects that the project contains an Apple Watch target and adjusts the build settings accordingly. The following line should appear in the build log:
Watch companion app found.
Successful build
Actual results:
Flutter cannot detect that new Apple Watch targets created by Xcode exist because the structure of Apple Watch targets changed
Build failure
Code sample
https://github.com/Rexios80/flutter_apple_watch_build_failure
Logs
Additional Information
Currently, Flutter looks for a
WKCompanionAppBundleIdentifier
key in plist files, but that key no longer exists in new Apple Watch targets.The watchkitapp target no longer contains a plist by default, and the watchkitextension target contains a plist with the following contents:
This issue can be worked around by adding the following items to the watchkitextension plist:
Ideally this workaround would be unnecessary.
Location of the issue in the Flutter repo:
flutter/packages/flutter_tools/lib/src/xcode_project.dart
Line 335 in e4351ff
The text was updated successfully, but these errors were encountered: