Example app couldn't be executed.
Closed this issue · 1 comments
I tried to execute example app to copy main.dart in the example app to myapp I created by flutter create
. However, it crashes with following errors. It seems that there is some problem about plugins.
I also tried to replace ios
directory in the "example app" with myapp's, and it works well.
Here, I used the example app in the library I fetched (like /.symlinks/plugins/geofencing/example) bacause if I use the example app I cloned from github, I got an another error which is /build/ios/Debug-iphonesimulator/Runner.app/Frameworks/Flutter.framework: Permission denied
.
Xcode error output is this.
2019-11-04 17:45:53.974677+0900 Runner[98628:6930647] flutter: Observatory listening on http://127.0.0.1:61147/si91USLHVws=/
2019-11-04 17:45:54.539093+0900 Runner[98628:6930637] flutter: Initializing...
2019-11-04 17:45:55.203242+0900 Runner[98628:6930328] *** Assertion failure in -[GeofencingPlugin startGeofencingService:], /Users/yanyo/development/flutter/.pub-cache/hosted/pub.dartlang.org/geofencing-0.0.1/ios/Classes/GeofencingPlugin.m:168
2019-11-04 17:45:55.231958+0900 Runner[98628:6930328] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'failed to set registerPlugins'
*** First throw call stack:
(
0 CoreFoundation 0x00007fff23c4f02e __exceptionPreprocess + 350
1 libobjc.A.dylib 0x00007fff50b97b20 objc_exception_throw + 48
2 CoreFoundation 0x00007fff23c4eda8 +[NSException raise:format:arguments:] + 88
3 Foundation 0x00007fff256c9b61 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 191
4 geofencing 0x0000000106a5187f -[GeofencingPlugin startGeofencingService:] + 799
5 geofencing 0x0000000106a5001c -[GeofencingPlugin handleMethodCall:result:] + 652
6 Flutter 0x0000000104a6d4fd __45-[FlutterMethodChannel setMethodCallHandler:]_block_invoke + 104
7 Flutter 0x0000000104a06ec0 _ZNK7flutter21PlatformMessageRouter21HandlePlatformMessageEN3fml6RefPtrINS_15PlatformMessageEEE + 166
8 Flutter 0x0000000104a0a780 _ZN7flutter15PlatformViewIOS21HandlePlatformMessageEN3fml6RefPtrINS_15PlatformMessageEEE + 38
9 Flutter 0x0000000104a67db3 _ZNSt3__110__function6__funcIZN7flutter5Shell29OnEngineHandlePlatformMessageEN3fml6RefPtrINS2_15PlatformMessageEEEE4$_31NS_9allocatorIS8_EEFvvEEclEv + 57
10 Flutter 0x0000000104a193f1 _ZN3fml15MessageLoopImpl10FlushTasksENS_9FlushTypeE + 123
11 Flutter 0x0000000104a1e742 _ZN3fml17MessageLoopDarwin11OnTimerFireEP16__CFRunLoopTimerPS0_ + 26
12 CoreFoundation 0x00007fff23bb2944 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 20
13 CoreFoundation 0x00007fff23bb2632 __CFRunLoopDoTimer + 1026
14 CoreFoundation 0x00007fff23bb1c8a __CFRunLoopDoTimers + 266
15 CoreFoundation 0x00007fff23bac9fe __CFRunLoopRun + 2238
16 CoreFoundation 0x00007fff23babe16 CFRunLoopRunSpecific + 438
17 GraphicsServices 0x00007fff38438bb0 GSEventRunModal + 65
18 UIKitCore 0x00007fff4784fb68 UIApplicationMain + 1621
19 Runner 0x00000001046c60f8 main + 72
20 libdyld.dylib 0x00007fff51a1dc25 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)
Flutter doctor is this.
$ flutter doctor -v
[✓] Flutter (Channel stable, v1.9.1+hotfix.5, on Mac OS X 10.14.6 18G95, locale ja-JP)
• Flutter version 1.9.1+hotfix.5 at /Users/yanyo/development/flutter
• Framework revision 1aedbb1835 (3 weeks ago), 2019-10-17 08:37:27 -0700
• Engine revision b863200c37
• Dart version 2.5.0
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at /Users/yanyo/Library/Android/sdk
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-28, build-tools 28.0.3
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.2)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.2, Build version 11B52
• CocoaPods version 1.6.1
[!] Android Studio (version 3.5)
• Android Studio at /Applications/Android Studio.app/Contents
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
[✓] VS Code (version 1.39.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.6.0
[✓] Connected device (1 available)
• iPhone 11 Pro Max • 5D418355-E533-491B-8821-97DCA97BB049 • ios • com.apple.CoreSimulator.SimRuntime.iOS-13-2 (simulator)
! Doctor found issues in 1 category.
It looks like you're using a version of this plugin that someone else published on pub. Unfortunately, I can't support those. Your best bet it to pull this repository and reference it directly in your pubspec.yaml.