Replies: 4 comments
-
I can fix this by the obvious ALTER TABLE, and I'm then able to generate a report. But it suggests there may be more serious problems? Shouldn't the database schema be correct out of the box / having run the migrations? I also see other worrying errors. Should I submit a patch for the missing migration? Presumably there are others missing too - comparing server/src/db/sql.js to the database schema maybe? |
Beta Was this translation helpful? Give feedback.
-
I've seen this before. I think that column was removed entirely and shouldn't even be in any migrations. Looking into this: there are references to some defunct db columns in the code. We can't simply remove them since some legacy deployments may be using them. But maybe I can wrap them in some conditional logic... |
Beta Was this translation helpful? Give feedback.
-
@toad I made a DRAFT PR to remove some unused fields as well as shield the two encrypted_* fields from normal environments. You might find this branch useful for your self-hosted deployment. Unsure if this is necessarily the direction to take in edge/prod (hence DRAFT). |
Beta Was this translation helpful? Give feedback.
-
That works. Now using the updated edge with local patches. Thanks! |
Beta Was this translation helpful? Give feedback.
-
I've been trying to set up a self-hosted polis instance. It looks like the database migrations and the code that uses them are incompatible somehow? When I create a test conversation and attempt to vote, it fails on the browser and the logs show:
postgres-1 | 2024-11-01 16:52:17.606 UTC [175] ERROR: column "encrypted_ip_address" of relation "participants_extended" does not exist at character 105
...
server-1 | error: column "encrypted_ip_address" of relation "participants_extended" does not exist
This happens whether I use the edge or stable branch. I've tried running the migrations but they do not mention the field "encrypted_ip_address". I've tried rebuilding with --no-cache.
Am I running old code or old database migrations? This is with the default postgres-in-the-compose settings, I've tried with dev and prod on stable and prod on edge.
Beta Was this translation helpful? Give feedback.
All reactions