Help us understand the problem. What is going on with this article?

Redash v5 にアップグレードすると「dashboards.tags does not exist」エラーが発生する現象の対応

More than 1 year has passed since last update.

Redash を v5 にアップグレードしようとした際に、以下のエラーが発生しました。
どうやら以前のバージョンには無い dashboard.tags というカラムに依存したコードがある模様。

sqlalchemy.exc.ProgrammingError: (psycopg2.ProgrammingError) column dashboards.tags does not exist
LINE 1: ...ived, dashboards.is_draft AS dashboards_is_draft, dashboards...
                                                             ^

v4 -> v5 の順でアップグレードする

既にいくつか報告が上がっていました。
一旦 v4 までアップグレードしてから、再度 v5 にアップグレードすれば良さそうです。
v4 の AMI があれば早いのですが、見当たらなかったので upgrade スクリプトをいじることにします。

https://discuss.redash.io/t/upgrade-from-3-0-0-b3134-to-v5/2384
https://discuss.redash.io/t/solved-how-to-upgrade-from-3-0-x-to-5-0-x/2426

まず、bin/upgrade をコピーします。

$ sudo cp bin/upgrade bin/upgrade_v4

upgrade_v4 を編集し、v4 系をダウンロードするようにします。

def get_release(channel):
    if channel == 'ci':
        return get_latest_release_from_ci()

    response = requests.get('https://version.redash.io/api/releases?channel={}'.format(channel))
    release = response.json()[0]

    # 追記
    release['version'] = '4.0.1'
    release['download_url'] = 'https://s3.amazonaws.com/redash-releases/redash.4.0.1.b4038.tar.gz'

で、v4、v5 と順番にアップグレードすれば OK でした。

$ sudo bin/upgrade_v4
$ sudo bin/upgrade
Why do not you register as a user and use Qiita more conveniently?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Comments
Sign up for free and join this conversation.
If you already have a Qiita account
Why do not you register as a user and use Qiita more conveniently?
You need to log in to use this function. Qiita can be used more conveniently after logging in.
You seem to be reading articles frequently this month. Qiita can be used more conveniently after logging in.
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away