当我尝试在模拟器上运行fluter应用程序时,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有关的问题。
2条答案
按热度按时间4ioopgfo1#
这是授权问题。请在“终端”中尝试以下操作:
hts6caw32#
在我的例子中,即使我没有在Rosetta下运行它,我也必须安装它。为此,运行以下脚本:
softwareupdate --install-rosetta
如果要跳过许可协议,请执行以下操作:
/usr/sbin/softwareupdate --install-rosetta --agree-to-license