Carte icon indicating copy to clipboard operation
Carte copied to clipboard

`uuid_with_name': uninitialized constant ProjectIntegrator::Digest (NameError)

Open matthiasotto opened this issue 7 years ago • 4 comments

The post_install is resulting in an error on my machine:

post_install do |installer|
    pods_dir = File.dirname(installer.pods_project.path)
    at_exit { `ruby #{pods_dir}/Carte/Sources/Carte/carte.rb configure` }
end
MBP17:app motto$ pod install
Analyzing dependencies
Downloading dependencies
Using Carte (2.1.6)
[...]
Generating Pods project
Integrating client project
Sending stats
Pod installation complete! There are 6 dependencies from the Podfile and 10 total pods installed.

Traceback (most recent call last):
	6: from /Users/motto/git/dw/ios/app/Pods/Carte/Sources/Carte/carte.rb:152:in `<main>'
	5: from /Users/motto/git/dw/ios/app/Pods/Carte/Sources/Carte/carte.rb:129:in `run'
	4: from /Users/motto/git/dw/ios/app/Pods/Carte/Sources/Carte/carte.rb:17:in `integrate'
	3: from /Users/motto/git/dw/ios/app/Pods/Carte/Sources/Carte/carte.rb:17:in `each'
	2: from /Users/motto/git/dw/ios/app/Pods/Carte/Sources/Carte/carte.rb:24:in `block in integrate'
	1: from /Users/motto/git/dw/ios/app/Pods/Carte/Sources/Carte/carte.rb:52:in `new_script_phase'
/Users/motto/git/dw/ios/app/Pods/Carte/Sources/Carte/carte.rb:62:in `uuid_with_name': uninitialized constant ProjectIntegrator::Digest (NameError)

matthiasotto avatar Mar 06 '18 23:03 matthiasotto

I am not quite sure why the carte.rb script is required in the first place. https://github.com/vtourraine/AcknowList uses the existing Pods-MyApp-acknowledgements.plist which cocoaPods already generated anyways.

matthiasotto avatar Mar 07 '18 18:03 matthiasotto

@matthiasotto, Carte currently supports CocoaPods only but it aims to support multiple package managers. I'll find a better solution :)

Anyway, which version of CocoaPods and Xcodeproj are you using?

$ pod --version
1.4.0
$ xcodeproj --version
1.5.5

devxoul avatar Mar 12 '18 06:03 devxoul

Thank you for getting back to me. I am using:

$ pod --version
1.4.0
$ xcodeproj --version
1.5.6

matthiasotto avatar Mar 13 '18 22:03 matthiasotto

Hello, I think the issue is dependent on the Ruby version. When I tried using version 2.3.1, it succeeded. When I used 2.4.1, 2.5.0 version it failed.

$ rvm default ruby-2.3.1
Using /Users/user/.rvm/gems/ruby-2.3.1

$ ruby Pods/Carte/Sources/Carte/carte.rb configure
[Carte] Pre Script
[Carte] Post Script
[Carte] Pre Script
[Carte] Post Script
$ rvm default ruby-2.4.1
Using /Users/user/.rvm/gems/ruby-2.4.1

$ ruby Pods/Carte/Sources/Carte/carte.rb configure
/Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- xcodeproj (LoadError)
	from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
	from Pods/Carte/Sources/Carte/carte.rb:5:in `<main>'
$ rvm default ruby-2.5.0
Using /Users/user/.rvm/gems/ruby-2.5.0

$ ruby Pods/Carte/Sources/Carte/carb configure
[Carte] Pre Script
Traceback (most recent call last):
	6: from Pods/Carte/Sources/Carte/carte.rb:153:in `<main>'
	5: from Pods/Carte/Sources/Carte/carte.rb:130:in `run'
	4: from Pods/Carte/Sources/Carte/carte.rb:17:in `integrate'
	3: from Pods/Carte/Sources/Carte/carte.rb:17:in `each'
	2: from Pods/Carte/Sources/Carte/carte.rb:24:in `block in integrate'
	1: from Pods/Carte/Sources/Carte/carte.rb:53:in `new_script_phase'
Pods/Carte/Sources/Carte/carte.rb:63:in `uuid_with_name': uninitialized constant ProjectIntegrator::Digest (NameError)

kjisoo avatar Apr 10 '18 02:04 kjisoo