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

undefined method `exists?' for nil:NilClass when specifying git repo #335

Closed
itszero opened this issue Jun 14, 2012 · 6 comments
Closed

Comments

@itszero
Copy link

itszero commented Jun 14, 2012

Report

  • What did you do?

I add ShareKit as my dependency and specify its git repo for using latest revision.
If I remove the ShareKit line, everything is fine. If I don't specify the repo URL, it works.
and finally, if I change the Podspec file to make it use the latest commit, it works as well.

  • What did you expect to happen?

The latest version on the master branch of given repo of ShareKit being included.

  • What happened instead?

Error.

Stack

   CocoaPods : 0.6.0.rc2
        Ruby : ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-darwin11.3.0]
    RubyGems : 1.8.21
        Host : Mac OS X 10.7.4 (11E53)
       Xcode : 4.3.3 (4E3002)
Ruby lib dir : /Users/Zero/.rvm/rubies/ruby-1.9.3-p125/lib
Repositories : master - git://github.com/CocoaPods/Specs.git @ b271221cd87f60b509f02b3fc8b7f5b5a3c8d529

Podfile

platform :ios

dependency 'DTCoreText'
dependency 'AFNetworking'
dependency 'BlockAlertsAnd-ActionSheets'
dependency 'BlocksKit'
dependency 'EGOTableViewPullRefresh'
dependency 'JSONKit'
dependency 'Objective-C-HMTL-Parser'
dependency 'QuickDialog'
dependency 'SVProgressHUD'

dependency 'ShareKit', :git => 'https://github.com/ShareKit/ShareKit.git'

Error

undefined method `exists?' for nil:NilClass
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/dependency.rb:140:in `specification_from_sandbox'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/resolver.rb:44:in `find_cached_set'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/resolver.rb:60:in `block in find_dependency_specs'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/resolver.rb:58:in `each'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/resolver.rb:58:in `find_dependency_specs'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/resolver.rb:25:in `block in resolve'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/resolver.rb:22:in `each'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/resolver.rb:22:in `resolve'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/installer.rb:172:in `specs_by_target'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/installer.rb:81:in `install!'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/command/install.rb:53:in `run'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/lib/cocoapods/command.rb:69:in `run'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bundler/gems/CocoaPods-fd5c7045e3b6/bin/pod:12:in `<top (required)>'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bin/pod:19:in `load'
/Users/Zero/.rvm/gems/ruby-1.9.3-p125/bin/pod:19:in `<main>'
@fabiopelosin
Copy link
Member

The syntax that you used is reserved for repos that have a podspec in the root. You can use one of the options available in the wiki to use the head version of sharekit ShareKit.

@itszero
Copy link
Author

itszero commented Jun 14, 2012

Ah, right! Thanks for pointing out the overlooked point.

@itszero itszero closed this as completed Jun 14, 2012
@subdigital
Copy link
Contributor

@irrationalfab instead of closing this ticket, I think a better error message is in order in this case. Something like:

No pod spec found in the root of "http://github.com/ShareKit/ShareKit.git". You'll need to specify a custom pod spec path with the :podspec option.

What do you think?

@fabiopelosin
Copy link
Member

@subdigital I totally agree about the error message. Yet to keep things tidy in this cases I prefer to create a new ticket that describes the change and reference the original issue.

Btw, do you have any opinions about #336?

@subdigital
Copy link
Contributor

Cool, I'll submit a pull request shortly...

On Jun 14, 2012, at 11:56 AM, Fabio Pelosin wrote:

@subdigital I totally agree about the error message. Yet to keep things tidy in this cases I prefer to create a new ticket that describes the change and reference the original issue.

Btw, do you have any opinions about #336?


Reply to this email directly or view it on GitHub:
#335 (comment)

@fabiopelosin
Copy link
Member

Nice!

jzapater pushed a commit to jzapater/CocoaPods that referenced this issue Sep 17, 2013
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