DataDog/dd-sdk-flutter

App crash - iOS Flutter

ShekharEnvato opened this issue · 2 comments

Logs from flutter run --verbose
CrashLog.txt

XCode Debugger shows error in this line
if #available(iOS 12, tvOS 12, *) {
subscribe(.networkConnectionInfo, to: NWPathMonitorPublisher())
} else {
assign(reader: SCNetworkReachabilityReader(), to: .networkConnectionInfo)
}

Flutter doctor -v
[✓] Flutter (Channel stable, 3.13.9, on macOS 14.0 23A344 darwin-x64, locale en-MX)
• Flutter version 3.13.9 on channel stable at /Users/shekhar.suman.envato/development/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision d211f42860 (8 days ago), 2023-10-25 13:42:25 -0700
• Engine revision 0545f8705d
• Dart version 3.1.5
• DevTools version 2.25.0

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
• Android SDK at /Users/shekhar.suman.envato/Library/Android/sdk
• Platform android-34, build-tools 34.0.0
• Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 11.0.15+0-b2043.56-8887301)
• All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.0.1)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 15A507
• CocoaPods version 1.12.1

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

[✓] Android Studio (version 2022.1)
• 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 11.0.15+0-b2043.56-8887301)

[✓] VS Code (version 1.84.0)
• VS Code at /Users/shekhar.suman.envato/Desktop/Visual Studio Code.app/Contents
• Flutter extension version 3.76.0

[✓] Connected device (3 available)
• iPhone 15 Pro (mobile) • 06E5A649-291D-445D-9BD5-2888CBD4B36B • ios • com.apple.CoreSimulator.SimRuntime.iOS-17-0 (simulator)
• macOS (desktop) • macos • darwin-x64 • macOS 14.0 23A344 darwin-x64
• Chrome (web) • chrome • web-javascript • Google Chrome 118.0.5993.117
! Error: Shekhar’s iPhone has recently restarted. Xcode will continue when Shekhar’s iPhone is unlocked. (code -14)

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

• No issues found!

Hi @ShekharEnvato,

Is this a duplicate of #480?

Hi @ShekharEnvato,

Is this a duplicate of #480?

@fuzzybinary Thanks Adding below lines to podfile fixed the crash issue.

if config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'].to_f < 12.0
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '12.0'
end