Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(explore): remove unnecessary parameters from the explore url #17123

Merged
merged 2 commits into from
Oct 18, 2021

Conversation

suddjian
Copy link
Member

@suddjian suddjian commented Oct 15, 2021

SUMMARY

The url was getting too long from including all this extra dashboard state that isn't used on the explore page. Now the extra state will be filtered out.

Truly solving the long explore url issue will require more substantial changes, but this will make it less likely for now.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

ADDITIONAL INFORMATION

  • Has associated issue: fixes [View in Explore]404s when 'View chart in Explore' from Dashboard #17075
  • Required feature flags:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

@suddjian suddjian changed the title remove unnecessary parameters from the explore url fix(explore): remove unnecessary parameters from the explore url Oct 15, 2021
@codecov
Copy link

codecov bot commented Oct 15, 2021

Codecov Report

Merging #17123 (ee33688) into master (7a2e394) will increase coverage by 0.03%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #17123      +/-   ##
==========================================
+ Coverage   76.94%   76.98%   +0.03%     
==========================================
  Files        1031     1031              
  Lines       55213    55500     +287     
  Branches     7505     7629     +124     
==========================================
+ Hits        42483    42726     +243     
- Misses      12480    12524      +44     
  Partials      250      250              
Flag Coverage Δ
hive 81.47% <ø> (ø)
javascript 71.01% <100.00%> (+0.09%) ⬆️
mysql 81.93% <ø> (ø)
postgres 81.94% <ø> (ø)
presto 81.80% <ø> (-0.01%) ⬇️
python 82.43% <ø> (-0.01%) ⬇️
sqlite 81.61% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
.../src/dashboard/components/gridComponents/Chart.jsx 80.37% <100.00%> (ø)
...uperset-frontend/src/explore/exploreUtils/index.js 66.66% <100.00%> (+0.20%) ⬆️
superset/db_engine_specs/presto.py 89.95% <0.00%> (-0.42%) ⬇️
...controls/FilterControl/AdhocFilterOption/index.jsx 100.00% <0.00%> (ø)
...src/components/FilterableTable/FilterableTable.tsx 83.33% <0.00%> (+1.47%) ⬆️
...perset-frontend/src/views/CRUD/chart/ChartList.tsx 76.28% <0.00%> (+1.92%) ⬆️
...ols/FilterControl/AdhocFilterEditPopover/index.jsx 70.79% <0.00%> (+2.46%) ⬆️
.../FilterControl/AdhocFilterPopoverTrigger/index.tsx 84.61% <0.00%> (+3.84%) ⬆️
...l/AdhocFilterEditPopoverSimpleTabContent/index.tsx 76.92% <0.00%> (+4.37%) ⬆️
...ontrols/FilterControl/AdhocFilterControl/index.jsx 63.90% <0.00%> (+6.21%) ⬆️
... and 1 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7a2e394...ee33688. Read the comment docs.

@pull-request-size pull-request-size bot added size/M and removed size/S labels Oct 15, 2021
@suddjian suddjian marked this pull request as ready for review October 15, 2021 18:48
@pkdotson
Copy link
Member

/testenv up

@github-actions
Copy link
Contributor

@pkdotson Ephemeral environment spinning up at http://54.214.199.175:8080. Credentials are admin/admin. Please allow several minutes for bootstrapping and startup.

@pkdotson
Copy link
Member

/testenv up FEATURE_DASHBOARD_NATIVE_FILTERS=true FEATURE_DASHBOARD_CROSS_FILTERS=true FEATURE_DASHBOARD_NATIVE_FILTERS_SET=true FEATURE_DASHBOARD_FILTERS_EXPERIMENTAL=true

@github-actions
Copy link
Contributor

@pkdotson Ephemeral environment spinning up at http://34.212.20.21:8080. Credentials are admin/admin. Please allow several minutes for bootstrapping and startup.

@graceguo-supercat
Copy link

if we know these parameters are from dashboard, why not _.omit them from dashboard?

Copy link
Member

@pkdotson pkdotson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested in eph env and looks good to go! Thanks for the fix.

@suddjian
Copy link
Member Author

suddjian commented Oct 15, 2021

if we know these parameters are from dashboard, why not _.omit them from dashboard?

It's a small difference, but it seems cleaner to me to have the url builder function take a full formData object and decide on its own what should go in the url.

@geido geido merged commit 57f869c into master Oct 18, 2021
@github-actions
Copy link
Contributor

Ephemeral environment shutdown and build artifacts deleted.

opus-42 pushed a commit to opus-42/incubator-superset that referenced this pull request Nov 14, 2021
…che#17123)

* remove unnecessary parameters from the explore url

* refactor, test
@eschutho eschutho added the v1.4 label Nov 23, 2021
eschutho pushed a commit that referenced this pull request Nov 23, 2021
)

* remove unnecessary parameters from the explore url

* refactor, test

(cherry picked from commit 57f869c)
@mistercrunch mistercrunch added 🍒 1.4.0 🍒 1.4.1 🍒 1.4.2 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels labels Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels preset-io size/M v1.4 🍒 1.4.0 🍒 1.4.1 🍒 1.4.2 🚢 1.5.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[View in Explore]404s when 'View chart in Explore' from Dashboard
6 participants