I think I found a real beauty.  I had to make some changes to the
posts controller, so I followed the documentation and copied it to my
controllers directory, made my changes, everything worked great in
development environment.

Then I deployed.  When I saved a new post (or deleted one) I got this
error:

NoMethodError (undefined method `controller_name' for nil:NilClass):
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/caching/sweeping.rb:83:in `callback'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/caching/sweeping.rb:65:in `after'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:417:in `around_proc'
    /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/
active_support/callbacks.rb:177:in `call'
    /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/
active_support/callbacks.rb:177:in `evaluate_method'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:393:in `call'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:598:in `run_before_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:578:in `call_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:601:in `run_before_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:398:in `call'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:398:in `call'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:598:in `run_before_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:578:in `call_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:601:in `run_before_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:398:in `call'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:398:in `call'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:598:in `run_before_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:578:in `call_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:573:in `perform_action_without_benchmark'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/benchmarking.rb:68:in
`perform_action_without_rescue'
    /usr/local/lib/ruby/1.8/benchmark.rb:293:in `measure'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/benchmarking.rb:68:in
`perform_action_without_rescue'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/rescue.rb:201:in `perform_action_without_caching'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/caching/sql_cache.rb:13:in
`passenger_orig_perform_action'
    /usr/local/lib/ruby/gems/1.8/gems/activerecord-2.1.0/lib/
active_record/connection_adapters/abstract/query_cache.rb:33:in
`cache'
    /usr/local/lib/ruby/gems/1.8/gems/activerecord-2.1.0/lib/
active_record/query_cache.rb:8:in `cache'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/caching/sql_cache.rb:12:in
`passenger_orig_perform_action'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
railz/request_handler.rb:53:in `perform_action'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/base.rb:529:in `send'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/base.rb:529:in `process_without_filters'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/filters.rb:569:in
`process_without_session_management_support'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/session_management.rb:130:in `sass_old_process'
    /usr/local/lib/ruby/gems/1.8/gems/haml-2.0.2/lib/sass/plugin/
rails.rb:19:in `process'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/base.rb:389:in `process'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/dispatcher.rb:149:in `handle_request'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/dispatcher.rb:107:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/dispatcher.rb:104:in `synchronize'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/dispatcher.rb:104:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/dispatcher.rb:120:in `dispatch_cgi'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/
action_controller/dispatcher.rb:35:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
railz/request_handler.rb:38:in `process_request'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
abstract_request_handler.rb:163:in `main_loop'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
railz/application_spawner.rb:307:in `start_request_handler'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
railz/application_spawner.rb:144:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
utils.rb:165:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
utils.rb:163:in `fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
utils.rb:163:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
railz/application_spawner.rb:130:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
utils.rb:165:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
utils.rb:163:in `fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
utils.rb:163:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
railz/application_spawner.rb:129:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
spawn_manager.rb:230:in `spawn_rails_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
spawn_manager.rb:213:in `synchronize'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
spawn_manager.rb:213:in `spawn_rails_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
spawn_manager.rb:122:in `spawn_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
spawn_manager.rb:247:in `handle_spawn_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
abstract_server.rb:317:in `__send__'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
abstract_server.rb:317:in `main_loop'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/lib/passenger/
abstract_server.rb:168:in `start_synchronously'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.3/bin/passenger-
spawn-server:46

Rendering /var/www/applications/doctv/public/500.html (500 Internal
Server Error)

After much debugging I determined that if I moved the posts controller
back into the vendor directory with my changes it worked perfectly.
So the workaround is to modify the original CE controller which of
course is a no-no if you want to be able to upgrade CE without losing
your changes.

Does anybody have any ideas how to fix this so that I can relocate the
controller back to my apps directory?  The other controller I
relocated are working fine, and I suspect the problem with the posts
controller is that it has a sweeper (you can see action_controller/
caching/sweeping at the top of the call stack) .  I tried copying the
sweeper to my apps/controllers directory but that didn't solve the
problem.

Thoughts?

Regards,

Stan

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CommunityEngine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/communityengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to