Rake Release Doesn't Work

I am trying to release a new version of my gem running this command:

rake release --trace

but the process is stuck here:

 rake release --trace ** Invoke load_app (first_time) ** Execute load_app ** Invoke release (first_time) ** Invoke build (first_time) ** Execute build paperclip_upload 1.2.0 built to pkg/paperclip_upload-1.2.0.gem. ** Invoke release:guard_clean (first_time) ** Execute release:guard_clean ** Invoke release:source_control_push (first_time) ** Execute release:source_control_push Tag v1.2.0 has already been created. ** Invoke release:rubygem_push (first_time) ** Execute release:rubygem_push 

Things I tried and didn't work:

  • Remove the github tag and release again.
  • Update gem to the latest version (2.4.8) by running gem update --system .
  • Reset my rubygems API key.
  • Use api. curl --data-binary @pkg/paperclip_upload-1.2.0.gem -H 'Authorization:XXX' https://rubygems.org/api/v1/gems

    POST does not work, but I can restore my gems by doing a GET.

  • Use gems

     require 'rubygems' require 'gems' Gems.configure do |config| config.username = 'xxx' config.password = 'xxx' end Gems.push(File.new("pkg/paperclip_upload-1.2.0.gem")) 
  • Avoid using the rake command that does gem build and then gem push -v pkg/paperclip_upload-1.2.0.gem , but also gets stuck:

     gem push -v pkg/paperclip_upload-1.2.0.gem GET https://rubygems.org/latest_specs.4.8.gz 302 Moved Temporarily GET https://s3.amazonaws.com/production.s3.rubygems.org/latest_specs.4.8.gz 304 Not Modified GET http://rubygems.org/latest_specs.4.8.gz 302 Moved Temporarily GET http://production.s3.rubygems.org/latest_specs.4.8.gz 200 OK GET http://rubygems.org/quick/Marshal.4.8/rubygems-update-2.4.8.gemspec.rz 302 Moved Temporarily GET http://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/rubygems-update-2.4.8.gemspec.rz 200 OK Pushing gem to http://rubygems.org/... POST http://rubygems.org//api/v1/gems connection reset after 1 requests, retrying POST http://rubygems.org//api/v1/gems connection reset after 1 requests, retrying ERROR: While executing gem ... (Gem::RemoteFetcher::FetchError) too many connection resets (http://rubygems.org//api/v1/gems) 

Any clue?

The RubyGems status page is all green to me.

+4
source share
2 answers

That was my problem. How to reduce the size of the gem.

Trying to send a stone with 585 MB of tmp garbage is not a good idea ...

0
source

For me, after enabling 2FA on Rubygems.org, I could no longer run the rake release .

release:rubygem_push step release:rubygem_push hung. It turns out that older versions of gem do not support 2FA , and in intermediate versions there was an error when the process was waiting for the 2FA code to be entered, but there was no request .

The solution for me was to enter the 2FA + return code when the process was waiting.

In the end, you can gem update --system to get a new version of gem with full 2FA support.

0
source

All Articles