You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/08/31 04:13:17 UTC

[GitHub] [superset] whitney opened a new issue #16518: welcome_dashboard_id no longer works

whitney opened a new issue #16518:
URL: https://github.com/apache/superset/issues/16518


   When a user is added to the superset database, and a record is inserted into the `user_attributes` table to set the user's welcome dashboard to a particular dashboard, and then the user logs in, the user is not presented with the specified dashboard view but rather the generic welcome page.
   
   ### Expected results
   
   The dashboard specific view `/superset/dashboard/{dashboard_id_or_slug}` should be rendered.
   
   ### Actual results
   
   The generic, non-dashboard-specific "welcome" view is rendered (at `/superset/welcome`) 
   
   #### Screenshots
   
   <img width="1791" alt="Screen Shot 2021-08-30 at 11 39 32 PM" src="https://user-images.githubusercontent.com/72547/131438355-6083a704-f968-4965-a9a7-f98df5688bce.png">
   <img width="974" alt="Screen Shot 2021-08-30 at 11 43 32 PM" src="https://user-images.githubusercontent.com/72547/131438371-898c69f4-4843-4ea1-80de-8d1d27501b72.png">
   <img width="671" alt="Screen Shot 2021-08-30 at 11 40 52 PM" src="https://user-images.githubusercontent.com/72547/131438392-65aa0217-e6b4-408d-8a12-6875b2eb8817.png">
   
   
   #### How to reproduce the bug
   
   1. (in terminal) clone and build the latest version:
   ```bash
   git clone https://github.com/apache/superset.git
   cd superset
   docker-compose build && docker-compose up
   ```
   2. (in browser) login as admin user (username `admin`, password `admin`) at localhost:8088, and create a new user (say they have id=2)
   3. grant the `Admin` role to the user at `/users/edit/2`
   4. logout
   5. (in terminal) connect to the running  `superset_db` container:
   ```bash
   docker exec -it superset_db /bin/bash
   ```
   6. connect to the db (use password `superset`):
   ```bash
   psql -h db  -U superset -d superset
   ```
   7. insert a user_attribute record specifying that user 2 has the "Slack Dashboard" (from the examples), as the welcome dashboard:
   ```bash
   INSERT INTO user_attribute(user_id, welcome_dashboard_id) VALUES(2, 9);
   ```
   8. (in browser) login as the user you created in step 2.
   
   ### Environment
   
   I am running superset _locally_, in _dev mode_, using docker-compose, and the _latest version of code in master _ as of 10PM EST, 8/30/2021. Commit sha: `e2469162fa074af229ff97e845755caf1a29ca0d` 
   
   ### Checklist
   
   - [x] I have checked the superset logs for python stacktraces and included it here as text if there are any.
   - [x] I have reproduced the issue with at least the latest released version of superset.
   - [x] I have checked the issue tracker for the same issue and I haven't found one similar.
   
   ### Additional context
   
   I believe this issue was introduced with the refactor to move the dashboards route to a SPA (react) app. We are running a version of superset on production (f504b7fdd6863ba3da3a22963aa329b298b37357), and whereas in the legacy, server-side templating version there was very clear dashboard-specific bootstrap data being passed to the _dashboard_ template (see https://github.com/apache/superset/blob/f504b7fdd6863ba3da3a22963aa329b298b37357/superset/views/core.py#L1869), in the current SPA implementation, no such dashboard-specific bootstrap data is present (see https://github.com/apache/superset/blob/master/superset/views/core.py#L1904).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org