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(import): Show the error message with db install guide when exist the importing db issue #20573

Merged
merged 2 commits into from
Jul 6, 2022

Conversation

prosdev0107
Copy link
Contributor

SUMMARY

Add error message when user tries to import without having db driver installed

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

BEFORE:
Clipboard 2022-23-06 at 11 02 20 PM
Clipboard 2022-23-06 at 11 02 45 PM

AFTER:

import-resource.mov

TESTING INSTRUCTIONS

  1. Go to Connect Database Modal
  2. Select the import database from invalid file.

In case of Invaid db file with already installed driver
In case of invaoide db fiel with not installed driver

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

@@ -51,6 +51,7 @@ const ErrorAlert: FunctionComponent<IProps> = ({
{t(
'Database driver for importing maybe not installed. Visit the Superset documentation page for installation instructions:',
)}
&nbsp;&nbsp;

Choose a reason for hiding this comment

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

Wondering why not using css on the anchor or span to space out?

@yousoph
Copy link
Member

yousoph commented Jun 30, 2022

/testenv up

@codecov
Copy link

codecov bot commented Jun 30, 2022

Codecov Report

Merging #20573 (b91fe70) into master (90d486a) will decrease coverage by 0.02%.
The diff coverage is 23.80%.

@@            Coverage Diff             @@
##           master   #20573      +/-   ##
==========================================
- Coverage   66.71%   66.68%   -0.03%     
==========================================
  Files        1752     1754       +2     
  Lines       65478    65588     +110     
  Branches     6916     6935      +19     
==========================================
+ Hits        43681    43740      +59     
- Misses      20049    20092      +43     
- Partials     1748     1756       +8     
Flag Coverage Δ
javascript 51.81% <23.80%> (+<0.01%) ⬆️

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

Impacted Files Coverage Δ
...frontend/src/components/ImportModal/ErrorAlert.tsx 33.33% <ø> (ø)
superset-frontend/src/views/CRUD/hooks.ts 46.56% <ø> (ø)
...c/views/CRUD/data/database/DatabaseModal/index.tsx 32.04% <23.80%> (-0.04%) ⬇️
...preset-chart-deckgl/src/layers/Hex/controlPanel.ts 50.00% <0.00%> (-50.00%) ⬇️
...reset-chart-deckgl/src/layers/Grid/controlPanel.ts 50.00% <0.00%> (-50.00%) ⬇️
...chart-deckgl/src/layers/Screengrid/controlPanel.ts 50.00% <0.00%> (-50.00%) ⬇️
...et-chart-deckgl/src/layers/Polygon/controlPanel.ts 33.33% <0.00%> (-16.67%) ⬇️
...rontend/src/explore/reducers/datasourcesReducer.ts 20.00% <0.00%> (-13.34%) ⬇️
...-frontend/src/explore/reducers/saveModalReducer.js 30.00% <0.00%> (-3.34%) ⬇️
...perset-frontend/src/addSlice/AddSliceContainer.tsx 66.66% <0.00%> (-1.52%) ⬇️
... and 26 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 90d486a...b91fe70. Read the comment docs.

@github-actions
Copy link
Contributor

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

@yousoph
Copy link
Member

yousoph commented Jun 30, 2022

A few text updates needed:
When the error shows up on the password screen:
image
Period missing before "Please" and there's an extra space between the : and here

When the error shows up on the db connection screen, a period is also missing before "Please"
image

@prosdev0107
Copy link
Contributor Author

@yousoph
Resolved your review. Please kindly check this.

@yousoph
Copy link
Member

yousoph commented Jul 1, 2022

/testenv up

@github-actions
Copy link
Contributor

github-actions bot commented Jul 1, 2022

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

Copy link
Member

@Antonio-RiveroMartnez Antonio-RiveroMartnez left a comment

Choose a reason for hiding this comment

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

LGTM!

@rusackas rusackas merged commit c992ff3 into apache:master Jul 6, 2022
@github-actions
Copy link
Contributor

github-actions bot commented Jul 6, 2022

Ephemeral environment shutdown and build artifacts deleted.

codyml pushed a commit to codyml/superset that referenced this pull request Jul 7, 2022
…the importing db issue (apache#20573)

* fix(import): make to update the error display when importing resurce

* fix(import): make to update the error message
akshatsri pushed a commit to charan1314/superset that referenced this pull request Jul 19, 2022
…the importing db issue (apache#20573)

* fix(import): make to update the error display when importing resurce

* fix(import): make to update the error message
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 2.1.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 Preset-Patch size/M 🚢 2.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants