flutter-intellij
flutter-intellij copied to clipboard
Can not terminate ios simulator app from android studio
I created a simple sample project to reproduce that. When I click on stop button to terminate the app it doesn't work. This is getting really annoying.
It throws below exception
Error: Unable to terminate com.example.flutterTester1 on 10117A3A-781B-420D-A3C5-906C46E3392B:
ProcessException: Process exited abnormally with exit code -2:
Command: /usr/bin/arch -arm64e xcrun simctl terminate 10117A3A-781B-420D-A3C5-906C46E3392B com.example.flutterTester1
the Dart compiler exited unexpectedly.
Error waiting for a debug connection: The log reader failed unexpectedly
Error launching application on iPhone 16 Pro.
However, running the command in terminal does works
/usr/bin/arch -arm64e xcrun simctl terminate 10117A3A-781B-420D-A3C5-906C46E3392B com.example.flutterTester1
flutter doctor -v
[✓] Flutter (Channel stable, 3.32.0, on macOS 15.4.1 24E263 darwin-arm64, locale en-AU) [1,559ms]
• Flutter version 3.32.0 on channel stable at /Users/jayhuang/fvm/versions/3.32.0
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision be698c48a6 (7 days ago), 2025-05-19 12:59:14 -0700
• Engine revision 1881800949
• Dart version 3.8.0
• DevTools version 2.45.1
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0) [3.1s]
• Android SDK at /Users/jayhuang/Library/Android/sdk
• Platform android-35, build-tools 34.0.0
• 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.5+-13047016-b750.29)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 16.2) [2.2s]
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 16C5032a
• CocoaPods version 1.16.2
[✓] Chrome - develop for the web [38ms]
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2024.2) [37ms]
• 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.5+-13047016-b750.29)
[✓] IntelliJ IDEA Ultimate Edition (version 2025.1.1.1) [35ms]
• IntelliJ at /Applications/IntelliJ IDEA.app
• 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
[✓] VS Code (version 1.100.1) [10ms]
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.50.0
[✓] Connected device (4 available) [7.4s]
• sdk gphone64 arm64 (mobile) • emulator-5554 • android-arm64 • Android 16 (API 36) (emulator)
• iPhone 16 Pro (mobile) • 10117A3A-781B-420D-A3C5-906C46E3392B • ios • com.apple.CoreSimulator.SimRuntime.iOS-18-0 (simulator)
• macOS (desktop) • macos • darwin-arm64 • macOS 15.4.1 24E263 darwin-arm64
• Chrome (web) • chrome • web-javascript • Google Chrome 136.0.7103.114
[✓] Network resources [513ms]
• All expected network resources are available.
• No issues found!
similar problem here:
Error: Unable to terminate com.flutter.testApp2 on 3519108D-6587-407A-84E9-2486A911E592:
ProcessException: Process exited abnormally with exit code -2:
Command: xcrun simctl terminate 3519108D-6587-407A-84E9-2486A911E592 com.obsisoft.testApp2
the Dart compiler exited unexpectedly.
flutter doctor -v
[✓] Flutter (Channel stable, 3.24.5, on macOS 14.7.4 23H420 darwin-x64, locale
it-IT)
• Flutter version 3.24.5 on channel stable at
/Users/luca/fvm/versions/3.24.5
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision dec2ee5c1f (7 months ago), 2024-11-13 11:13:06 -0800
• Engine revision a18df97ca5
• Dart version 3.5.4
• DevTools version 2.37.3
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
• Android SDK at /Users/luca/Library/Android/sdk
• Platform android-35, build-tools 34.0.0
• Java binary at: /Applications/Android
Studio.app/Contents/jbr/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 21.0.3+-79915915-b509.11)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 16.2)
• Xcode at /Applications/xCode_16.2.0/Xcode.app/Contents/Developer
• Build 16C5032a
• CocoaPods version 1.16.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+-79915915-b509.11)
[✓] VS Code (version 1.100.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.110.0
Visual Studio Code stops the iOS app without problems.