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 2018/06/01 20:29:45 UTC

[GitHub] williaster opened a new pull request #5126: [dashboard v2] add v1 switch

williaster opened a new pull request #5126: [dashboard v2] add v1 switch
URL: https://github.com/apache/incubator-superset/pull/5126
 
 
   This PR adds a dashboard v1 switch to the v2 app to enable us to execute on [our rollout plan](https://docs.google.com/a/airbnb.com/presentation/d/e/2PACX-1vTLLsUPzLuxq9kaSj4NlMG5HMnzY9_Dd6JXM17Tbmgie2HriJN445DXmBABN-0J2N_3WUpbmIB8AOd6/pub?start=false&loop=false&delayms=3000).
   
   It does the following:
   - copies the v1 `src/dashboard` app into `src/dashboard/deprecated/v1` 
     - note: v1 `src/chart` is also copied into this folder and referenced by the deprecated dashboard 
     - ⚠️ *After this PR it will be very difficult to incorporate dashboard v1 changes*
   - adds a `dashboard_deprecated` bundle entry, and a `dashboard_v1_deprecated.html` template (so the v1 app is entirely separate, this will enable easy future deletion)
   - adds a backend switch to `views/core.py => /dashboard/<id>` to support both `v1` and `v2`
   - adds [`v2` logging changes](https://github.com/apache/incubator-superset/pull/5087) to the `v1` dashboard app, and distinguishes which version is the source of given client logs.
   - adds the following `config.py` flags to support how dashboard viewers + owners experience `v1` and `v2` (see [example rollout plan](https://docs.google.com/a/airbnb.com/presentation/d/e/2PACX-1vTLLsUPzLuxq9kaSj4NlMG5HMnzY9_Dd6JXM17Tbmgie2HriJN445DXmBABN-0J2N_3WUpbmIB8AOd6/pub?start=false&loop=false&delayms=3000) here)
     ```python
     # change as desired as you rollout
     DASH_V2_IS_DEFAULT_VIEW_FOR_EDITORS = False
     CAN_FALLBACK_TO_DASH_V1_EDIT_MODE = True
   
     # shown in user messaging (optional)
     PLANNED_V2_AUTO_CONVERT_DATE = '2018-06-15'
     V2_FEEDBACK_URL = 'https://goo.gl/forms/...'
     ```
   - adds additional backend + client side logging to track v1 <> v2 usage + fallback 
   - [this gist](https://gist.github.com/williaster/bad4ac9c6a71b234cf9fc8ee629844e5#file-superset-dashboard-v2-md) is linked to via the "read more" messaging, and will be updated to include an overview of changes (not in this PR) 
   - adds client-side messaging to 
     - Prompt dashboard editors to convert v1 dashboards to v1
       <img src="https://user-images.githubusercontent.com/4496521/40861328-8565c2c4-659d-11e8-814a-9732bd937974.png" width="300" />
       (when v1 editing is disabled)
       <img src="https://user-images.githubusercontent.com/4496521/40861198-183dbc4c-659d-11e8-9c08-e9b0e8ada722.png" width="300" />
       (when no feedback + v2 switch date are configured)
       <img src="https://user-images.githubusercontent.com/4496521/40861744-0997e134-659f-11e8-95ee-55dde6605e6b.png" width="300" />
   
     - Notify users they are viewing a v2 preview
        <img src="https://user-images.githubusercontent.com/4496521/40861343-9a05d476-659d-11e8-90b7-08b045d67fd3.png" width="300" />
   
   
   **Remaining TODO**
   - [ ] Persist `v2` feedback url beyond the modal so users can reference it when editing, etc.
   - [x] Remove default values for feedback url + convert date
   
   @graceguo-supercat @mistercrunch 
   cc @michellethomas @john-bodley @betodealmeida @hughhhh 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

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