Cocoapods: Xcode 11 Pod init crash

Created on 13 Jun 2019  路  8Comments  路  Source: CocoaPods/CocoaPods

Command

/usr/local/bin/pod init

Report

  • What did you do?

  • What did you expect to happen?

  • What happened instead?

Stack

   CocoaPods : 1.7.1
        Ruby : ruby 2.3.7p456 (2018-03-28 revision 63024) [universal.x86_64-darwin18]
    RubyGems : 2.5.2.3
        Host : Mac OS X 10.14.5 (18F132)
       Xcode : 10.2.1 (10E1001)
         Git : git version 2.20.1 (Apple Git-117)
Ruby lib dir : /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib
Repositories : master - https://github.com/CocoaPods/Specs.git @ bdf3762d3a979b09bcedb0fbd39db74eb3a0ab68
               mcom-tfs-defaultcollection-auckland_pd-_git-podspecs - http://auk-tfs.mcom.local:8080/tfs/DefaultCollection/Auckland_PD/_git/PodSpecs @ 4291889f607806b8ccec048518aa156fdfd38596
               nzlabs-tfs-defaultcollection-auckland_pd-_git-podspecs - http://auk-tfs.nzlabs.net:8080/tfs/DefaultCollection/Auckland_PD/_git/PodSpecs @ 4291889f607806b8ccec048518aa156fdfd38596
               nzlabs-tfs-defaultcollection-auckland_pd-_git-podspecs-1 - https://auk-tfs.nzlabs.net/tfs/DefaultCollection/Auckland_PD/_git/PodSpecs @ e4b28ed37556b75e67033e7dad9922fd19ce3cdf
               nzlabs-tfs-defaultcollection-auckland_pd-_git-podspecs-2 - https://auk-tfs.nzlabs.net/tfs/DefaultCollection/Auckland_PD/_git/PodSpecs/ @ e8b1782837f6707ebe91cae02052690b31d18ac6

Plugins

cocoapods-deintegrate : 1.0.4
cocoapods-plugins     : 1.0.0
cocoapods-search      : 1.0.0
cocoapods-stats       : 1.0.0
cocoapods-trunk       : 1.3.1
cocoapods-try         : 1.1.0

Error

RuntimeError - [Xcodeproj] Unknown object version.
/Library/Ruby/Gems/2.3.0/gems/xcodeproj-1.8.2/lib/xcodeproj/project.rb:227:in `initialize_from_file'
/Library/Ruby/Gems/2.3.0/gems/xcodeproj-1.8.2/lib/xcodeproj/project.rb:112:in `open'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.7.1/lib/cocoapods/command/init.rb:41:in `validate!'
/Library/Ruby/Gems/2.3.0/gems/claide-1.0.2/lib/claide/command.rb:333:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.7.1/lib/cocoapods/command.rb:52:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.7.1/bin/pod:55:in `<top (required)>'
/usr/local/bin/pod:22:in `load'
/usr/local/bin/pod:22:in `<main>'

Most helpful comment

gem update xcodeproj. Please see duplicate issues already filed in the repo.

All 8 comments

gem update xcodeproj. Please see duplicate issues already filed in the repo.

@dnkoutso still the same. I figure out that once install Swift Package Manager, then no longer can use cocoapod.

I do not understand what you mean...either way if SPM works then thats good news. Make sure xcodeproj gem is 1.10.x.

I cant using both at the same time. After I remove SPM, Pod is working.

Upload a sample then, if its reproduced I will re-open the issue.

gem update xcodeproj. Please see duplicate issues already filed in the repo.

this method function

sudo gem update xcodeproj

I just got this same error with XCode 11.3, macOS 10.15.2 and cocoapods 1.8.4 with no changes to my project, other than updating cocoapods. Issue #7697 has a workaround but it's not a permanent fix. Change the Project Format to Xcode 9.3 - compatible.

Was this page helpful?
0 / 5 - 0 ratings