尝试在heroku中部署时出错

时间:2018-06-03 19:43:45

标签: ruby heroku

尝试在heroku中部署时出错

remote:        ------------------------------
remote:        Bundle completed (48.81s)
remote:        Cleaning up the bundler cache.
remote: -----> Installing node-v8.10.0-linux-x64
remote: -----> Detecting rake tasks
remote: sh: 2: Syntax error: Unterminated quoted string
remote: sh: 2: Syntax error: Unterminated quoted string
remote:  !
remote:  !     Could not detect rake tasks
remote:  !     ensure you can run `$ bundle exec rake -P` against your app
remote:  !     and using the production group of your Gemfile.
remote:  !     rake aborted!
remote:  !     LoadError:     Can't load WDM!
remote:  !
remote:  !     WDM is not supported on your system. For a cross-platform alternative,
remote:  !     we recommend using Listen: http://github.com/guard/listen
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/wdm-0.1.1/lib/wdm.rb:4:in `rescue in <top (required)>'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/wdm-0.1.1/lib/wdm.rb:1:in `<top (required)>'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/bundler-1.15.2/lib/bundler/runtime.rb:82:in `require'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/bundler-1.15.2/lib/bundler/runtime.rb:82:in `block (2 levels) in require'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/bundler-1.15.2/lib/bundler/runtime.rb:77:in `each'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/bundler-1.15.2/lib/bundler/runtime.rb:77:in `block in require'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/bundler-1.15.2/lib/bundler/runtime.rb:66:in `each'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/bundler-1.15.2/lib/bundler/runtime.rb:66:in `require'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/bundler-1.15.2/lib/bundler.rb:108:in `require'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/config/application.rb:7:in `<top (required)>'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/Rakefile:4:in `require_relative'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/Rakefile:4:in `<top (required)>'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/rake_module.rb:29:in `load'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/rake_module.rb:29:in `load_rakefile'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/application.rb:703:in `raw_load_rakefile'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/application.rb:104:in `block in load_rakefile'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/application.rb:186:in `standard_exception_handling'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/application.rb:103:in `load_rakefile'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/application.rb:82:in `block in run'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/application.rb:186:in `standard_exception_handling'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/lib/rake/application.rb:80:in `run'
remote:  !     /tmp/build_23f08682e6a066ec3fbe1f3ee37ee97d/vendor/bundle/ruby/2.4.0/gems/rake-12.3.1/exe/rake:27:in `<top (required)>'
remote:  !     vendor/bundle/bin/rake:17:in `load'
remote:  !     vendor/bundle/bin/rake:17:in `<main>'
remote:  !
remote:  !     Caused by:
remote:  !     LoadError: cannot load such file -- wdm_ext

1 个答案:

答案 0 :(得分:0)

根据提供的描述,您似乎已经指定了wdm依赖项,因为您在Windows上开发应用程序,但在heroku(unix系统)上部署时无法找到相同的内容。

您是否在Gemfile中添加了以下内容?

platforms :mswin do 
  gem "wdm"
end

如果它存在于Gemfile中,则将其修改为下面提到的:

platforms :mswin do 
  gem "wdm", :group => [:development]
end

然后将其添加到git并尝试在heroku上部署。