dpl: Unable to deploy new gem with latest gems
Having pretty standard configuration:
language: ruby
rvm:
- 2.0.0
- 2.4.0
install:
- gem install bundler
- bundle install
- gem install rspec
- gem install coveralls
script: rspec
deploy:
provider: rubygems
api_key: $RUBYGEMS_API_KEY
gemspec: my-new-gem.gemspec
on:
tags: true
I couldn’t push new gem to RubyGems.org. Travis gave me following error:
/home/travis/.rvm/rubies/ruby-2.2.0/lib/ruby/2.2.0/json/common.rb:155:in `parse': 757: unexpected token at 'This rubygem could not be found.' (JSON::ParserError)
from /home/travis/.rvm/rubies/ruby-2.2.0/lib/ruby/2.2.0/json/common.rb:155:in `parse'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/gems-1.0.0/lib/gems/client.rb:27:in `info'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/gems-1.0.0/lib/gems.rb:17:in `method_missing'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/dpl-1.8.31/lib/dpl/provider/rubygems.rb:27:in `check_app'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/dpl-1.8.31/lib/dpl/provider.rb:135:in `block in deploy'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/dpl-1.8.31/lib/dpl/cli.rb:41:in `fold'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/dpl-1.8.31/lib/dpl/provider.rb:133:in `deploy'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/dpl-1.8.31/lib/dpl/cli.rb:32:in `run'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/dpl-1.8.31/lib/dpl/cli.rb:7:in `run'
from /home/travis/.rvm/gems/ruby-2.2.0/gems/dpl-1.8.31/bin/dpl:5:in `<top (required)>'
from /home/travis/.rvm/gems/ruby-2.2.0/bin/dpl:23:in `load'
from /home/travis/.rvm/gems/ruby-2.2.0/bin/dpl:23:in `<main>'
from /home/travis/.rvm/gems/ruby-2.2.0/bin/ruby_executable_hooks:15:in `eval'
from /home/travis/.rvm/gems/ruby-2.2.0/bin/ruby_executable_hooks:15:in `<main>'
Seems that problem is in updated dpl >= 1.8.30 which transitively includes gems-1.0.0.
When I used this deployment script, my problem was solved:
#!/bin/sh
yes y | gem uninstall dpl
yes y | gem uninstall gems
gem install gems -v 0.8.3
gem install dpl -v 1.8.27
dpl --provider=rubygems --api-key=$RUBY_GEMS_API_KEY --gemspec=./my-new-gem.gemspec
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 2
- Comments: 20 (11 by maintainers)
That did it, thanks a lot!
@emilienh
gembelongs underdeploy. https://github.com/Smartling/api-sdk-ruby/blob/6826175868e15d0f18d8eba4a64e78deffe4a034/.travis.yml#L3 Please review https://docs.travis-ci.com/user/deployment/rubygems#Gem-to-release.