Discourse Voting missing table on postgresql

After installing https://github.com/discourse/discourse-voting, I get the following error in logs (docker):

discourse | Started GET "/" for 2.3.75.18 at 2020-10-22 17:36:58 +0000 discourse | Processing by ListController#latest as HTML discourse_db | 2020-10-22 17:36:59.073 UTC [2221] ERROR: relation "discourse_voting_category_settings" does not exist at character 454 discourse_db | 2020-10-22 17:36:59.073 UTC [2221] STATEMENT: SELECT a.attname, format_type(a.atttypid, a.atttypmod), discourse_db | pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod, discourse_db | c.collname, col_description(a.attrelid, a.attnum) AS comment discourse_db | FROM pg_attribute a discourse_db | LEFT JOIN pg_attrdef d ON a.attrelid = d.adrelid AND a.attnum = d.adnum discourse_db | LEFT JOIN pg_type t ON a.atttypid = t.oid discourse_db | LEFT JOIN pg_collation c ON a.attcollation = c.oid AND a.attcollation <> t.typcollation discourse_db | WHERE a.attrelid = '"discourse_voting_category_settings"'::regclass discourse_db | AND a.attnum > 0 AND NOT a.attisdropped discourse_db | ORDER BY a.attnum discourse_db | discourse | Completed 500 Internal Server Error in 30ms (ActiveRecord: 0.0ms | Allocations: 9365) discourse | ActiveRecord::StatementInvalid (PG::UndefinedTable: ERROR: relation "discourse_voting_category_settings" does not exist discourse | LINE 8: WHERE a.attrelid = '"discourse_voting_category_settings"'::... discourse | ^ discourse | ) discourse | /opt/bitnami/discourse/vendor/bundle/ruby/2.6.0/gems/rack-mini-profiler-2.0.2/lib/patches/db/pg.rb:110:in `exec' discourse | Failed to handle exception in exception app middleware : PG::UndefinedTable: ERROR: relation "discourse_voting_category_settings" does not exist discourse | LINE 8: WHERE a.attrelid = '"discourse_voting_category_settings"'::... discourse | ^ discourse | discourse | Started GET "/service-worker-c8000968830b6f6bd33f1e842dffdd569664119d449f93dc7d428d963a71635d.js" for 2.3.75.18 at 2020-10-22 17:37:01 +0000 discourse | Processing by StaticController#service_worker_asset as */* discourse | Rendering text template discourse | Rendered text template (Duration: 0.0ms | Allocations: 1) discourse | Completed 200 OK in 6ms (Views: 0.8ms | ActiveRecord: 0.0ms | Allocations: 1731) 

Plugin was installed without errors through command line:

RAILS_ENV=production bundle exec rake plugin:install[https://github.com/discourse/discourse-voting] 
1 Like

There have been issues with this migration running at times. Try running bin/rake db:migrate from console or rebuilding your container to resolve until we find a fix.

4 Likes

Hi @justin
This does seems to fix the problem. Thank you.

I do hope though that you a fix for that :smiley:

2 Likes

Please follow this guide to install plugins: Install plugins on a self-hosted site

Also, as said on your other topic, please follow Discourse official Standard Installation to install Discourse.

6 Likes