clear-code / redmine_full_text_search

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

Can't uninstall full_text_search #67

Closed ryouma-nagare closed 5 years ago

ryouma-nagare commented 5 years ago

環境情報

bundle exec rake redmine:plugins:migrate RAILS_ENV=production VERSION=0 NAME=full_text_search

の実行時に以下のエラーが発生します。

== 20170630075028 AddIndexToSearcherRecords: reverting ========================
rake aborted!
StandardError: An error has occurred, this and all later migrations canceled:

Index name 'index_searcher_records_pgroonga' on table 'searcher_records' does not exist
/opt/redmine/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.3/lib/active_record/migration/compatibility.rb:209:in `index_name_for_remove'
/opt/redmine/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.3/lib/active_record/migration/compatibility.rb:183:in `remove_index'

対処としては以下の通り、ダミーのインデックスを付加してアンインストールしました

sudo -u postgres -H psql -d db_redmine --command 'CREATE INDEX index_searcher_records_pgroonga on searcher_records(id) '
kou commented 5 years ago

できるようにしました。

ryouma-nagare commented 5 years ago

こちらも無事にアンインストールできるするようになりました。