[英]Flutter: The application's Info.plist does not contain CFBundleVersion
[英]XCode 13 - The application's Info.plist does not contain a valid CFBundleVersion
我正在尝试在 XCode 13 中启动一个旧的 ios 应用程序,但在构建失败后它一直给我这个错误:
Details
Failed to install the requested application
Domain: NSPOSIXErrorDomain
Code: 22
Failure Reason: The application's Info.plist does not contain a valid CFBundleVersion.
Recovery Suggestion: Ensure your bundle contains a valid CFBundleVersion.
User Info: {
IDERunOperationFailingWorker = IDELaunchiPhoneSimulatorLauncher;
bundleURL = "file:///Users/lukas/Library/Developer/Xcode/DerivedData/zidane-cugshiqqzwkexrgiylyvxcagbylt/Build/Products/Vedur_Dev-iphonesimulator/zidane.app/";
}
--
Analytics Event: com.apple.dt.IDERunOperationWorkerFinished : {
"device_model" = "iPhone10,4";
"device_osBuild" = "15.0 (19A339)";
"device_platform" = "com.apple.platform.iphonesimulator";
"launchSession_schemeCommand" = Run;
"launchSession_state" = 1;
"launchSession_targetArch" = "x86_64";
"operation_duration_ms" = 87;
"operation_errorCode" = 22;
"operation_errorDomain" = NSPOSIXErrorDomain;
"operation_errorWorker" = IDELaunchiPhoneSimulatorLauncher;
"operation_name" = IDERunOperationWorkerGroup;
"param_consoleMode" = 0;
"param_debugger_attachToExtensions" = 0;
"param_debugger_attachToXPC" = 1;
"param_debugger_type" = 3;
"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" = 1;
"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" = 1;
"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";
"param_runnable_type" = 2;
"param_testing_launchedForTesting" = 0;
"param_testing_suppressSimulatorApp" = 0;
"param_testing_usingCLI" = 0;
"sdk_canonicalName" = "iphonesimulator15.0";
"sdk_osVersion" = "15.0";
"sdk_variant" = iphonesimulator;
}
--
System Information
macOS Version 11.6 (Build 20G165)
Xcode 13.0 (19234) (Build 13A233)
Timestamp: 2021-10-06T08:33:19Z
我对 XCode 很陌生,所以我不确定该怎么做。 我检查了 Info.plist 并将我自己的内部版本号设置为 3。
我只是不知道什么是有效的构建版本以及在哪里可以找到它。 我见过类似的问题,其中缺少构建版本号,但没有任何关于构建版本无效的说法。
将 $(CURRENT_PROJECT_VERSION) 设置为 CFBundleVersion 的值是解决此问题的方法。
如果您的项目中有两个名为 Resources 的文件夹,也会发生这种情况。 这发生在我身上。 将 Resources 文件夹之一重命名为其他文件夹,解决了这个问题。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.