当 运行 在较旧的 iOS 模拟器上时,错误 "Failed to start launchd_sim: could not bind to session, launchd_sim may have crashed or quit responding"

When running on older iOS Simulator, error "Failed to start launchd_sim: could not bind to session, launchd_sim may have crashed or quit responding"

我在我的 M1 MacBook Pro 上 运行ning Xcode 12.2 (12B45b)。每当我尝试 运行 旧版 iOS 上的模拟器时,例如:

没用。 Xcode 弹出这个错误:

当我按下 详细信息 时,会弹出一个屏幕显示:

Details

Failed to start launchd_sim: could not bind to session, launchd_sim may have crashed or quit responding
Domain: com.apple.SimLaunchHostService.RequestError
Code: 4
--


System Information

macOS Version 11.0 (Build 20A2411)
Xcode 12.2 (17535) (Build 12B45b)
Timestamp: 2020-12-06T12:41:11-08:00

但是,如果我 运行 一个较新的 iOS 像 14.2,它工作得很好。这是预装 Xcode 的 运行 时间。

我看了这个问题,, but the answer is almost useless. Some other people have had the same problem on the Dev Forums,但也没有人有解决方案。

编辑: release notes 上似乎提到了 Xcode 12.2:

Simulator runtimes for iOS 13, tvOS 13, and watchOS 6 and earlier don’t work on the Developer Transition Kit. Preferences offers these runtimes for download, but creating a simulated device from one of these runtimes fails, claiming the runtime is unavailable. Other Macs with Apple silicon support a limited set of older simulator runtimes for iOS and tvOS. (66115743, 70472441) (FB8157217)

似乎已在 Big Sur 11.0.1!

中修复

附带说明一下,更新您的 M1 Mac 真的 快!真的花了 20 分钟。

请检查 permission.I 是否已通过 运行 在终端中执行以下命令

来解决问题
sudo chmod 1777 /tmp