Skip to content

Swift Compiler Error (Xcode): 'shared' is unavailable in application extensions for iOS: Use view controller based solutions where appropriate instead. #3076

@cuong292

Description

@cuong292

Platform

Flutter Mobile iOS

Obfuscation

Enabled

Debug Info

Enabled

Doctor

[✓] Flutter (Channel stable, 3.29.3, on macOS 15.3.1 24D70 darwin-arm64, locale en-VN) [1,318ms]
• Flutter version 3.29.3 on channel stable at
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision ea121f8859 (3 months ago), 2025-04-11 19:10:07 +0000
• Engine revision cf56914b32
• Dart version 3.7.2
• DevTools version 2.42.3

[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.1) [3.1s]
• Android SDK at /Library/Android/sdk
• Platform android-35, build-tools 35.0.1
• Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
This is the JDK bundled with the latest Android Studio installation on this machine.
To manually set the JDK path, use: flutter config --jdk-dir="path/to/jdk".
• Java version OpenJDK Runtime Environment (build 21.0.6+-13368085-b895.109)
• All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 16.3) [1,932ms]
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 16E140
• CocoaPods version 1.16.2

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

[✓] Android Studio (version 2024.3) [10ms]
• 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.6+-13368085-b895.109)

[✓] VS Code (version 1.100.3) [9ms]
• Flutter extension version 3.114.0

arm64
• Mac Designed for iPad (desktop) • mac-designed-for-ipad • darwin • macOS 15.3.1 24D70 darwin-arm64
• Chrome (web) • chrome • web-javascript • Google Chrome 138.0.7204.101
! Error: Browsing on the local area network for iPhone của Nguyen. 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 [576ms]
• All expected network resources are available.

• No issues found!

Version

8.14.2

Steps to Reproduce

Sentry in Podfile.lock : Sentry (8.53.2):
- Sentry/Core (= 8.53.2)

  • Sentry/Core (8.53.2)

  • I face the issue when run flutter project with Sentry. It's able to run if i change the above Sentry version to 8.53.1

  • I was tried :

  • Upgrade Sentry to latest version
  • Turn Require Only App-Extension-Safe API to No in PodFile -> Sentry -> Build Setting

<img width="791" height="353" alt="Image" src="https://github.com/user-attachments/assets/e2d85664-f5ca-4f68-852e-245226f3895f"

Expected Result

How to make it able to run?

Actual Result

Swift Compiler Error (Xcode): 'shared' is unavailable in application extensions for iOS: Use view controller based solutions where appropriate instead.

Are you willing to submit a PR?

None

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions