Error locally with rake db:seed


#1

Hi, I'm trying the tasks locally and get following error when running rake db:seed :

rake aborted!
ActiveModel::UnknownAttributeError: unknown attribute 'content' for Message.
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activemodel-5.0.0.beta3/lib/active_model/attribute_assignment.rb:48:in _assign_attribute'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activemodel-5.0.0.beta3/lib/active_model/attribute_assignment.rb:40:in
block in assignattributes'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activemodel-5.0.0.beta3/lib/active_model/attribute_assignment.rb:39:in each'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activemodel-5.0.0.beta3/lib/active_model/attribute_assignment.rb:39:in
assignattributes'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activerecord-5.0.0.beta3/lib/active_record/attribute_assignment.rb:26:in _assign_attributes'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activemodel-5.0.0.beta3/lib/active_model/attribute_assignment.rb:33:in
assign_attributes'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activerecord-5.0.0.beta3/lib/active_record/core.rb:310:in initialize'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activerecord-5.0.0.beta3/lib/active_record/inheritance.rb:65:in
new'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activerecord-5.0.0.beta3/lib/active_record/inheritance.rb:65:in new'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activerecord-5.0.0.beta3/lib/active_record/persistence.rb:33:in
create'
/Users/tjb/Sites/Pages/Mine/Ruby/Test1/helloworld/db/seeds.rb:9:in <top (required)>'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activesupport-5.0.0.beta3/lib/active_support/dependencies.rb:296:in
load'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activesupport-5.0.0.beta3/lib/active_support/dependencies.rb:296:in block in load'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activesupport-5.0.0.beta3/lib/active_support/dependencies.rb:268:in
load_dependency'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activesupport-5.0.0.beta3/lib/active_support/dependencies.rb:296:in load'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/railties-5.0.0.beta3/lib/rails/engine.rb:549:in
load_seed'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activerecord-5.0.0.beta3/lib/active_record/tasks/database_tasks.rb:265:in load_seed'
/Users/tjb/.rvm/gems/ruby-2.3.0/gems/activerecord-5.0.0.beta3/lib/active_record/railties/databases.rake:196:in
block (2 levels) in '
Tasks: TOP => db:seed
(See full trace by running task with --trace)

why is it and what can I do?


#2

Hi Chitzui,

You gave very few details - have you copied the Codecademy project so far exactly so it's the same thing on your computer, or are there differences? Have you run bundle install and rake db:migrate first?