Rails : Could not find jwt-1.5.3 in any of the sources

I have been using Capistrano for a long time for this project. This time when I tried to deploy my latest changes I stumbled upon this issue. So I documented this.

 

(Backtrace restricted to imported tasks)
cap aborted!
SSHKit::Runner::ExecuteError: Exception while executing as user@mysite.com: bundle exit status: 7
bundle stdout: Could not find jwt-1.5.3 in any of the sources
bundle stderr: Regenerating ruby-2.2.1 wrappers........
Regenerating ruby-2.2.1 wrappers........
/usr/local/rvm/gems/ruby-2.2.1/gems/bundler-1.11.2/lib/bundler/vendor/thor/lib/thor/shell/basic.rb:356: warning: Insecure world writable dir /usr/local/rvm/gems/ruby-2.2.1/bin in PATH, mode 042777

SSHKit::Command::Failed: bundle exit status: 7
bundle stdout: Could not find jwt-1.5.3 in any of the sources
bundle stderr: Regenerating ruby-2.2.1 wrappers........
Regenerating ruby-2.2.1 wrappers........
/usr/local/rvm/gems/ruby-2.2.1/gems/bundler-1.11.2/lib/bundler/vendor/thor/lib/thor/shell/basic.rb:356: warning: Insecure world writable dir /usr/local/rvm/gems/ruby-2.2.1/bin in PATH, mode 042777

Tasks: TOP => deploy:updated => bundler:install
(See full trace by running task with --trace)
The deploy has failed with an error: Exception while executing as deployer@45.79.200.151: bundle exit status: 7
bundle stdout: Could not find jwt-1.5.3 in any of the sources
bundle stderr: Regenerating ruby-2.2.1 wrappers........

 

The reason is:

https://rubygems.org/gems/jwt/versions/1.5.3

jwt 1.5.3 is yanked because of some reasons. So 1.5.3 version isn’t in repository..!

How to solve

Delete your Gemfile.lock and

$ bundle install

update your remote repo and deploy again

Sources:

http://stackoverflow.com/a/36219627/3437900

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s