出现此错误:
PG::DuplicateTable: ERROR: relation “index_users_on_username_lower_trgm” already exists
因此构建失败。
我不能通过执行以下操作来清除问题吗?:
rake db:migrate:down VERSION=20230201192925
然后:
rake db:migrate:up VERSION=20230201192925
不幸的是,后者重现了问题,表明回滚迁移并未重置状态?
出现此错误:
PG::DuplicateTable: ERROR: relation “index_users_on_username_lower_trgm” already exists
因此构建失败。
我不能通过执行以下操作来清除问题吗?:
rake db:migrate:down VERSION=20230201192925
然后:
rake db:migrate:up VERSION=20230201192925
不幸的是,后者重现了问题,表明回滚迁移并未重置状态?
我执行了以下操作进行解决:
cd /var/discourse
./launcher enter app
sudo -u discourse psql
\c discourse
DROP INDEX index_users_on_username_lower_trgm;
exit
然后为了确保万无一失:
rake db:migrate:up VERSION=20230201192925
这次成功运行了 ![]()
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.