-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Downgrading then upgrading redash schemas doesn't work #6836
Comments
@wlach thanks for a finding |
Will see what I can do. |
Found an additional gotcha ( |
Oh, this all doesn't sound good. Breaking the schema when downgrading is something we'd better fix. The rough plan is to enable automatic schema upgrades when Redash starts (rather than a manual process). So being able to downgrade stuff when needed for some reason is probably pretty important. |
Yeah, it's a bit unfortunate -- I assume the alembic db migrations were automatically generated, and were just wrong in this case. I think we need to verify (via FWIW my testing setup is to do this to downgrade:
And this to upgrade:
|
Update: I haven't had time to look at this and am not sure when I will. |
@wlach This should be fixed in #7068, thanks to @ezraodio1. 😄 |
Issue Summary
After updating to latest main (1672cd9) and then downgrading to a previous version, upgrading again doesn't work unless you do the following:
The problem seems to be that this migration sets a default on downgrade, where none existed before. When you try to add a json schema to that, redash aborts.
Additional gotcha:
The "schedule" column gets casted to the
"null"
string on downgrade. You need to do a manual:Looks like the migrations modified in the following PRs are the culprits:
#6687
#6707
#6713
/cc @AndrewChubatiuk
The text was updated successfully, but these errors were encountered: