ERROR - Guard::RailsAssets failed to achieve its <start>, exception was (Rails 4/ zeus/guard)

青春壹個敷衍的年華 提交于 2020-02-07 17:14:02

问题


I am getting this error whenever I load Guard and I think it fails to precompile locally my assets due to this.

When I load guard with

$ guard

I get:

16:55:35 - ERROR - Guard::RailsAssets failed to achieve its <start>, exception was:
> [#6D5274147654] TypeError: can't modify immutable index
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/sprockets-2.12.3/lib/sprockets/index.rb:81:in `expire_index!'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/sprockets-2.12.3/lib/sprockets/base.rb:97:in `cache='
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@global/gems/guard-rails-assets-0.1.5/lib/guard/rails-assets/rails_runner.rb:34:in `boot_rails'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@global/gems/guard-rails-assets-0.1.5/lib/guard/rails-assets/rails_runner.rb:80:in `compile_assets'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@global/gems/guard-rails-assets-0.1.5/lib/guard/rails-assets.rb:33:in `compile_assets'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@global/gems/guard-rails-assets-0.1.5/lib/guard/rails-assets.rb:15:in `start'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:78:in `block in _supervise'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:75:in `catch'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:75:in `_supervise'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:20:in `block (2 levels) in run'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:136:in `block (3 levels) in _scoped_plugins'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:134:in `each'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:134:in `block (2 levels) in _scoped_plugins'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:133:in `catch'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:133:in `block in _scoped_plugins'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:130:in `each'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:130:in `_scoped_plugins'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:19:in `block in run'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/lumberjack-1.0.9/lib/lumberjack.rb:32:in `unit_of_work'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/runner.rb:18:in `run'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/commander.rb:25:in `start'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/cli.rb:112:in `start'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/aruba_adapter.rb:32:in `execute'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/lib/guard/aruba_adapter.rb:19:in `execute!'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/gems/guard-2.7.3/bin/guard:11:in `<top (required)>'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/bin/guard:23:in `load'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/bin/guard:23:in `<main>'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/bin/ruby_executable_hooks:15:in `eval'
> [#6D5274147654] /home/mathieu/.rvm/gems/ruby-2.0.0-p451@rails3tutorial2ndEd/bin/ruby_executable_hooks:15:in `<main>'
16:55:35 - INFO - Guard::RailsAssets has just been fired
16:55:37 - INFO - Guard is now watching at '/home/mathieu/rails_projects/my_app'

Anybody have an idea why?


回答1:


Known error, marked as closed by mistake: https://github.com/dnagir/guard-rails-assets/issues/19



来源:https://stackoverflow.com/questions/27591119/error-guardrailsassets-failed-to-achieve-its-start-exception-was-rails-4

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!