Skip to content

ArgumentError - Illformed requirement `" < 2.0, >= 1.0.1"` #1076

Closed
capnslipp opened this Issue May 28, 2013 · 2 comments

2 participants

@capnslipp

Report

  • What did you do?

    1. Set up podfile with a rubygems-style version requirement '>= 1.0.1', '< 2.0'
    2. pod install-ed it
    3. Staged the Podfile and Podfile.lock (my Pods/ dir is gitignored)
    4. Removed the Pods directory (as it would be missing in a freshly-cloned project)
    5. Ran pod install again

    Also tried cloning the repo (with Podfile and Podfile.lock but no Pods/) and running pod install, for sanity's sake. Same crash.

  • What did you expect to happen?

    All the pods to be installed again, just as they had prior to the Podfile.lock's existence.

  • What happened instead?

    Crash bang boom. And then settled for ~> 1.0.

Stack

   CocoaPods : 0.20.2
        Ruby : ruby 1.9.3p327 (2012-11-10) [x86_64-darwin12.2.0]
    RubyGems : 1.8.25
        Host : Mac OS X 10.8.3 (12D78)
       Xcode : 4.6.2 (4H1003)
Ruby lib dir : /Volumes/UserDrive/Users/slippyd/.rvm/rubies/ruby-1.9.3-p327/lib
Repositories : master - https://github.com/CocoaPods/Specs.git @ 003ae9603458475da09adfc4affdeb3577d7790b

Podfile

platform :ios, '5.0'
pod 'SVSegmentedControl.deARCed'
pod 'FontAwesomeIconFactory', '>= 1.0.1', '< 2.0'

Podfile.lock (quite relevant to this issue!)

PODS:
  - FontAwesomeIconFactory (1.1)
  - SVSegmentedControl.deARCed (0.2)

DEPENDENCIES:
  - FontAwesomeIconFactory (< 2.0, >= 1.0.1)
  - SVSegmentedControl.deARCed

SPEC CHECKSUMS:
  FontAwesomeIconFactory: cc484a5a3ca304e44d1cd6a30d84de55958fd4f7
  SVSegmentedControl.deARCed: 14467f1dd7bf91ed76b96615f1d35c3d19a2f353

COCOAPODS: 0.20.2

Error

ArgumentError - Illformed requirement `" < 2.0, >= 1.0.1"`
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/requirement.rb:63:in `parse'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/vendor/requirement.rb:108:in `block in initialize'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/vendor/requirement.rb:108:in `map!'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/vendor/requirement.rb:108:in `initialize'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/requirement.rb:34:in `new'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/requirement.rb:34:in `create'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/dependency.rb:91:in `initialize'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/dependency.rb:323:in `new'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/dependency.rb:323:in `from_string'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/lockfile.rb:117:in `block in dependencies'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/lockfile.rb:116:in `map'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/lockfile.rb:116:in `dependencies'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-core-0.20.2/lib/cocoapods-core/lockfile.rb:234:in `detect_changes_with_podfile'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/installer/analyzer.rb:132:in `block in generate_podfile_state'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/user_interface.rb:52:in `section'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/installer/analyzer.rb:131:in `generate_podfile_state'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/installer/analyzer.rb:51:in `analyze'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/installer.rb:167:in `analyze'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/installer.rb:92:in `block in resolve_dependencies'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/user_interface.rb:52:in `section'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/installer.rb:91:in `resolve_dependencies'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/installer.rb:84:in `install!'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/command/project.rb:38:in `run_install_with_update'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/command/project.rb:68:in `run'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/claide-0.3.2/lib/claide/command.rb:206:in `run'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/lib/cocoapods/command.rb:49:in `run'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/gems/cocoapods-0.20.2/bin/pod:19:in `<top (required)>'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/bin/pod:19:in `load'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/bin/pod:19:in `<main>'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/bin/ruby_noexec_wrapper:14:in `eval'
/Users/slippyd/.rvm/gems/ruby-1.9.3-p327/bin/ruby_noexec_wrapper:14:in `<main>'
@alloy
CocoaPods member
alloy commented May 29, 2013

That’s indeed a bug, this method does not respect multiple version requirements in the string.

Is this something you’ll want to create a patch for?

@capnslipp

Cool. Thanks, @irrationalfab !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.