Skip to content

fix: ensure engine is outside parameters#14787

Merged
betodealmeida merged 1 commit into
apache:masterfrom
betodealmeida:move_engine_outside_params
May 24, 2021
Merged

fix: ensure engine is outside parameters#14787
betodealmeida merged 1 commit into
apache:masterfrom
betodealmeida:move_engine_outside_params

Conversation

@betodealmeida
Copy link
Copy Markdown
Member

SUMMARY

In the new database modal flow we have 2 different flows:

  • In the old APIs (test_connection, add/edit DB) we expect engine inside parameters.
  • In the new API (validate_parameters) it should be outside.

It's better to have a consistent way, and it's also better to have engine outside of parameters, so I fixed the old APIs to support both initially, to prevent breaking the frontend. Later we can remove support for passing engine inside parameters and only accept it outside.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

N/A

TESTING INSTRUCTIONS

Tested manually.

ADDITIONAL INFORMATION

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

@betodealmeida betodealmeida requested a review from hughhhh May 24, 2021 17:13
@betodealmeida betodealmeida force-pushed the move_engine_outside_params branch from 5016072 to 1fe023b Compare May 24, 2021 17:15
Comment thread superset/databases/schemas.py Outdated
Comment on lines 273 to 277
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I moved this closer to where is needed, to prevent us from running this if not necessary.

@betodealmeida betodealmeida force-pushed the move_engine_outside_params branch from 1fe023b to 8574282 Compare May 24, 2021 17:37
@codecov
Copy link
Copy Markdown

codecov Bot commented May 24, 2021

Codecov Report

Merging #14787 (8574282) into master (e9657af) will decrease coverage by 0.24%.
The diff coverage is 77.77%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #14787      +/-   ##
==========================================
- Coverage   77.54%   77.30%   -0.25%     
==========================================
  Files         962      962              
  Lines       49147    49148       +1     
  Branches     6182     6182              
==========================================
- Hits        38111    37993     -118     
- Misses      10832    10951     +119     
  Partials      204      204              
Flag Coverage Δ
hive ?
mysql 81.62% <77.77%> (-0.01%) ⬇️
postgres 81.65% <77.77%> (-0.01%) ⬇️
presto ?
python 81.73% <77.77%> (-0.46%) ⬇️
sqlite 81.27% <77.77%> (+<0.01%) ⬆️

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

Impacted Files Coverage Δ
superset/databases/schemas.py 98.71% <77.77%> (-0.86%) ⬇️
superset/db_engines/hive.py 0.00% <0.00%> (-82.15%) ⬇️
superset/db_engine_specs/hive.py 70.32% <0.00%> (-17.08%) ⬇️
superset/db_engine_specs/presto.py 83.36% <0.00%> (-6.95%) ⬇️
superset/views/database/mixins.py 81.03% <0.00%> (-1.73%) ⬇️
superset/connectors/sqla/models.py 88.08% <0.00%> (-1.67%) ⬇️
superset/db_engine_specs/base.py 87.90% <0.00%> (-0.41%) ⬇️
superset/models/core.py 89.70% <0.00%> (-0.27%) ⬇️
superset/utils/core.py 88.91% <0.00%> (-0.13%) ⬇️

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 e9657af...8574282. Read the comment docs.

@betodealmeida betodealmeida merged commit 33cee65 into apache:master May 24, 2021
amitmiran137 pushed a commit to nielsen-oss/superset that referenced this pull request May 25, 2021
* master: (163 commits)
  fix(native-filters): Manage default value of filters by superset (apache#14785)
  fix: Additional ResultSet tests (apache#14741)
  chore: added BasicParametersMixin to Redshift (apache#14752)
  fix: make dataset list sort case insensitive (apache#14528)
  fix: use encodeURIComponent when getting table metadata (apache#14790)
  fix: ensure engine is outside parameters (apache#14787)
  database modal should close on connect with tab layout (apache#14771)
  feat(native-filters): add search all filter options (apache#14710)
  fix: extra query in Dashboard when native filter enabled (apache#14770)
  chore: Improves the native filters UI/UX - iteration 2 (apache#14753)
  fix(native filters): Fix explore state (apache#14779)
  fix(explore): DndColumnSelect not handling controls with "multi: false" (apache#14737)
  feat: Create BigQuery Parameters for DatabaseModal (apache#14721)
  feat: enable user impersonation in GSheets (apache#14767)
  fix: add DB should not say it's Postgres (apache#14766)
  Revert "fix(dashboard): multiple query trigger when native filter enabled (apache#14734)" (apache#14762)
  feat: save database with new dynamic form (apache#14583)
  fix: save non-parameter DBs (apache#14759)
  chore: Removes ColorSchemeControl.less (apache#14199)
  fix(explore): Icons width (apache#14717)
  ...
cccs-RyanS pushed a commit to CybercentreCanada/superset that referenced this pull request Dec 17, 2021
QAlexBall pushed a commit to QAlexBall/superset that referenced this pull request Dec 29, 2021
cccs-rc pushed a commit to CybercentreCanada/superset that referenced this pull request Mar 6, 2024
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.3.0 First shipped in 1.3.0 labels Mar 12, 2024
qfcwell pushed a commit to qfcwell/superset that referenced this pull request May 12, 2026
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/S 🚢 1.3.0 First shipped in 1.3.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants