Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

specification.rb:525 TypeError - no implicit conversion of nil into String #5184

Closed
itsthejb opened this issue Apr 21, 2016 · 6 comments
Closed

Comments

@itsthejb
Copy link

itsthejb commented Apr 21, 2016

Crash log attached

Command

/Users/jc/.rbenv/versions/2.2.4/bin/pod install

Report

pod install

Stack

   CocoaPods : 1.0.0.beta.8
        Ruby : ruby 2.2.4p230 (2015-12-16 revision 53155) [x86_64-darwin15]
    RubyGems : 2.4.5.1
        Host : Mac OS X 10.11.4 (15E65)
       Xcode : 7.3 (7D175)
         Git : git version 2.8.0
Ruby lib dir : /Users/jc/.rbenv/versions/2.2.4/lib
Repositories : eyeem - https://github.com/eyeem/CocoaPods-Specs.git @ e5d20deb9c06d8557bec7bb8659155ac41313f96
               master - https://github.com/CocoaPods/Specs.git @ 09ed33c662d3095f8ecb77f066a30c12dafed5f6

Plugins

cocoapods-deintegrate : 1.0.0.beta.1
cocoapods-plugins     : 1.0.0.beta.1
cocoapods-search      : 1.0.0.beta.2
cocoapods-stats       : 1.0.0.beta.4
cocoapods-trunk       : 1.0.0.beta.4
cocoapods-try         : 1.0.0.beta.4

Podfile

require 'fileutils'

project '<REDACTED>.xcodeproj'
source 'https://github.com/eyeem/CocoaPods-Specs.git'
source 'https://github.com/CocoaPods/Specs.git'

use_frameworks!
inhibit_all_warnings!

# Soon-to-be-removed
abstract_target 'App' do
  platform :ios, '9.0'

  # Core Pods
  abstract_target 'CoreAbstract' do
    pod 'BNRCoreDataStack', '~> 1.1.5'
    pod 'CocoaLumberjack/Swift', '~> 2.2.0'
    pod 'HanekeSwift', '~> 0.10.1'
    pod 'PromiseKit/CorePromise', '~> 3.0.3'
    pod 'Result', '~> 1.0'
    pod 'SwiftlyLRU', :git => 'https://github.com/eyeem/SwiftlyLRU', :branch => 'eyeem-modifications'
    pod 'TTTAttributedLabel', '~> 1.13.4'
    pod 'SwiftyJSON', '~> 2.3.1'
    pod 'SFGaugeView', '~> 0.0.7'
    pod 'ReachabilitySwift', '~> 2.3.3'
    pod 'SwiftyUserDefaults', '~> 2.0.0'
    ['Standard', '+Photos'].each { |spec|
      pod 'Operations/' + spec, :git => 'git@github.com:eyeem/Operations.git', :commit => 'dc19369'
    }

    target 'Core' do
      pod 'Crashlytics', '~> 3.7.0'
      pod 'Fabric', '~> 1.6.0'
    end

    target 'Benchmarking'
    target 'Onboarding'

    # Run Target Pods
    abstract_target 'RunTargets' do
      pod 'Swinject', '~> 1.1.0'

      target '<REDACTED>' do
        pod 'SnapKit', '0.19.1'
        pod 'SwiftHEXColors', '~> 1.0.2'
        pod 'Changeset', '~> 1.0.4'
        pod 'FBSDKCoreKit', '~> 4.10.1'
      end

      # Testing-only pods
      abstract_target 'Testing' do
        pod 'Nimble', '~> 4.0.0'
        pod 'Quick', '~> 0.9.2'
        pod 'Nimble-Snapshots', '~> 4.0.1'

        target '<REDACTED>Tests'
        target 'CoreTests'
      end
    end
  end
end

# No Pods
abstract_target 'Support' do
  platform :osx, '10.10'
  target 'StoreSeeder'
end

# Post Install

TESTABILITY_PODS = ["Operations"].freeze

post_install do |i|
  # Insert acknowldegements
  TARGET="Pods-App-CoreAbstract-RunTargets-<REDACTED>"
  FileUtils.cp_r("Pods/Target Support Files/#{TARGET}/#{TARGET}-Acknowledgements.plist", "<REDACTED>/Settings.bundle/Acknowledgements.plist", :remove_destination => true)

  # Pod process
  i.pods_project.targets.each do |t|
    t.build_configurations.each do |c|
      c.build_settings['EXPANDED_CODE_SIGN_IDENTITY'] = ""
      c.build_settings['CODE_SIGNING_REQUIRED'] = "NO"
      c.build_settings['CODE_SIGNING_ALLOWED'] = "NO"

      # Private module map workaround
      # https://github.com/facebook/ios-snapshot-test-case/pull/141
      c.build_settings['WARNING_CFLAGS'] = '$(inherited) -Wno-error=private-header' if t.name == 'FBSnapshotTestCase'
    end

    # These are pods we want to test in the test bundles
    if TESTABILITY_PODS.include? t.name
      t.build_configurations.each do |c|
        c.build_settings['ENABLE_TESTABILITY'] = "YES" if c.name == "Debug"
      end
    end
  end
end

Error

TypeError - no implicit conversion of nil into String
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-core-1.0.0.beta.8/lib/cocoapods-core/specification.rb:523:in `initialize'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-core-1.0.0.beta.8/lib/cocoapods-core/specification.rb:523:in `new'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-core-1.0.0.beta.8/lib/cocoapods-core/specification.rb:523:in `from_file'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-core-1.0.0.beta.8/lib/cocoapods-core/specification/set.rb:45:in `specification'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-core-1.0.0.beta.8/lib/cocoapods-core/source.rb:268:in `search'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-core-1.0.0.beta.8/lib/cocoapods-core/source/aggregate.rb:83:in `block in search'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-core-1.0.0.beta.8/lib/cocoapods-core/source/aggregate.rb:83:in `select'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-core-1.0.0.beta.8/lib/cocoapods-core/source/aggregate.rb:83:in `search'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:346:in `create_set_from_sources'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:316:in `find_cached_set'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:289:in `specifications_for_dependency'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:107:in `search_for'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:205:in `block in sort_dependencies'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:199:in `each'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:199:in `sort_by'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:199:in `sort_dependencies'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolution.rb:131:in `block (2 levels) in <class:Resolution>'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolution.rb:431:in `push_state_for_requirements'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolution.rb:423:in `require_nested_dependencies_for'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolution.rb:411:in `activate_spec'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolution.rb:376:in `attempt_to_activate_new_spec'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolution.rb:320:in `attempt_to_activate'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolution.rb:147:in `process_topmost_state'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolution.rb:72:in `resolve'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/molinillo-0.4.4/lib/molinillo/resolver.rb:42:in `resolve'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/resolver.rb:62:in `resolve'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/installer/analyzer.rb:563:in `block in resolve_dependencies'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/user_interface.rb:63:in `section'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/installer/analyzer.rb:561:in `resolve_dependencies'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/installer/analyzer.rb:76:in `analyze'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/installer.rb:227:in `analyze'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/installer.rb:151:in `block in resolve_dependencies'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/user_interface.rb:63:in `section'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/installer.rb:150:in `resolve_dependencies'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/installer.rb:114:in `install!'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/command/install.rb:37:in `run'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/claide-1.0.0.beta.3/lib/claide/command.rb:334:in `run'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/lib/cocoapods/command.rb:50:in `run'
/Users/jc/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/cocoapods-1.0.0.beta.8/bin/pod:44:in `<top (required)>'
/Users/jc/.rbenv/versions/2.2.4/bin/pod:23:in `load'
/Users/jc/.rbenv/versions/2.2.4/bin/pod:23:in `<main>'
@itsthejb
Copy link
Author

itsthejb commented Apr 21, 2016

Have tried reinstalling ruby 2.2.4 and all dependencies. Was working no problems with beta 6

@segiddins
Copy link
Member

I can't replicate the issue with the given Podfile

@itsthejb
Copy link
Author

itsthejb commented Apr 21, 2016

@segiddins Indeed, members of my team can't reproduce it either, and this is including re-cloning the project, reinstalling ruby, reinstalling all dependencies!... :blank_face:

@segiddins
Copy link
Member

Do you happen to have a case-sensitive file system?

@itsthejb
Copy link
Author

Fixed by deleting ~/.cocoapods and pod setup. If it's of interest, previously to this issue surfacing. I had deleted some specs on our private specs repo. Those specs had been previously used in the repo I was trying to install into (but deleted from the podfile a while earlier). Perhaps there's a small issue with that that might be worth investigating at some point?

@davidair
Copy link
Contributor

It looks like this will happen if the Specs directory contains an empty subdirectory. In that case, a source versions_by_name map will contain an entry with an empty array, causing highest_version_spec_path to be nil.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants