copiousfreetime / stickler

a tool to organize and maintain an internal gem distribution server
MIT License
143 stars 29 forks source link

Add support for Ruby 2.0 #28

Closed pitr closed 10 years ago

pitr commented 11 years ago
.bundle/gems/ruby/2.0.0/gems/stickler-2.3.0/lib/stickler/repository/local.rb:5:in `require': cannot load such file -- rubygems/format (LoadError)
from .bundle/gems/ruby/2.0.0/gems/stickler-2.3.0/lib/stickler/repository/local.rb:5:in `<top (required)>'
from .bundle/gems/ruby/2.0.0/gems/stickler-2.3.0/lib/stickler/repository.rb:9:in `require'
from .bundle/gems/ruby/2.0.0/gems/stickler-2.3.0/lib/stickler/repository.rb:9:in `<top (required)>'
from .bundle/gems/ruby/2.0.0/gems/stickler-2.3.0/lib/stickler.rb:12:in `require'
from .bundle/gems/ruby/2.0.0/gems/stickler-2.3.0/lib/stickler.rb:12:in `<top (required)>'
copiousfreetime commented 11 years ago

Yup, this looks like one of the updates with rubygems 2.0

http://blog.rubygems.org/2013/02/24/2.0.0-released.html

Merged Gem::Format into Gem::Package. Use Gem::Package.new instead of Gem::Format.from_file_by_path

mbasset commented 11 years ago

+1

I am having a very similar issue after the rubygem 2.0 update using stickler 2.3.0, gem 2.0.3, bundler 1.3.5, ruby 1.9.3p392.

/Users/matthew/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/rubygems/format.rb:62:in `from_io': private method `open' call
ed for Gem::Package:Class (NoMethodError)
        from /Users/matthew/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/rubygems/format.rb:46:in `block in from_file_by_path'
        from /Users/matthew/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/rubygems/format.rb:45:in `open'
        from /Users/matthew/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/rubygems/format.rb:45:in `from_file_by_path'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/gems/stickler-2.3.0/lib/stickler/repository/remote.rb:257:in `specification_from_gem_file'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/gems/stickler-2.3.0/lib/stickler/repository/remote.rb:253:in `speclite_from_gem_file'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/gems/stickler-2.3.0/lib/stickler/repository/remote.rb:75:in `push'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/gems/stickler-2.3.0/lib/stickler/client/push.rb:39:in `block in run'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/gems/stickler-2.3.0/lib/stickler/client/push.rb:35:in `each'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/gems/stickler-2.3.0/lib/stickler/client/push.rb:35:in `run'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/gems/stickler-2.3.0/bin/stickler:46:in `'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/bin/stickler:23:in `load'
        from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/bin/stickler:23:in `
' from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in `eval' from /Users/matthew/.rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in `
'
copiousfreetime commented 11 years ago

Thanks for the reminder ;-). I'll take care of this this week.

mbasset commented 11 years ago

Incase anyone is wondering I have an alpha release that appears to work at least in a basic fashion for ruby 2.0.0 hacked together in about 5 mins. Not really pull request worthy though but should be enough to push using stickler with ruby 2.0.0 for now. https://github.com/mbasset/stickler

copiousfreetime commented 11 years ago

I haven't forgotten about this, working on it now. And it will go into the next version

copiousfreetime commented 10 years ago

Version 2.4 released, and includes this fix.