ruby on rails - Rails4 app not logging as expected on Heroku -
i have simple rails 4 app showing divergent behavior between running on localhost , heroku. trying debug behavior through logs finding calls puts
or logger.info
not propagating heroku logs
. in view, however, puts
calls working fine.
i have config.log_level = :info
set in /config/environments/production.rb
, know relevant controller puts
statements should being executed because statements placed after them in controller method being executed.
i have gem 'rails_12factor', '0.0.2'
in group :production
, know affects logging don't understand how.
would appreciate suggestions why happening or can fix.
edit
so had 2 calls in controller:
logger.info "in load_messages, id: #{params[:cid]}" @current_conversation = conversation.find(params[:cid]) logger.info "in load_messages, current_conversation: #{@current_conversation}" # other code executing
@current_conversation
not being loaded, nor logs being executed. removed 2 logger.info
calls, @current_conversation
assignment executed correctly. confused behavior, , still love explanation knows why is.
Comments
Post a Comment