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: move columns to datasource object for bootstrap data #20203

Merged
merged 2 commits into from
May 31, 2022

Conversation

hughhhh
Copy link
Member

@hughhhh hughhhh commented May 26, 2022

SUMMARY

Address concern after merge for adding data to datasource object instead of having it's own top level key

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

ADDITIONAL INFORMATION

  • Has associated issue:
  • 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

@hughhhh hughhhh changed the title move columns to datasource fix: move columns to datasource object for bootstrap data May 26, 2022
@codecov
Copy link

codecov bot commented May 26, 2022

Codecov Report

Merging #20203 (3aca9d0) into master (7a2eb8b) will decrease coverage by 0.18%.
The diff coverage is 50.00%.

@@            Coverage Diff             @@
##           master   #20203      +/-   ##
==========================================
- Coverage   66.46%   66.28%   -0.19%     
==========================================
  Files        1727     1727              
  Lines       64721    64723       +2     
  Branches     6823     6823              
==========================================
- Hits        43019    42901     -118     
- Misses      19970    20090     +120     
  Partials     1732     1732              
Flag Coverage Δ
hive ?
mysql 82.15% <50.00%> (-0.01%) ⬇️
postgres 82.21% <50.00%> (-0.01%) ⬇️
presto ?
python 82.25% <50.00%> (-0.39%) ⬇️
sqlite ?
unit ?

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

Impacted Files Coverage Δ
superset/views/core.py 77.34% <0.00%> (-0.02%) ⬇️
superset/models/sql_lab.py 91.08% <66.66%> (-0.48%) ⬇️
superset/db_engines/hive.py 0.00% <0.00%> (-85.19%) ⬇️
superset/db_engine_specs/hive.py 70.22% <0.00%> (-15.65%) ⬇️
superset/db_engine_specs/sqlite.py 91.89% <0.00%> (-5.41%) ⬇️
superset/db_engine_specs/presto.py 83.36% <0.00%> (-5.34%) ⬇️
superset/utils/celery.py 86.20% <0.00%> (-3.45%) ⬇️
superset/connectors/sqla/utils.py 88.75% <0.00%> (-2.50%) ⬇️
superset/result_set.py 96.85% <0.00%> (-1.58%) ⬇️
superset/connectors/sqla/models.py 88.41% <0.00%> (-1.19%) ⬇️
... and 5 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 7a2eb8b...3aca9d0. Read the comment docs.

if datasource:
datasource_data["owners"] = datasource.owners_data
if isinstance(datasource, Query):
columns = datasource.extra.get("columns", [])
datasource_data["columns"] = datasource.extra.get("columns", [])
Copy link
Member

Choose a reason for hiding this comment

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

would it be easier to make a columns property of the Query model that does this?

@hughhhh hughhhh merged commit 9432c62 into apache:master May 31, 2022
philipher29 pushed a commit to ValtechMobility/superset that referenced this pull request Jun 9, 2022
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 2.0.0 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 size/XS 🚢 2.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants