clear-code / redmine_full_text_search

Full text search for Redmine
MIT License
63 stars 24 forks source link

Migration error while removing plugin with MySQL #38

Closed iquiw closed 7 years ago

iquiw commented 7 years ago

After https://github.com/okkez/redmine_full_text_search/pull/37, with MySQL, bundle exec rake redmine:plugins:migrate NAME=full_text_search VERSION=0 causes the following error.

== 20170630062526 ResetSchemaForMroonga: reverting ============================
-- create_table(:fts_custom_values, {:if_exists=>true})
   -> 0.1749s
-- create_table(:fts_wiki_contents, {:if_exists=>true})
   -> 0.3746s
-- create_table(:fts_wiki_pages, {:if_exists=>true})
   -> 0.3160s
-- create_table(:fts_changesets, {:if_exists=>true})
   -> 0.1998s
-- create_table(:fts_attachments, {:if_exists=>true})
   -> 0.4337s
-- create_table(:fts_messages, {:if_exists=>true})
   -> 0.3493s
-- create_table(:fts_documents, {:if_exists=>true})
   -> 0.2166s
-- create_table(:fts_journals, {:if_exists=>true})
   -> 0.3249s
-- create_table(:fts_issues, {:if_exists=>true})
   -> 0.2666s
-- create_table(:fts_news, {:if_exists=>true})
   -> 0.1748s
-- create_table(:fts_projects, {:if_exists=>true})
   -> 0.2502s
== 20170630062526 ResetSchemaForMroonga: reverted (3.0985s) ===================

== 20170630062504 ResetSchemaForPgroonga: reverting ===========================
== 20170630062504 ResetSchemaForPgroonga: reverted (0.0004s) ==================

== 20170227125753 ChangeColumnTypeToText: reverting ===========================
== 20170227125753 ChangeColumnTypeToText: reverted (0.0001s) ==================

== 20170223142427 StopUsingMultiColumnIndex: reverting ========================
-- remove_index(:fts_projects, :name)
rake aborted!
StandardError: An error has occurred, all later migrations canceled:

Index name 'index_fts_projects_on_name' on table 'fts_projects' does not exist
/usr/local/bundle/gems/activerecord-4.2.8/lib/active_record/connection_adapters/abstract/schema_statements.rb:1003:in `index_name_for_remove'
/usr/local/bundle/gems/activerecord-4.2.8/lib/active_record/connection_adapters/abstract/schema_statements.rb:593:in `remove_index'