Closed Akrog closed 3 years ago
I created a reproducer and pushed to https://github.com/Akrog/anvil-issue-45.
DB schema:
db_schema:
- name: Providers
id: 148532
python_name: providers
columns:
63VfP1JrMt8=:
name: created
type: datetime
admin_ui: {order: 3, width: 200}
gOyvB6eoXgY=:
name: users
type: liveObject
backend: anvil.tables.Row
admin_ui: {order: 0, width: 200}
table_id: 148527
sFdXtPCzTdA=:
name: display_name
type: string
admin_ui: {order: 1, width: 200}
yfv+w5o2s+Y=:
name: config
type: string
admin_ui: {order: 2, width: 200}
access: {python_name: providers, app_id: RQPID2OHG4B46QLT, server: full, client: none,
table_mapping_name: null, table_mapping_id: null, table_id: 148532}
There seems to be a regression in 1.6.0 in the DB schema check to decide when a migration is necessary. This issue is not present in 1.5.5.
I run
anvil-app-server
version 1.6.0 on a container with a host directory volume for the database, and on first start it successfully creates the database and everything works, but if I kill the container and start it again it doesn't recognize the schema and suggests all kinds of crazy changes.Pinning
anvil-app-server
to 1.5.5 on the pip installation in theDockerfile
and repeating the same procedure works fine.Example of the suggested migration when there have been no changes to the DB schema in
anvil.yaml
:Link to a forum post of another user experiencing the same issue when migrating to 1.6.0