Closed kinsersh closed 10 years ago
This error is because you have an older version of rubygems that does not support the .new method. Update your rubygems version and the push will work just fine.. ( I recommend rubygems 2.1.7 )
if i install rubygems-update on a 1.9.3 install with rvm, will it be patched?
gem update --system should do the right thing for you under rvm.. But, sometimes rvm does odd things. If you have trouble with that, grab the gem from rubygems.org and install it. (rubygems-update-2.1.7.gem)
Verified. Upgrading to a newer rubygems with 'gem update --system' worked with ruby 1.9.3.
Thanks for the help.
I've made #36 to fix this so it won't happen to others. Thanks @kinsersh for finding it and @breeves for helping out.
This worked just fine with the previous version of stickler (2.2.4). It looks like you're rescuing with a LoadError, but it's a NoMethodError that's being raised instead. Am I right to assume you want this to still work with version 1.9.3 for a while?
kinsersh@kinsersh-VirtualBox:~/sandbox/blueprint-deploy (inline-acceptance-test-mgr *)$ stickler push pkg/blueprint-deploy-0.0.409.gem --server http://myserver:6789 Pushing gem(s) to http://myserver:6789/ ... /home/kinsersh/sandbox/blueprint-deploy/pkg/blueprint-deploy-0.0.409.gem -> /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/gem_container.rb:26:in'
load_container': undefined method
new' for Gem::Package:Module (NoMethodError) from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/gem_container.rb:12:ininitialize' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/repository/remote.rb:279:in
new' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/repository/remote.rb:279:inspecification_from_gem_file' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/repository/remote.rb:275:in
speclite_from_gem_file' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/repository/remote.rb:82:inpush' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/client/push.rb:39:in
block in run' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/client/push.rb:35:ineach' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/lib/stickler/client/push.rb:35:in
run' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/gems/stickler-2.4.0/bin/stickler:47:in<top (required)>' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/bin/stickler:19:in
load' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/bin/stickler:19:in<main>' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/bin/ruby_noexec_wrapper:14:in
eval' from /home/kinsersh/.rvm/gems/ruby-1.9.3-p327/bin/ruby_noexec_wrapper:14:in `kinsersh@kinsersh-VirtualBox:~/sandbox/blueprint-deploy (inline-acceptance-test-mgr *)$ ruby -e 'puts RUBY_DESCRIPTION' ruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-linux]
kinsersh@kinsersh-VirtualBox:~/sandbox/blueprint-deploy (inline-acceptance-test-mgr *)$ cat /etc/issue Ubuntu 13.04 \n \l
kinsersh@kinsersh-VirtualBox:~/sandbox/blueprint-deploy (inline-acceptance-test-mgr *)$ ruby -rubygems -e "require 'stickler'; puts Stickler::VERSION" 2.4.0