rsmml / cashless_386

1 stars 1 forks source link

migration issue. #64

Closed chihoko12 closed 4 years ago

chihoko12 commented 4 years ago

after pulling master and trying rails db:migrate, migration is aborted.

== 20200730184655 RenameTypeToCardType: migrating =============================
-- rename_column(:cards, :type, :card_type)
rails aborted!
StandardError: An error has occurred, this and all later migrations canceled:

PG::UndefinedColumn: ERROR:  column "type" does not exist
/Users/cu/code/rsmml/cashless_386/db/migrate/20200730184655_rename_type_to_card_type.rb:3:in `change'
/Users/cu/code/rsmml/cashless_386/bin/rails:9:in `<top (required)>'
/Users/cu/code/rsmml/cashless_386/bin/spring:15:in `<top (required)>'
bin/rails:3:in `load'
bin/rails:3:in `<main>'

Caused by:
ActiveRecord::StatementInvalid: PG::UndefinedColumn: ERROR:  column "type" does not exist
/Users/cu/code/rsmml/cashless_386/db/migrate/20200730184655_rename_type_to_card_type.rb:3:in `change'
/Users/cu/code/rsmml/cashless_386/bin/rails:9:in `<top (required)>'
/Users/cu/code/rsmml/cashless_386/bin/spring:15:in `<top (required)>'
bin/rails:3:in `load'
bin/rails:3:in `<main>'

Caused by:
PG::UndefinedColumn: ERROR:  column "type" does not exist
/Users/cu/code/rsmml/cashless_386/db/migrate/20200730184655_rename_type_to_card_type.rb:3:in `change'
/Users/cu/code/rsmml/cashless_386/bin/rails:9:in `<top (required)>'
/Users/cu/code/rsmml/cashless_386/bin/spring:15:in `<top (required)>'
bin/rails:3:in `load'
bin/rails:3:in `<main>'
Tasks: TOP => db:migrate
rsmml commented 4 years ago

I had the same yesterday. Should be fixed now :)