superset icon indicating copy to clipboard operation
superset copied to clipboard

After upgrade changed name to Superset, existing role's permission names were not changed

Open jasonshah opened this issue 9 years ago • 9 comments

Superset version

Previously 0.11.x After upgrade, 0.12.1.0

Expected results

Existing standard roles (Admin, Alpha, Gamma) and custom roles (in our case, Client) would have their names changed from, e.g. "can welcome on Caravel" to "can welcome on Superset" as a part of the migration.

Actual results

No roles' names have changed. We have to manually change the names either one at a time through the UI, or through database queries. Only users with Admin role continued to work. For clients on all other roles, this resulted in ERR_TOO_MANY_REDIRECTS in Chrome, and investigation into the logs to identify this as the source of the issue.

Steps to reproduce

Perform the upgrade.

We ended up having to blow out our database and recreating it. We could not reliably upgrade.

jasonshah avatar Dec 05 '16 20:12 jasonshah

Yeah, would be very nice to have a migration for that

xrmx avatar Dec 06 '16 10:12 xrmx

@jasonshah - have u tried superset init ?

bkyryliuk avatar Dec 07 '16 01:12 bkyryliuk

@bkyryliuk yes, we followed instructions on the documentation for an upgrade.

karlgrz avatar Dec 07 '16 02:12 karlgrz

superset init should work.

malleshm avatar Dec 08 '16 07:12 malleshm

@malleshm I followed the documentation provided for applying an upgrade, so yes, I did run superset init. It still did not migrate the custom roles we have set up. Is it possible superset init failed in the middle of the process and just didn't log anything?

karlgrz avatar Dec 08 '16 15:12 karlgrz

ah, yes - we have 0 control over the custom roles.

bkyryliuk avatar Dec 09 '16 22:12 bkyryliuk

I meet the same problem that move the whole virtualenv files with superset-0.15.4 into product cluster's machine for upgrading superset-0.14.1. And i changed the sqlite3 datasource from /home/superset/.superset/superset.db into /root/.superset/superset.db. However, those information of superset changed nothing about USER, ROLE etc, even the UI.

  • Expected Result: image
  • But changed nothing: image @xrmx

asdf2014 avatar Feb 21 '17 07:02 asdf2014

@asdf2014 completely unrelated issue, before opening a new issue double check that your config correctly points to the right db and that you are using the correct virtualenv (last time i checked virtualenv were not movable). On top of that running stuff as root is bad.

xrmx avatar Feb 21 '17 08:02 xrmx

I see.

  • Config I use the default sqlite path, and i print the value of SQLALCHEMY_DATABASE_URI is /home/superset/.superset/superset.db. image

  • Virtualenv I am afraid I can not agree with your point of view that virtualenv is not movable. We can move it with virtualenv --relocatable command.

  • User I just put it in /root/superset, but it still belong to superset user. image

@xrmx

asdf2014 avatar Feb 21 '17 09:02 asdf2014