Rails 每次执行 Rails 的时候都有提示信息是什么意思

johnlu · 2013年07月31日 · 最后由 JohnLu 回复于 2013年08月18日 · 5620 次阅读

如执行rails generate integration_test authentication_pages

DEPRECATION WARNING: config.whiny_nils option is deprecated and no longer works. (called from block in <top (required)> at /home/johnlu/rails_projects/mysampleapp/config/environments/development.rb:10)
config.eager_load is set to nil. Please update your config/environments/*.rb files accordingly:

  * development - set it to false
  * test - set it to false (unless you use a tool that preloads your test environment)
  * production - set it to true

      invoke  rspec
DEPRECATION WARNING: Model based mass assignment security has been extracted
out of Rails into a gem. Please use the new recommended protection model for
params or add `protected_attributes` to your Gemfile to use the old one.

To disable this message remove the `whitelist_attributes` option from your
`config/application.rb` file and any `mass_assignment_sanitizer` options
from your `config/environments/*.rb` files.

See http://guides.rubyonrails.org/security.html#mass-assignment for more information.

DEPRECATION WARNING: The Active Record auto explain feature has been removed.

To disable this message remove the `active_record.auto_explain_threshold_in_seconds`
option from the `config/environments/*.rb` config file.

See http://guides.rubyonrails.org/4_0_release_notes.html for more information.

具体要设置哪些参数呢? Ubuntu12.04 32 位

这是你提高英文的好机会,把它读懂就明白了。

#1 楼 @nightire 其实有点明白,在config/environments/development.rb第 10 行把config.whiny_nils设置为false 但不知其所然,所以迷茫!

#1 楼 @nightire 大侠,为什么我按照提示设置好参数后,执行 Rspec 却提示:

DEPRECATION WARNING: config.whiny_nils option is deprecated and no longer works. (called from block in <top (required)> at /home/johnlu/rails_projects/mysampleapp/config/environments/test.rb:15)
You don't have dalli installed in your application. Please add it to your Gemfile and run bundle install

唉呀,有太多不懂了! 乱配置!

你從 rails3 升級到 rails4 的吧?

#5 楼 @yesmeck 我也不记得有没有安装过 Rails 3 了

#6 楼 @Rei 谢谢,我已经硬着头皮看懂了

#9 楼 @brala61 谢谢。已经设置好了!

需要 登录 后方可回复, 如果你还没有账号请 注册新账号