-
Notifications
You must be signed in to change notification settings - Fork 24
Fix compilation errors after merging schema changes
Norman Rzepka edited this page Jan 11, 2023
·
4 revisions
After merging changes to the sql schema into your branch, some manual steps are required. We are working on automating some of them, but for now:
- run
yarn refresh-schema
to drop your db’s contents and load a fresh schema from schema.sql
-
conf/evolutions/
contains sql code to migrate your data to newer schema versions. - to help you figure out which ones you need, you can optionally run
tools/postgres/diff_schema.js tools/postgres/schema.sql DB
- apply the evolutions in the correct order, e.g. by copying their content to a pgadmin query tool that is connected to your db and executing them there.
- run
rm target/scala-2.12/src_managed/schema/com/scalableminds/webknossos/schema/Tables.scala
so that the scala compiler subsequently recreates it from the now up-to-date schema in your db
If the above steps didn't help. Try to run docker-compose down
and repeat the above steps.