Issue Summary
I was having issues upgrading from v3 to v5, specifically with applying the db migrations.
From a clone of the release/5.0.x branch I ran:
bin/run ./manage.py db upgrade
which produced this error:
dashboards.tags does not exist
What Worked for Me
I modified the upgrade script so that it upgraded to v4.0.2 instead.
Place the script alongside the default one.
sudo cp path-to-modified-upgrade /opt/redash/current/bin/upgrade_v4
Run the modified upgrade script. [Upgrade to V4]
sudo bin/upgrade_v4
With v4 now installed, run the default upgrade script. [Upgrade to V5]
sudo bin/upgrade
Voila! You should now be running v5.0.1 (the latest version at this time of writing)
Technical details:
Redash Version: v3.0.0
Browser/OS: Ubuntu 16.04.3 LTS
How did you install Redash: Legacy bootstrap script
1 Like
galeck
October 31, 2018, 3:19pm
2
How did you enforce it to upgrade to a version which isn’t the latest?
Im encountering the same issue right now and would like to upgrade to V4.0.2 instead of V5
Modify your upgrade script, particularly the get_release method, with something like this:
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]
### CUSTOM ###
# hardcode to v4.0.2
release = [r for r in response.json() if r['version'] == '4.0.2']
if len(release) == 0:
exit(1)
print(release)
release = release[0]
### END CUSTOM ###
filename = release['download_url'].split('/')[-1]
release = Release(release['version'], release['download_url'], filename, release['description'])
return release