Repository: flutter
Issue: Unable To Run Flutter App With Apple Watch Extension After Upgrading 3.27.0
Labels: platform-ios,tool,P2,team-ios,triaged-ios,fyi-tool

### Steps to reproduce

My app has an Apple Watch extension and working without any problem before upgrading Flutter 3.27
But after upgrade I cannot run my app from VSCode. But I can run either app itself or Apple Watch extension from XCode without any problem.

I know you will ask a reproducable example but I can only provide what I have for now. I will try to create a new project asap. 


### Expected results

I expect to run without any problem

### Actual results

Build fails on VSCode

### Code sample

<details open><summary>Code sample</summary>

```dart
// no code available
```

</details>


### Screenshots or Video

<details open>
<summary>Screenshots / Video demonstration</summary>

[Upload media here]

</details>


### Logs

<details open><summary>Logs</summary>

```console
Launching lib/main.dart on iPhone 16 Pro in debug mode...
Xcode build done.                                           40.4s
Failed to build iOS app
Swift Compiler Error (Xcode): 'StateObject' is only available in iOS 14.0 or newer
/Users/bahadirarslan/Development/Flutter/myproject/ios/MyProject%20Watch%20App/MainView.swift:10:5

Swift Compiler Error (Xcode): 'main()' is only available in iOS 14.0 or newer
/Users/bahadirarslan/Development/Flutter/myproject/ios/MyProject%20Watch%20App/MyProjectApp.swift:9:0

Swift Compiler Error (Xcode): 'Scene' is only available in iOS 14.0 or newer
/Users/bahadirarslan/Development/Flutter/myproject/ios/MyProject%20Watch%20App/MyProjectApp.swift:12:19

Swift Compiler Error (Xcode): Type 'WatchViewModel' does not conform to protocol 'WCSessionDelegate'
/Users/bahadirarslan/Development/Flutter/myproject/ios/MyProject%20Watch%20App/ViewModel/WatchViewModel.swift:79:0

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

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

Exited (1).
```

</details>


### Flutter Doctor output

<details open><summary>Doctor output</summary>

```console
[✓] Flutter (Channel stable, 3.27.0, on macOS 15.1 24B83 darwin-arm64, locale en-TR)
    • Flutter version 3.27.0 on channel stable at /Users/bahadirarslan/Development/SDKS/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 8495dee1fd (9 days ago), 2024-12-10 14:23:39 -0800
    • Engine revision 83bacfc525
    • Dart version 3.6.0
    • DevTools version 2.40.2

[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
    • Android SDK at /Users/bahadirarslan/Library/Android/sdk
    • Platform android-35, build-tools 35.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 21.0.3+-79915917-b509.11)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 16.2)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 16C5032a
    • CocoaPods version 1.15.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2024.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 21.0.3+-79915917-b509.11)

[✓] VS Code (version 1.96.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.102.0

[✓] Connected device (4 available)            
    • iPhone 16 Pro (mobile)          • B5611E87-5F6A-4178-ABAD-7B837493DE55 • ios            • com.apple.CoreSimulator.SimRuntime.iOS-18-2 (simulator)
    • macOS (desktop)                 • macos                                • darwin-arm64   • macOS 15.1 24B83 darwin-arm64
    • Mac Designed for iPad (desktop) • mac-designed-for-ipad                • darwin         • macOS 15.1 24B83 darwin-arm64
    • Chrome (web)                    • chrome                               • web-javascript • Google Chrome 131.0.6778.205
    ! Error: Browsing on the local area network for Bahadır’s iPhone. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)
    ! Error: Browsing on the local area network for Bahadir Arslan’s iPad. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)
    ! Error: Browsing on the local area network for Bahadır's iPad. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)

[✓] Network resources
    • All expected network resources are available.

• No issues found!
```

</details>