A copy of ApplicationController has been removed from the module tree but is still active

Posted by Matchu on Stack Overflow See other posts from Stack Overflow or by Matchu
Published on 2009-08-07T02:14:14Z Indexed on 2013/11/11 3:54 UTC
Read the original article Hit count: 352

Whenever two concurrent HTTP requests go to my Rails app, the second always returns the following error:

A copy of ApplicationController has been removed from the module tree but is still active!

From there it gives an unhelpful stack trace to the effect of "we went through the standard server stuff, ran your first before_filter on ApplicationController (and I checked; it's just whichever filter runs first)", then offers the following:

/home/matchu/rails/torch/vendor/rails/activesupport/lib/active_support/dependencies.rb:414:in `load_missing_constant'

/home/matchu/rails/torch/vendor/rails/activesupport/lib/active_support/dependencies.rb:96:in `const_missing'

which I'm assuming is a generic response and doesn't really say much.

Google seems to tell me that people developing Rails Engines will encounter this, but I don't do that. All I've done is upgrade my Rails app from 2.2 (2.1?) to 2.3.

What are some possible causes for this error, and how can I go about tracking down what's really going on? I know this question is vague, so would any other information be helpful?

More importantly: I tried doing a test run in a "production" environment just now, and the error doesn't seem to persist. Does this only affect development, then, and need I not worry too much?

© Stack Overflow or respective owner

Related posts about ruby

Related posts about rubygems