Rails WARN -- : Overwriting existing field

leslin123 · 2014年01月27日 · 最后由 leslin123 回复于 2014年02月01日 · 2958 次阅读

部署 ruby-china 源代码后,跑各种命令都报以下类似的 warning。看起来似乎与 mongo 相关,哪位指点一下排查思路,谢谢!

 rake assets:precompile
W, [2014-01-27T14:39:09.324275 #19593]  WARN -- : Overwriting existing field _id.
W, [2014-01-27T14:39:11.300263 #19593]  WARN -- : Overwriting existing field _id.
W, [2014-01-27T14:39:11.305920 #19593]  WARN -- : Overwriting existing field _type.
W, [2014-01-27T14:39:11.309161 #19593]  WARN -- : Overwriting existing field _type.
W, [2014-01-27T14:39:11.483261 #19593]  WARN -- : Overwriting existing field _id.


rails s
W, [2014-01-27T13:48:11.376040 #16812]  WARN -- : Overwriting existing field _id.
=> Booting Thin
=> Rails 4.0.2 application starting in development on http://0.0.0.0:3000
=> Run `rails server -h` for more startup options
=> Ctrl-C to shutdown server
W, [2014-01-27T13:48:13.608263 #16812]  WARN -- : Overwriting existing field _id.
W, [2014-01-27T13:48:13.614664 #16812]  WARN -- : Overwriting existing field _type.
W, [2014-01-27T13:48:13.617905 #16812]  WARN -- : Overwriting existing field _type.
W, [2014-01-27T13:48:13.793242 #16812]  WARN -- : Overwriting existing field _id.
=> Memory usage: 118.63 Mb
>> Thin web server (v1.5.0 codename Knife)
>> Maximum connections set to 1024
>> Listening on 0.0.0.0:3000, CTRL+C to stop

再不懂点我

谢谢 @search ,我先仔细看一下,谢谢! 预祝新年快乐!

@search ,没有看到解决方法,求提示,谢谢!

@huacnlee 最近一次@Rei patch"Fix create topic with invalid node_id bug"是与此相关吗? 没看出关联性,能解决 warning 的问题吗?上面 stackoverflow 的 QA 反映的是类似的问题,解决方法有吗?

这个等 Mongoid 最新版本发布后就能解决

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