首页 > 解决方案 > Flutter 项目未在 IOS 模拟器上启动

问题描述

当我尝试在我的 oOS 模拟器(版本 14.5)上启动默认 Flutter 应用程序时,我收到一条错误消息:

“跑步者意外退出”

我将问题详细信息和系统配置报告附在这篇文章的底部。有没有其他人有这个问题或知道如何解决它?我试过擦除模拟器并创建一个全新的 Flutter 项目,但都没有成功。


CrashReporter Key:   IDK if this is sensitive but I'm redacting it
Hardware Model:      Macmini9,1
Process:             Runner [22475]
Path:                /Users/USER/Library/Developer/CoreSimulator/Devices/85498A85-DCD0-4FB9-82EE-794AE9FDBD1D/data/Containers/Bundle/Application/447DA17F-A27F-4676-980A-20CACFEBC45C/Runner.app/Runner
Identifier:          com.example.flutterCompleteGuide
Version:             1.0.0 (1)
Code Type:           X86-64 (Native)
Role:                Foreground
Parent Process:      launchd_sim [22063]
Coalition:           com.apple.CoreSimulator.SimDevice.85498A85-DCD0-4FB9-82EE-794AE9FDBD1D [5919]
Responsible Process: SimulatorTrampoline [2216]

Date/Time:           2021-06-15 10:42:55.3798 -0400
Launch Time:         2021-06-15 10:42:54.4896 -0400
OS Version:          macOS 12.0 (21A5248p)
Release Type:        User
Report Version:      104

Exception Type:  EXC_BAD_ACCESS (SIGSEGV)
Exception Subtype: KERN_INVALID_ADDRESS at 0x0000000000000000
VM Region Info: 0 is not in any region.  Bytes before following region: 4298858496
      REGION TYPE                    START - END         [ VSIZE] PRT/MAX SHRMOD  REGION DETAIL
      UNUSED SPACE AT START
--->  
      mapped file                 1003b6000-1003ba000    [   16K] r-x/r-x SM=COW  ...t_id=4c916b85
Exception Note:  EXC_CORPSE_NOTIFY
Termination Reason: SIGNAL 11 Segmentation fault: 11
Terminating Process: exc handler [22475]

Triggered by Thread:  0

Application Specific Information:



Thread 0 Crashed:
0   ???                                 0x7ff7fff2bbd8 ???
1   <translation info unavailable>         0x1003eae5c ???
2   dyld                                   0x20051a88f dyld4::prepareSim(dyld4::RuntimeState&, char const*) + 890
3   dyld                                   0x2005196b5 dyld4::prepare(dyld4::APIs&, dyld3::MachOAnalyzer const*) + 244
4   dyld                                   0x2005194b4 start + 388
5   dyld                                   0x200514000 ???

Thread 1:: com.apple.rosetta.exceptionserver
0   ???                                 0x7ff7fff18320 ???
1   ???                                 0x7ff7fff311a0 ???


Thread 0 crashed with X86 Thread State (64-bit):
  rax: 0x0000000000000000  rbx: 0x0000000108441af8  rcx: 0x0000000000000000  rdx: 0x0000000000000001
  rdi: 0x0000000000000000  rsi: 0x0000000000000000  rbp: 0x0000000000000000  rsp: 0x0000000108ade000
   r8: 0x9894d64da077006c   r9: 0x0000000000000000  r10: 0x0000000108ade000  r11: 0x0000000108901010
  r12: 0x0000000000000000  r13: 0x0000000108901060  r14: 0x0000000200588080  r15: 0x0000000000000000
  rip: <unavailable>       rfl: 0x0000000000000283
 tmp0: 0x00000001003d8c64 tmp1: 0x00000001003d7f8c tmp2: 0x0000000200532ca3


Binary Images:
               0x0 - 0xffffffffffffffff ??? (*) <00000000-0000-0000-0000-000000000000> ???
       0x200514000 -        0x20057bfff dyld (*) <4e207376-cc5d-3986-a0bd-4d09f4217e68> /usr/lib/dyld

EOF

Model: Macmini9,1, BootROM 7429.0.72.0.3, proc 8:4:4 processors, 8 GB, SMC 
Graphics: kHW_AppleM1Item, Apple M1, spdisplays_builtin
Memory Module: LPDDR4
AirPort: spairport_wireless_card_type_wifi, wl0: May  4 2021 18:24:35 version 18.20.281.2.7.8.107 FWID 01-7c11bd60
Bluetooth: Version (null), 0 services, 0 devices, 0 incoming serial ports
Network Service: Ethernet, Ethernet, en0
Network Service: Wi-Fi, AirPort, en1
USB Device: USB 3.1 Bus
USB Device: USB 3.1 Bus
USB Device: USB 3.0 Bus
USB Device: webcam
USB Device: Dell USB Entry Keyboard
Thunderbolt Bus: Mac mini, Apple Inc.
Thunderbolt Bus: Mac mini, Apple Inc.```

标签: macosflutterdartios-simulator

解决方案


我认为这个问题的原因是您在看到崩溃报告后使用的 macOS Monterey (macOS 12.0)。

我最近刚刚安装了新的 Beta 版(也在 M1 上),很遗憾现在遇到了同样的问题。也许他们会在下一次更新中修复它,这应该会在接下来的几天/几周内发布。


推荐阅读