简体   繁体   中英

Rails - Heroku Migration error

I just did a migration on localhost and it worked fine. After pushing to heroku, I ran heroku run rake db:migrate and I get the following error stream...

c:/Program Files (x86)/Heroku/ruby-1.9.3/lib/ruby/site_ruby/1.9.1/rubygems/custo
m_require.rb:36:in require': cannot load such file -- ffi (LoadError)
from c:/Program Files (x86)/Heroku/ruby-1.9.3/lib/ruby/site_ruby/1.9.1/r
ubygems/custom_require.rb:36:inrequire'
from C:/Users/amoosa/.heroku/client/vendor/gems/rest-client-1.8.0/lib/re
stclient/windows/root_certs.rb:2:in <top (required)>'
from C:/Users/amoosa/.heroku/client/vendor/gems/rest-client-1.8.0/lib/re
stclient/windows.rb:7:inrequire_relative'

...more lines of similar errors.

How do I fix this? I'm on Windows/Ruby 2.0/Rails 4.0

I've run many migrations in the past year on this project and haven't seen this issue before.

I think your heroku tool-belt installation is broken.

Maybe you updated your computer or ruby version and some files were removed.

It looks like the heroku command is trying to load some of it's ruby files from your local directory and finds that a file it requires is missing.

the file missing is the local file referenced in line 36 of the file: c:/Program Files (x86)/Heroku/ruby-1.9.3/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb

I recommend re-installing the heroku tool-belt and retrying.

I may be wrong... but that's what I read in the log.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM