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

Source type gem broken with rubygems version 2.x.x #378

Closed
r4um opened this Issue Mar 7, 2013 · 6 comments

Comments

Projects
None yet
2 participants
@r4um
Contributor

r4um commented Mar 7, 2013

$ gem --version
2.0.2
$ fpm -s gem -t rpm fpm
/usr/lib64/ruby/gems/1.8/gems/fpm-0.4.29/lib/fpm/package/gem.rb:77:in `download': undefined method `fetch' for #<Gem::SpecFetcher:0x7f422c1e4568> (NoMethodError)
    from /usr/lib64/ruby/gems/1.8/gems/fpm-0.4.29/lib/fpm/package/gem.rb:54:in `download_if_necessary'
    from /usr/lib64/ruby/gems/1.8/gems/fpm-0.4.29/lib/fpm/package/gem.rb:41:in `input'
    from /usr/lib64/ruby/gems/1.8/gems/fpm-0.4.29/lib/fpm/command.rb:316:in `execute'
    from /usr/lib64/ruby/gems/1.8/gems/fpm-0.4.29/lib/fpm/command.rb:315:in `each'
    from /usr/lib64/ruby/gems/1.8/gems/fpm-0.4.29/lib/fpm/command.rb:315:in `execute'
    from /usr/lib64/ruby/gems/1.8/gems/clamp-0.3.1/lib/clamp/command.rb:64:in `run'
    from /usr/lib64/ruby/gems/1.8/gems/clamp-0.3.1/lib/clamp/command.rb:126:in `run'
    from /usr/lib64/ruby/gems/1.8/gems/fpm-0.4.29/bin/fpm:8
    from /usr/bin/fpm:23:in `load'
    from /usr/bin/fpm:23

Came to light via #371

@jordansissel

This comment has been minimized.

Owner

jordansissel commented Mar 7, 2013

I gave up waiting for the rubygem api docs to load - http://rubydoc.org/gems/rubygems-update

@jordansissel

This comment has been minimized.

Owner

jordansissel commented Mar 7, 2013

Will try reaching out to anyone who understands the new rubygems 2.0.0 internals; I had a peak, but frankly I'm sleepy so I'm going to go resolve that problem instead ;)

@r4um

This comment has been minimized.

Contributor

r4um commented Mar 7, 2013

:), probably time to revisit #233.

@jordansissel

This comment has been minimized.

Owner

jordansissel commented Mar 22, 2013

Still broken as of fpm 0.4.31.

  • ruby 2.0.0 works now (fixed rpm support)
  • rubygems 2.x.x doesn't (still broken gem support under this rubygems version)
@r4um

This comment has been minimized.

Contributor

r4um commented Mar 22, 2013

Looked at just using gem external command, some of the caveats/observations.

  • Downloading with gem fetch works fine, though it downloads it in current directory.
  • Download in directory $(gem env gemdir)/cache.
  • If a version was given make sure we pick up the gem file with intended version.
  • Invoke gem spec on downloaded gem and read its output.

Problem is, currently there is no way to read stdout/stderr from external commands via safesystem (?).

@r4um

This comment has been minimized.

Contributor

r4um commented Mar 22, 2013

Never mind no need to change safesystem.

prof-milki pushed a commit to prof-milki/xpm that referenced this issue Dec 18, 2014

prof-milki pushed a commit to prof-milki/xpm that referenced this issue Dec 27, 2014

jordansissel added a commit that referenced this issue Apr 24, 2015

Merge pull request #389 from r4um/use_gem_cmd
Close #378, #233 Use gem command to download gem and spec.

jordansissel added a commit that referenced this issue Jun 20, 2016

Merge pull request #389 from r4um/use_gem_cmd
Close #378, #233 Use gem command to download gem and spec.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment