我试图进行迁移但出现以下错误
I was trying to make a migation but got the following error
ActiveAdmin::DatabaseHitDuringLoad: Your file, app/admin/formula.rb (line 7), caused a database error while Active Admin was loading. This is most common when your database is missing or doesn't have the latest migrations applied. To prevent this error, move the code to a place where it will only be run when a page is rendered. One solution can be, to wrap the query in a Proc. Original error message: PG::UndefinedTable: ERROR: relation "users" does not exist
LINE 1: SELECT "users".* FROM "users"
^
: SELECT "users".* FROM "users"
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/error.rb:43:in `rescue in capture'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/error.rb:41:in `capture'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `block in load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:248:in `routes'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:80:in `routes'
/home/aysha/Documents/reditum3/config/routes.rb:8:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `eval_block'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:371:in `draw'
/home/aysha/Documents/reditum3/config/routes.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:16:in `reload!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:26:in `block in updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/file_update_checker.rb:77:in `execute'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:27:in `updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/finisher.rb:119:in `block in <module:Finisher>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `run'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:55:in `block in run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:54:in `run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:352:in `initialize!'
/home/aysha/Documents/reditum3/config/environment.rb:5:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `block in require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:328:in `require_environment!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:448:in `block in run_tasks_blocks'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `eval'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `<main>'
ActiveRecord::StatementInvalid: PG::UndefinedTable: ERROR: relation "users" does not exist
LINE 1: SELECT "users".* FROM "users"
^
: SELECT "users".* FROM "users"
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `async_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `block in exec_no_cache'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract_adapter.rb:590:in `block in log'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract_adapter.rb:583:in `log'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `exec_no_cache'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:585:in `execute_and_clear'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql/database_statements.rb:103:in `exec_query'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/database_statements.rb:377:in `select_prepared'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/database_statements.rb:39:in `select_all'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/query_cache.rb:95:in `select_all'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/querying.rb:39:in `find_by_sql'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/bullet-5.5.1/lib/bullet/active_record5.rb:25:in `find_by_sql'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:702:in `exec_queries'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:583:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:260:in `records'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/bullet-5.5.1/lib/bullet/active_record5.rb:52:in `records'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation/delegation.rb:40:in `map'
/home/aysha/Documents/reditum3/app/admin/formula.rb:7:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/dsl.rb:15:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/dsl.rb:15:in `run_registration_block'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/namespace.rb:230:in `parse_registration_block'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/namespace.rb:52:in `register'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:176:in `register'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:76:in `register'
/home/aysha/Documents/reditum3/app/admin/formula.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/error.rb:41:in `capture'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `block in load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:248:in `routes'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:80:in `routes'
/home/aysha/Documents/reditum3/config/routes.rb:8:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `eval_block'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:371:in `draw'
/home/aysha/Documents/reditum3/config/routes.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:16:in `reload!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:26:in `block in updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/file_update_checker.rb:77:in `execute'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:27:in `updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/finisher.rb:119:in `block in <module:Finisher>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `run'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:55:in `block in run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:54:in `run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:352:in `initialize!'
/home/aysha/Documents/reditum3/config/environment.rb:5:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `block in require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:328:in `require_environment!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:448:in `block in run_tasks_blocks'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `eval'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `<main>'
PG::UndefinedTable: ERROR: relation "users" does not exist
LINE 1: SELECT "users".* FROM "users"
^
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `async_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `block in exec_no_cache'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract_adapter.rb:590:in `block in log'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract_adapter.rb:583:in `log'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `exec_no_cache'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:585:in `execute_and_clear'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql/database_statements.rb:103:in `exec_query'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/database_statements.rb:377:in `select_prepared'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/database_statements.rb:39:in `select_all'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/query_cache.rb:95:in `select_all'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/querying.rb:39:in `find_by_sql'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/bullet-5.5.1/lib/bullet/active_record5.rb:25:in `find_by_sql'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:702:in `exec_queries'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:583:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:260:in `records'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/bullet-5.5.1/lib/bullet/active_record5.rb:52:in `records'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation/delegation.rb:40:in `map'
/home/aysha/Documents/reditum3/app/admin/formula.rb:7:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/dsl.rb:15:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/dsl.rb:15:in `run_registration_block'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/namespace.rb:230:in `parse_registration_block'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/namespace.rb:52:in `register'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:176:in `register'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:76:in `register'
/home/aysha/Documents/reditum3/app/admin/formula.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/error.rb:41:in `capture'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `block in load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:248:in `routes'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:80:in `routes'
/home/aysha/Documents/reditum3/config/routes.rb:8:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `eval_block'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:371:in `draw'
/home/aysha/Documents/reditum3/config/routes.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:16:in `reload!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:26:in `block in updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/file_update_checker.rb:77:in `execute'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:27:in `updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/finisher.rb:119:in `block in <module:Finisher>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `run'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:55:in `block in run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:54:in `run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:352:in `initialize!'
/home/aysha/Documents/reditum3/config/environment.rb:5:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `block in require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:328:in `require_environment!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:448:in `block in run_tasks_blocks'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `eval'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `<main>'
Tasks: TOP => db:migrate => environment
(See full trace by running task with --trace)
您的数据库中不存在用户 table。可能存在迁移文件,但 运行 和 table 未创建。请先尝试创建用户 table,这应该可以解决此问题。如果您在迁移过程中遇到任何问题,请随时 post 这里的问题。
ActiveAdmin::DatabaseHitDuringLoad: Your file, app/admin/formula.rb (line 7), caused a database error while Active Admin was loading. This is most common when your database is missing or doesn't have the latest migrations applied. To prevent this error, move the code to a place where it will only be run when a page is rendered. One solution can be, to wrap the query in a Proc. Original error message: PG::UndefinedTable: ERROR: relation "users" does not exist
LINE 1: SELECT "users".* FROM "users"
^
: SELECT "users".* FROM "users"
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/error.rb:43:in `rescue in capture'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/error.rb:41:in `capture'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `block in load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:248:in `routes'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:80:in `routes'
/home/aysha/Documents/reditum3/config/routes.rb:8:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `eval_block'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:371:in `draw'
/home/aysha/Documents/reditum3/config/routes.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:16:in `reload!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:26:in `block in updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/file_update_checker.rb:77:in `execute'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:27:in `updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/finisher.rb:119:in `block in <module:Finisher>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `run'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:55:in `block in run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:54:in `run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:352:in `initialize!'
/home/aysha/Documents/reditum3/config/environment.rb:5:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `block in require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:328:in `require_environment!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:448:in `block in run_tasks_blocks'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `eval'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `<main>'
ActiveRecord::StatementInvalid: PG::UndefinedTable: ERROR: relation "users" does not exist
LINE 1: SELECT "users".* FROM "users"
^
: SELECT "users".* FROM "users"
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `async_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `block in exec_no_cache'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract_adapter.rb:590:in `block in log'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract_adapter.rb:583:in `log'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `exec_no_cache'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:585:in `execute_and_clear'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql/database_statements.rb:103:in `exec_query'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/database_statements.rb:377:in `select_prepared'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/database_statements.rb:39:in `select_all'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/query_cache.rb:95:in `select_all'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/querying.rb:39:in `find_by_sql'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/bullet-5.5.1/lib/bullet/active_record5.rb:25:in `find_by_sql'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:702:in `exec_queries'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:583:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:260:in `records'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/bullet-5.5.1/lib/bullet/active_record5.rb:52:in `records'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation/delegation.rb:40:in `map'
/home/aysha/Documents/reditum3/app/admin/formula.rb:7:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/dsl.rb:15:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/dsl.rb:15:in `run_registration_block'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/namespace.rb:230:in `parse_registration_block'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/namespace.rb:52:in `register'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:176:in `register'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:76:in `register'
/home/aysha/Documents/reditum3/app/admin/formula.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/error.rb:41:in `capture'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `block in load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:248:in `routes'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:80:in `routes'
/home/aysha/Documents/reditum3/config/routes.rb:8:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `eval_block'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:371:in `draw'
/home/aysha/Documents/reditum3/config/routes.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:16:in `reload!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:26:in `block in updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/file_update_checker.rb:77:in `execute'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:27:in `updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/finisher.rb:119:in `block in <module:Finisher>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `run'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:55:in `block in run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:54:in `run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:352:in `initialize!'
/home/aysha/Documents/reditum3/config/environment.rb:5:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `block in require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:328:in `require_environment!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:448:in `block in run_tasks_blocks'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `eval'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `<main>'
PG::UndefinedTable: ERROR: relation "users" does not exist
LINE 1: SELECT "users".* FROM "users"
^
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `async_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `block in exec_no_cache'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract_adapter.rb:590:in `block in log'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract_adapter.rb:583:in `log'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `exec_no_cache'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:585:in `execute_and_clear'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/postgresql/database_statements.rb:103:in `exec_query'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/database_statements.rb:377:in `select_prepared'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/database_statements.rb:39:in `select_all'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/connection_adapters/abstract/query_cache.rb:95:in `select_all'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/querying.rb:39:in `find_by_sql'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/bullet-5.5.1/lib/bullet/active_record5.rb:25:in `find_by_sql'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:702:in `exec_queries'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:583:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation.rb:260:in `records'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/bullet-5.5.1/lib/bullet/active_record5.rb:52:in `records'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activerecord-5.0.3/lib/active_record/relation/delegation.rb:40:in `map'
/home/aysha/Documents/reditum3/app/admin/formula.rb:7:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/dsl.rb:15:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/dsl.rb:15:in `run_registration_block'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/namespace.rb:230:in `parse_registration_block'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/namespace.rb:52:in `register'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:176:in `register'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:76:in `register'
/home/aysha/Documents/reditum3/app/admin/formula.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/error.rb:41:in `capture'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:234:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `block in load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:226:in `load!'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin/application.rb:248:in `routes'
/home/aysha/.rvm/gems/ruby-2.4.1/bundler/gems/activeadmin-8f7f58016802/lib/active_admin.rb:80:in `routes'
/home/aysha/Documents/reditum3/config/routes.rb:8:in `block in <top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:389:in `eval_block'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/actionpack-5.0.3/lib/action_dispatch/routing/route_set.rb:371:in `draw'
/home/aysha/Documents/reditum3/config/routes.rb:3:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `block in load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:287:in `load'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `each'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:40:in `load_paths'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:16:in `reload!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:26:in `block in updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/file_update_checker.rb:77:in `execute'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:27:in `updater'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application/finisher.rb:119:in `block in <module:Finisher>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `instance_exec'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:30:in `run'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:55:in `block in run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/initializable.rb:54:in `run_initializers'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:352:in `initialize!'
/home/aysha/Documents/reditum3/config/environment.rb:5:in `<top (required)>'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `block in require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:259:in `load_dependency'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/activesupport-5.0.3/lib/active_support/dependencies.rb:293:in `require'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:328:in `require_environment!'
/home/aysha/.rvm/gems/ruby-2.4.1/gems/railties-5.0.3/lib/rails/application.rb:448:in `block in run_tasks_blocks'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `eval'
/home/aysha/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:24:in `<main>'
Tasks: TOP => db:migrate => environment
(See full trace by running task with --trace)
您的数据库中不存在用户 table。可能存在迁移文件,但 运行 和 table 未创建。请先尝试创建用户 table,这应该可以解决此问题。如果您在迁移过程中遇到任何问题,请随时 post 这里的问题。