rails で小さなプロジェクトを作成し、requirejs-rails gem を追加しました。必要に応じてセットアップしましたが、assets:precompile の実行中に、requirejs-rails が JavaScript リソースをコンパイルしようとすると失敗します。しかし、奇妙なことに、assets:precompile はデバッグ モードで動作するようです。残念ながら、Heroku に適切にデプロイできるように、非デバッグ モードで実行する必要があります。以下は、エラーとスタック トレースです。誰でもこれに遭遇しましたか?さらに重要なことに、これに対する解決策はありますか?
/home/whyves/.rvm/rubies/ruby-2.1.2/bin/ruby -e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) /home/whyves/RubymineProjects/test2/bin/spring rake --trace assets:precompile
** Invoke assets:precompile (first_time)
** Invoke assets:environment (first_time)
** Execute assets:environment
** Invoke environment (first_time)
** Execute environment
** Invoke requirejs:precompile:external (first_time)
** Invoke requirejs:test_node (first_time)
** Execute requirejs:test_node
** Execute requirejs:precompile:external
/home/whyves/.rvm/rubies/ruby-2.1.2/bin/ruby rake --trace assets:precompile requirejs:precompile:all RAILS_ENV=production RAILS_GROUPS=assets --trace
/home/whyves/.rvm/rubies/ruby-2.1.2/bin/ruby: No such file or directory -- rake --trace assets:precompile (LoadError)
rake aborted!
Command failed with status (1): [/home/whyves/.rvm/rubies/ruby-2.1.2/bin/ru...]
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/file_utils.rb:54:in
create_shell_runner のブロック' /home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/file_utils.rb:45:in call'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/file_utils.rb:45:in
sh' /home/whyves/.rvm/gems /ruby-2.1.2/gems/rake-10.3.2/lib/rake/file_utils_ext.rb:37:in sh'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/file_utils.rb:82:in
ruby' /home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3. 2/lib/rake/file_utils_ext.rb:37:in ruby'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/requirejs-rails-0.9.3/lib/tasks/requirejs-rails_tasks.rake:19:in
ruby_rake_task' /home/whyves/.rvm/gems/ruby-2.1.2/gems/requirejs-rails-0.9.3/lib/tasks/requirejs-rails_tasks.rake :86:in block (3 levels) in <top (required)>'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:240:in
call' /home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:240:in block in execute'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:235:in
each' /home/whyves/.rvm /gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:235:invoke_with_call_chainexecute'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:179:in
のブロック内' /home/whyves/.rvm/rubies/ruby-2.1.2/lib/ ruby/2.1.0/monitor.rb:211:inmon_synchronize'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:172:in
invoke_with_call_chain' /home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:201:in block in invoke_prerequisites'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:199:in
each' /home/whyves/.rvm/gems/ruby -2.1.2/gems/rake-10.3.2/lib/rake/task.rb:199: invoke_prerequisites'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:178:in
invoke_with_call_chain'/home/whyves/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1 のブロック内。 0/monitor.rb:211:in mon_synchronize'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:172:in
invoke_with_call_chain' /home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/task.rb:165:in invoke'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/application.rb:150:in
invoke_task' /home /whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/application.rb:106:in block (2 levels) in top_level'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/application.rb:106:in
each' /home/whyves/.rvm/gems/ruby-2.1.2 /gems/rake-10.3.2/lib/rake/application.rb:106:in block in top_level'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/application.rb:115:in
run_with_threads' /home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/ application.rb:100:intop_level'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/application.rb:78:in
実行中のブロック' /home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/application.rb:176:standard_exception_handling'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/rake-10.3.2/lib/rake/application.rb:75:in
実行中' /home/whyves/RubymineProjects/test2/ bin/rake:8: in <top (required)>'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/dependencies.rb:241:in
load' /home/whyves/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/dependencies.rb:241 : in block in load'
/home/whyves/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/dependencies.rb:232:in
load_dependency' /home/whyves /.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/dependencies.rb:241:in load'
/home/whyves/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in
require' /home/whyves/.rvm/rubies/ruby-2.1.2/lib /ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in require'
-e:1:in
' タスク: TOP => assets:precompile => requirejs:precompile:external
プロセスは終了コード 1 で終了しました
`