ios - 构建成功后,应用程序启动没有返回有效的对,也没有在 Xcode 上返回启动错误

标签 ios xcode flutter dart

当我尝试在模拟器上运行 flutter 应用程序时,Xcode 出现问题。

构建进行 build succeed但随后出现一个弹出窗口,显示 Application launch for 'com.<My-app>' did not return a valid pid nor a launch error. No such process .

在此错误之前,我遇到了另一个错误 Flutter version unknown我用这个命令 xcode-select --install 解决了它.

这些是错误详细信息:

Details

Application launch for 'com.<My-app>' did not return a valid pid nor a launch error.
Domain: NSPOSIXErrorDomain
Code: 3
Failure Reason: No such process
User Info: {
    DVTErrorCreationDateKey = "2022-03-11 07:56:32 +0000";
    IDERunOperationFailingWorker = IDELaunchiPhoneSimulatorLauncher;
}
--

Analytics Event: com.apple.dt.IDERunOperationWorkerFinished : {
    "device_model" = "iPhone14,5";
    "device_osBuild" = "15.2 (19C51)";
    "device_platform" = "com.apple.platform.iphonesimulator";
    "launchSession_schemeCommand" = Run;
    "launchSession_state" = 1;
    "launchSession_targetArch" = arm64;
    "operation_duration_ms" = 232;
    "operation_errorCode" = 3;
    "operation_errorDomain" = NSPOSIXErrorDomain;
    "operation_errorWorker" = IDELaunchiPhoneSimulatorLauncher;
    "operation_name" = IDERunOperationWorkerGroup;
    "param_consoleMode" = 0;
    "param_debugger_attachToExtensions" = 0;
    "param_debugger_attachToXPC" = 0;
    "param_debugger_type" = 1;
    "param_destination_isProxy" = 0;
    "param_destination_platform" = "com.apple.platform.iphonesimulator";
    "param_diag_MainThreadChecker_stopOnIssue" = 0;
    "param_diag_MallocStackLogging_enableDuringAttach" = 0;
    "param_diag_MallocStackLogging_enableForXPC" = 1;
    "param_diag_allowLocationSimulation" = 1;
    "param_diag_gpu_frameCapture_enable" = 0;
    "param_diag_gpu_shaderValidation_enable" = 0;
    "param_diag_gpu_validation_enable" = 0;
    "param_diag_memoryGraphOnResourceException" = 0;
    "param_diag_queueDebugging_enable" = 0;
    "param_diag_runtimeProfile_generate" = 0;
    "param_diag_sanitizer_asan_enable" = 0;
    "param_diag_sanitizer_tsan_enable" = 0;
    "param_diag_sanitizer_tsan_stopOnIssue" = 0;
    "param_diag_sanitizer_ubsan_stopOnIssue" = 0;
    "param_diag_showNonLocalizedStrings" = 0;
    "param_diag_viewDebugging_enabled" = 0;
    "param_diag_viewDebugging_insertDylibOnLaunch" = 1;
    "param_install_style" = 0;
    "param_launcher_UID" = 2;
    "param_launcher_allowDeviceSensorReplayData" = 0;
    "param_launcher_kind" = 0;
    "param_launcher_style" = 0;
    "param_launcher_substyle" = 0;
    "param_runnable_appExtensionHostRunMode" = 0;
    "param_runnable_productType" = "com.apple.product-type.application";
    "param_runnable_swiftVersion" = "5.5.2";
    "param_runnable_type" = 2;
    "param_testing_launchedForTesting" = 0;
    "param_testing_suppressSimulatorApp" = 0;
    "param_testing_usingCLI" = 0;
    "sdk_canonicalName" = "iphonesimulator15.2";
    "sdk_osVersion" = "15.2";
    "sdk_variant" = iphonesimulator;
}
--


System Information

macOS Version 12.2.1 (Build 21D62)
Xcode 13.2.1 (19586) (Build 13C100)
Timestamp: 2022-03-11T08:56:32+01:00

这个问题可能也与我之前遇到的错误有关(Flutter 版本未知),但这是一个与 git 相关的问题。

最佳答案

就我而言,即使我没有在 Rosetta 下运行它,我也必须安装它。为此,请运行此脚本:

softwareupdate --install-rosetta

如果您想跳过许可协议(protocol),请执行以下操作:

/usr/sbin/softwareupdate --install-rosetta --agree-to-license

关于ios - 构建成功后,应用程序启动没有返回有效的对,也没有在 Xcode 上返回启动错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/71435412/

相关文章:

ios - 如何移动 CGContextRef 上的图像

ios - 无法将文件夹从应用程序包复制到文档目录

flutter - 允许 GridView 重叠 SliverAppBar

dart - 如何访问 Set 的值

Objective-c:现在允许我创建一个类的实例

android - 软键盘中不显示下一步按钮

ios - 设备方向在标签栏应用程序中启动所有 View Controller

objective-c - 如何在幻灯片放映中优雅地转换图像?

xcode - 如何在  Watch 应用程序中圆化 WKInterfaceImage 的角?

ios - 使用随机坐标重复 UIAnimation