iosflutterxcodecocoapods

xcode 15 Uncategorized (Xcode): Command CodeSign failed with a nonzero exit code


I updated my xcode to 15.4 Im running flutter run on iphone 15 pro simulator pod --version is 1.15.2 In my PodFile I added

post_install do |installer|
  installer.pods_project.targets.each do |target|
     flutter_additional_ios_build_settings(target)
      target.build_configurations.each do |config|
        xcconfig_path = config.base_configuration_reference.real_path
        xcconfig = File.read(xcconfig_path)
        xcconfig_mod = xcconfig.gsub(/DT_TOOLCHAIN_DIR/, "TOOLCHAIN_DIR")
        File.open(xcconfig_path, "w") { |file| file << xcconfig_mod }
      end
  end
end

the error I see

Uncategorized (Xcode): Command CodeSign failed with a nonzero exit code

Solution

  • None of the solutions above solved my problem. What happened was that when I upgraded my Mac and Xcode versions, the Flutter project folder on my desktop was saved to iCloud Drive. Disabling the sync with iCloud solved the problem, and all the errors disappeared.