rake db: ошибка посева в рельсах 4.0.0.rc1

У меня есть приложение rails, которое не будет загружать данные в базу данных на rake db:seed.

Я попытался выяснить rake db:seed RAILS_ENV=developement --trace он дает следующую ошибку

** Вызывать db: seed (first_time)

** Выполнить db: семя

** Вызывать db: abort_if_pending_migrations (first_time)

** Вызывать среду (first_time)

** Выполнить среду

грабли прерваны!

в конфигурации базы данных не указан адаптер

/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activerecord-4.0.0.rc1/lib/active_record/connection_adapters/connection_specification.rb:52:in resolve_hash_connection'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activerecord-4.0.0.rc1/lib/active_record/connection_adapters/connection_specification.rb:46:in resolve_string_connection '/Users/MacBook/.rvm/gems/ruby-2.0. 0-p195/gems/activerecord-4.0.0.rc1/lib/active_record/connection_adapters/connection_specification.rb: 30: в spec'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activerecord-4.0.0.rc1/lib/active_record/connection_handling.rb:39:in install_connection '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activerecord-4.0.0.rc1/lib/active_record/railtie.rb: 170: в block (2 levels) in <class:Railtie>'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/lazy_load_hooks.rb:38:in instance_eval '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/lazy_load_hooks.rb:38 : in execute_hook'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/lazy_load_hooks.rb:28:in block in on_load'/Пользователи /MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/lazy_load_hooks.rb: 27: в each'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/lazy_load_hooks.rb:27:in on_load '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activerecord -4.0.0.rc1/lib/active_record/railtie.rb: 168: в block in <class:Railtie>'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/initializable.rb:30:in instance_exec '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/initializable.rb: 30: in run'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/initializable.rb:55:in блоке в run_initializers '/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/tsort.rb:150:в block in tsort_each'/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/tsort.rb:183:in block in tsort_each'/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/tsort.rb:183:in блоке (2 уровня) в each_strongly_connected_component '/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/tsort.rb:219:in each_strongly_connected_component_from'/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/tsort.rb:182:in block в each_strongly_connected_component'/Пользователи /MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby /2.0.0/tsort.rb: 180: в each'/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/tsort.rb:180:in each_strongly_connected_component '/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/tsort.rb:148:in tsort_each'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/initializable.rb:54:in run_initializers'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/application.rb:214:in initialize!'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/railtie/configurable.rb:30:in initialize!'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/railtie/configurable.rb:30:in method_missing '/Пользователи /MacBook/rails_projects/medicaldevicehub/config/environment.rb: 5: in <top (required)>'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/dependencies.rb:228:in require '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/dependencies.rb:28: в block in require'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/dependencies.rb:213:in load_dependency'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activesupport-4.0.0.rc1/lib/active_support/dependencies.rb:28:in require'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/application.rb:188:in require_environment! ' /Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/railties-4.0.0.rc1/lib/rails/application.rb:248:в block in run_tasks_blocks'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:246:in вызове '/Users/MacBook/.rvm/gems/ruby-2.0.0- p195@global/gems/rake-10.0.4/lib/rake/task.rb: 246: in block in execute'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:241:in каждом '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb: 241: in execute'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:184:in блоке в invoke_with_call_chain '/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/monitor.rb:211:in mon_synchronize'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:177:in invoke_with_call_chain '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb: 205: в block in invoke_prerequisites'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:203:in block in invoke_prerequisites'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:203:in каждом '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb: 203: in invoke_prerequisites'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:183:in block in invoke_with_call_chain '/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/monitor.rb:211:in mon_synchronize'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:177:in invoke_with_call_chain '/Users/MacBook/.rvm/gems/ruby- 2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb: 170: in invoke'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/gems/activerecord-4.0.0.rc1/lib/active_record/railties/databases.rake:180:in блоке (2 уровня) в '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake -10.0.4/lib/rake/task.rb: 246: в call'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:246:in block in execute '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10 .0.4/lib/rake/task.rb: 241: в each'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:241:in execute '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:184:в block in invoke_with_call_chain'/Users/MacBook/.rvm/rubies/ruby-2.0.0-p195/lib/ruby/2.0.0/monitor.rb:211:in mon_synchronize '/Users/MacBook/.rvm/gems/ruby-2.0.0 -p195@global/gems/rake-10.0.4/lib/rake/task.rb: 177: in invoke_with_call_chain'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/task.rb:170:in invoke '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/application.rb: 143: in invoke_task'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/application.rb:101:in block (2 уровни) в top_level '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/application.rb:101:in each'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/application.rb:101:in блоке в top_level '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/application.rb:110:in run_with_threads'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/application.rb:95:in top_level '/Users/MacBook/.rvm/gems/ruby-2.0.0- p195@global/gems/rake-10.0.4/lib/rake/application.rb: 73: в block in run'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/application.rb:160:in standard_exception_handling '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/lib/rake/application.rb: 70: in run'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/gems/rake-10.0.4/bin/rake:33:in '/Пользователи /MacBook/.rvm/gems/ruby-2.0.0-p195 @global/bin/rake: 23: in load'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195@global/bin/rake:23:in '/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/bin/ruby_noexec_wrapper:14:in eval'/Users/MacBook/.rvm/gems/ruby-2.0.0-p195/bin/ruby_noexec_wrapper:14:in разделе "Задачи: TOP => db: abort_if_pending_migrations =>

Вот мой файл database.yml:

development:
adapter: sqlite3
database: db/development.sqlite3
pool: 5
timeout: 5000

test:
adapter: sqlite3
database: db/test.sqlite3
pool: 5
timeout: 5000

production:
adapter: sqlite3
database: db/production.sqlite3
pool: 5
timeout: 5000
-1
источник поделиться

Посмотрите другие вопросы по меткам или Задайте вопрос