Upgrading redash version from beta version to the latest version


#1

I am trying to upgrade an old beta version of Redash to the latest version.
I followed to upgrade tutorial and got an error.
The error:

mail Settings
Applying 0014_add_alert_rearm_seconds.py…
Applying 0014_migrate_existing_es_to_kibana.py…
Applying 0015_add_schedule_query_permission.py…
Applying 0016_add_alert_subscriber.py…
Failed running: sudo sudo -u redash PYTHONPATH=. bin/run python migrations/0016_add_alert_subscriber.py
Exit status: 1
Output:
[2018-07-16 09:14:33,404][PID:2773][INFO][requests.packages.urllib3.connectionpool] Starting new HTTP connection (1): metadata.google.internal
[2018-07-16 09:14:33,441][PID:2773][WARNING][redash.query_runner] Hive query runner enabled but not supported, not registering. Either disable or install missing dependencies.
[2018-07-16 09:14:33,476][PID:2773][WARNING][redash.query_runner] Microsoft SQL Server query runner enabled but not supported, not registering. Either disable or install missing dependencies.
[2018-07-16 09:14:33,590][PID:2773][ERROR][peewee] CREATE TABLE “alert_subscriptions” (“id” SERIAL NOT NULL PRIMARY KEY, “updated_at” timestamp with time zone NOT NULL, “created_at” timestamp with time zone NOT NULL, “user_id” INTEGER NOT NULL, “destination_id” INTEGER, “alert_id” INTEGER NOT NULL, FOREIGN KEY (“user_id”) REFERENCES “users” (“id”), FOREIGN KEY (“destination_id”) REFERENCES “notification_destinations” (“id”), FOREIGN KEY (“alert_id”) REFERENCES “alerts” (“id”)) []
Traceback (most recent call last):
File “/usr/local/lib/python2.7/dist-packages/playhouse/postgres_ext.py”, line 360, in execute_sql
cursor.execute(sql, params or ())
ProgrammingError: relation “notification_destinations” does not exist

Traceback (most recent call last):
File “migrations/0016_add_alert_subscriber.py”, line 7, in
AlertSubscription.create_table()
File “/usr/local/lib/python2.7/dist-packages/peewee.py”, line 4055, in create_table
db.create_table(cls)
File “/usr/local/lib/python2.7/dist-packages/peewee.py”, line 3152, in create_table
return self.execute_sql(*qc.create_table(model_class, safe))
File “/opt/redash/redash.0.12.0.b2449/redash/metrics/database.py”, line 22, in execute_sql
result = super(MeteredPostgresqlExtDatabase, self).execute_sql(*args, **kwargs)
File “/usr/local/lib/python2.7/dist-packages/playhouse/postgres_ext.py”, line 369, in execute_sql
self.commit()
File “/usr/local/lib/python2.7/dist-packages/peewee.py”, line 2922, in exit
reraise(new_type, new_type(*exc_value.args), traceback)
File “/usr/local/lib/python2.7/dist-packages/playhouse/postgres_ext.py”, line 360, in execute_sql
cursor.execute(sql, params or ())
peewee.ProgrammingError: relation “notification_destinations” does not exist

Please help me fix it.
Thanks,
Tamir