bundle exec rakeを実行したらSprocketsのWarningが表示される場合、Gemfileのバージョン指定で消えます。
エラーメッセージ
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
user@deploy:~/deploy/hoge RAILS_ENV=production bundle exec rails c DEPRECATION WARNING: Sprockets method `register_engine` is deprecated. Please register a mime type using `register_mime_type` then use `register_compressor` or `register_transformer`. https://github.com/rails/sprockets/blob/master/guides/extending_sprockets.md#supporting-all-versions-of-sprockets-in-processors (called from block in at /home/user/deploy/hoge/vendor/bundle/ruby/2.2.0/gems/slim-rails-3.0.1/lib/slim-rails.rb:12) DEPRECATION WARNING: Sprockets method `register_engine` is deprecated. Please register a mime type using `register_mime_type` then use `register_compressor` or `register_transformer`. https://github.com/rails/sprockets/blob/master/guides/extending_sprockets.md#supporting-all-versions-of-sprockets-in-processors (called from block (2 levels) in at /home/user/deploy/hoge/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.3/lib/sass/rails/railtie.rb:57) DEPRECATION WARNING: Sprockets method `register_engine` is deprecated. Please register a mime type using `register_mime_type` then use `register_compressor` or `register_transformer`. https://github.com/rails/sprockets/blob/master/guides/extending_sprockets.md#supporting-all-versions-of-sprockets-in-processors (called from block (2 levels) in at /home/user/deploy/hoge/vendor/bundle/ruby/2.2.0/gems/sass-rails-5.0.3/lib/sass/rails/railtie.rb:58) Loading production environment (Rails 4.2.3) irb(main):001:0> |
Gemfile
1 2 3 |
gem 'sass-rails', '~> 5.0' ↓ gem 'sass-rails', '~> 5.0.6' |