在生产环境中,我收到以下错误
uninitialized constant ActiveRecord::ConnectionAdapters::AbstractMysqlAdapter::MysqlDateTime
有人帮我解决了这个问题。我搜索了很多东西,但是我找不到解决这个问题的方法。
错误日志详细信息:
ActionView::Template::Error: uninitialized constant ActiveRecord::ConnectionAdapters::AbstractMysqlAdapter::MysqlDateTime vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/inflector/methods.rb:263:in
const_get' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / inflector / methods.rb:263:inblock in constantize' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/inflector/methods.rb:259:in
每个' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / inflector / methods.rb:259:ininject' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/inflector/methods.rb:259:in
constantize' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / core_ext / string / inflections.rb:66:inconstantize' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/core_ext/marshal.rb:10:in
rescue in load_with_autoloading' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / core_ext / marshal.rb:6:inload_with_autoloading' vendor/bundle/ruby/2.2.0/gems/activerecord-session_store-0.1.0/lib/active_record/session_store.rb:11:in
unmarshal' vendor / bundle / ruby / 2.2.0 / gems / activerecord-session_store-0.1.0 / lib / active_record / session_store / session.rb:60:在get_session中的data' vendor/bundle/ruby/2.2.0/gems/activerecord-session_store-0.1.0/lib/action_dispatch/session/active_record_store.rb:72:in
块中' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / core_ext / kernel / reporting.rb:120:inblock (2 levels) in quietly' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/core_ext/kernel/reporting.rb:54:in
silence_stream' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / core_ext / kernel / reporting.rb:119:block in quietly' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/core_ext/kernel/reporting.rb:54:in
silence_stream' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / core_ext / kernel / reporting.rb:118:inquietly' vendor/bundle/ruby/2.2.0/gems/activerecord-session_store-0.1.0/lib/action_dispatch/session/active_record_store.rb:64:in
get_session' vendor / bundle / ruby / 2.2.0 / gems / rack-1.6.4 / lib / rack / session / abstract / id.rb:266:在load_session中的load_session' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/action_dispatch/middleware/session/abstract_store.rb:43:in
块中' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / action_dispatch / middleware / session / abstract_store.rb:51:instale_session_check!' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/action_dispatch/middleware/session/abstract_store.rb:43:in
load_session' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / action_dispatch / request / session.rb:180:inload!' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/action_dispatch/request/session.rb:172:in
load_for_read!' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / action_dispatch / request / session.rb:89:in[]' vendor/bundle/ruby/2.2.0/gems/exception_notification-4.1.4/lib/exception_notifier/views/exception_notifier/_session.text.erb:1:in
_ vendor_bundle_ruby _______ gems_exception_notification _______ lib_exception_notifier_views_exception_notifier__session_text_erb ___ 2672557614301542611_69896127503220' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / template.rb:145:inblock in render' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/notifications.rb:166:in
instrument' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / template.rb:333:ininstrument' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/template.rb:143:in
render' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / partial_renderer.rb:339:在render_partial' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/renderer/partial_renderer.rb:310:in
块中渲染' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / abstract_renderer.rb:39:在block in instrument' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/notifications.rb:164:in
块中的仪器' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / notifications / instrumenter.rb:20:ininstrument' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/notifications.rb:164:in
instrument' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / abstract_renderer.rb:39:ininstrument' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/renderer/partial_renderer.rb:309:in
render' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / renderer.rb:47:inrender_partial' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/helpers/rendering_helper.rb:35:in
render' vendor / bundle / ruby / 2.2.0 / gems / haml-4.0.7 / lib / haml / helpers / action_view_mods.rb:12:inrender_with_haml' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/template.rb:145:in
块中的渲染' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / notifications.rb:166:ininstrument' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/template.rb:333:in
instrument' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / template.rb:143:在render' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/renderer/template_renderer.rb:54:in
块(2级)中的render_template' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / abstract_renderer.rb:39:在block in instrument' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/notifications.rb:164:in
块中的仪器' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / notifications / instrumenter.rb:20:ininstrument' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/notifications.rb:164:in
instrument' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / abstract_renderer.rb:39:在render_template中的instrument' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/renderer/template_renderer.rb:53:in
块中' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / template_renderer.rb:61:inrender_with_layout' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/renderer/template_renderer.rb:52:in
render_template' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / template_renderer.rb:14:inrender' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/renderer/renderer.rb:42:in
render_template' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / renderer / renderer.rb:23:inrender' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/rendering.rb:100:in
_ render_template' vendor / bundle / ruby / 2.2.0 / gems / actionview-4.2.0 / lib / action_view / rendering.rb:83:inrender_to_body' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/abstract_controller/rendering.rb:25:in
render' vendor / bundle / ruby / 2.2.0 / gems / actionmailer-4.2.0 / lib / action_mailer / base.rb:887:inblock in collect_responses' vendor/bundle/ruby/2.2.0/gems/actionmailer-4.2.0/lib/action_mailer/collector.rb:26:in
call' vendor / bundle / ruby / 2.2.0 / gems / actionmailer-4.2.0 / lib / action_mailer / collector.rb:26:incustom' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/abstract_controller/collector.rb:10:in
text' vendor / bundle / ruby / 2.2.0 / gems / exception_notification-4.1.4 / lib / exception_notifier / email_notifier.rb:107:inblock in compose_email' vendor/bundle/ruby/2.2.0/gems/actionmailer-4.2.0/lib/action_mailer/base.rb:888:in
collect_responses' vendor / bundle / ruby / 2.2.0 / gems / actionmailer-4.2.0 / lib / action_mailer / base.rb:828:inmail' vendor/bundle/ruby/2.2.0/gems/exception_notification-4.1.4/lib/exception_notifier/email_notifier.rb:106:in
compose_email' vendor / bundle / ruby / 2.2.0 / gems / exception_notification-4.1.4 / lib / exception_notifier / email_notifier.rb:40:inexception_notification' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/abstract_controller/base.rb:198:in
process_action' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / abstract_controller / callbacks.rb:20:inblock in process_action' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/callbacks.rb:88:in
call' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / callbacks.rb:88:in_run_callbacks' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/callbacks.rb:734:in
_ run_process_action_callbacks' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / callbacks.rb:81:inrun_callbacks' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/abstract_controller/callbacks.rb:19:in
process_action' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / abstract_controller / base.rb:137:在process' vendor/bundle/ruby/2.2.0/gems/actionview-4.2.0/lib/action_view/rendering.rb:30:in
进程' vendor / bundle / ruby / 2.2.0 / gems / actionmailer-4.2.0 / lib / action_mailer / base.rb:596:在block in process' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/notifications.rb:164:in
块中的仪器' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / notifications / instrumenter.rb:20:ininstrument' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/notifications.rb:164:in
instrument' vendor / bundle / ruby / 2.2.0 / gems / actionmailer-4.2.0 / lib / action_mailer / base.rb:593:process' vendor/bundle/ruby/2.2.0/gems/actionmailer-4.2.0/lib/action_mailer/base.rb:584:in
初始化' vendor / bundle / ruby / 2.2.0 / gems / actionmailer-4.2.0 / lib / action_mailer / message_delivery.rb:25:innew' vendor/bundle/ruby/2.2.0/gems/actionmailer-4.2.0/lib/action_mailer/message_delivery.rb:25:in
getobj ' vendor / bundle / ruby / 2.2.0 / gems / actionmailer-4.2.0 / lib / action_mailer / message_delivery.rb:34:inmessage' vendor/bundle/ruby/2.2.0/gems/actionmailer-4.2.0/lib/action_mailer/message_delivery.rb:85:in
deliver_now' vendor / bundle / ruby / 2.2.0 / gems / exception_notification-4.1.4 / lib / exception_notifier / email_notifier.rb:153:incall' vendor/bundle/ruby/2.2.0/gems/exception_notification-4.1.4/lib/exception_notifier.rb:95:in
fire_notification' vendor / bundle / ruby / 2.2.0 / gems / exception_notification-4.1.4 / lib / exception_notifier.rb:40:block in notify_exception' vendor/bundle/ruby/2.2.0/gems/exception_notification-4.1.4/lib/exception_notifier.rb:39:in
每个' vendor / bundle / ruby / 2.2.0 / gems / exception_notification-4.1.4 / lib / exception_notifier.rb:39:在notify_exception' vendor/bundle/ruby/2.2.0/gems/exception_notification-4.1.4/lib/exception_notification/rack.rb:42:in
救援电话' vendor / bundle / ruby / 2.2.0 / gems / exception_notification-4.1.4 / lib / exception_notification / rack.rb:32:incall' vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/etag.rb:24:in
call' vendor / bundle / ruby / 2.2.0 / gems / rack-1.6.4 / lib / rack / conditionalget.rb:38:incall' vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/head.rb:13:in
call' vendor / bundle / ruby / 2.2.0 / gems / remotipart-1.2.1 / lib / remotipart / middleware.rb:27:incall' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/action_dispatch/middleware/params_parser.rb:27:in
call' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / action_dispatch / middleware / flash.rb:260:call' vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/session/abstract/id.rb:225:in
上下文' vendor / bundle / ruby / 2.2.0 / gems / rack-1.6.4 / lib / rack / session / abstract / id.rb:220:incall' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/action_dispatch/middleware/cookies.rb:560:in
call' vendor / bundle / ruby / 2.2.0 / gems / activerecord-4.2.0 / lib / active_record / query_cache.rb:36:incall' vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.0/lib/active_record/connection_adapters/abstract/connection_pool.rb:647:in
call' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / action_dispatch / middleware / callbacks.rb:29:inblock in call' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/callbacks.rb:88:in
call' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / callbacks.rb:88:in_run_callbacks' vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.0/lib/active_support/callbacks.rb:734:in
_ run_call_callbacks' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / callbacks.rb:81:inrun_callbacks' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/action_dispatch/middleware/callbacks.rb:27:in
call' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / action_dispatch / middleware / remote_ip.rb:78:incall' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/action_dispatch/middleware/debug_exceptions.rb:17:in
call' vendor / bundle / ruby / 2.2.0 / gems / actionpack-4.2.0 / lib / action_dispatch / middleware / show_exceptions.rb:30:incall' vendor/bundle/ruby/2.2.0/gems/railties-4.2.0/lib/rails/rack/logger.rb:38:in
call_app' vendor / bundle / ruby / 2.2.0 / gems / railties-4.2.0 / lib / rails / rack / logger.rb:22:incall' vendor/bundle/ruby/2.2.0/gems/actionpack-4.2.0/lib/action_dispatch/middleware/request_id.rb:21:in
call' vendor / bundle / ruby / 2.2.0 / gems / rack-1.6.4 / lib / rack / methodoverride.rb:22:incall' vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/runtime.rb:18:in
call' vendor / bundle / ruby / 2.2.0 / gems / activesupport-4.2.0 / lib / active_support / cache / strategy / local_cache_middleware.rb:28:incall' vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/sendfile.rb:113:in
call' vendor / bundle / ruby / 2.2.0 / gems / utf8-cleaner-0.2.4 / lib / utf8-cleaner / middleware.rb:21:incall' vendor/bundle/ruby/2.2.0/gems/railties-4.2.0/lib/rails/engine.rb:518:in
call' vendor / bundle / ruby / 2.2.0 / gems / railties-4.2.0 / lib / rails / application.rb:164:incall' /usr/local/rvm/gems/ruby-2.2.0/gems/passenger-5.0.6/lib/phusion_passenger/rack/thread_handler_extension.rb:85:in
process_request' /usr/local/rvm/gems/ruby-2.2.0/gems/passenger-5.0.6/lib/phusion_passenger/request_handler/thread_handler.rb:155:inaccept_and_process_next_request' /usr/local/rvm/gems/ruby-2.2.0/gems/passenger-5.0.6/lib/phusion_passenger/request_handler/thread_handler.rb:110:in
main_loop' /usr/local/rvm/gems/ruby-2.2.0/gems/passenger-5.0.6/lib/phusion_passenger/request_handler.rb:414:inblock (3 levels) in start_threads' /usr/local/rvm/gems/ruby-2.2.0/gems/passenger-5.0.6/lib/phusion_passenger/utils.rb:111:in
阻止在create_thread_and_abort_on_exception' `