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

feat: DBC UI Snowflake Form #16856

Merged
merged 14 commits into from
Oct 17, 2021
Merged

feat: DBC UI Snowflake Form #16856

merged 14 commits into from
Oct 17, 2021

Conversation

hughhhh
Copy link
Member

@hughhhh hughhhh commented Sep 27, 2021

SUMMARY

Created a dynamic form for snowflake

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

Screen Shot 2021-10-15 at 4 41 35 PM

TESTING INSTRUCTIONS

  1. Goto Databases
  2. Click + Database in the top right corner
  3. Click Snowflake as db option
  4. Fill out information
  5. Click connect
  6. Then click finish

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

@codecov
Copy link

codecov bot commented Sep 27, 2021

Codecov Report

Merging #16856 (1d0d237) into master (40e9add) will increase coverage by 0.45%.
The diff coverage is 58.11%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #16856      +/-   ##
==========================================
+ Coverage   76.77%   77.22%   +0.45%     
==========================================
  Files        1031     1035       +4     
  Lines       55197    56468    +1271     
  Branches     7506     7681     +175     
==========================================
+ Hits        42379    43610    +1231     
- Misses      12566    12606      +40     
  Partials      252      252              
Flag Coverage Δ
hive 81.79% <65.30%> (+0.31%) ⬆️
javascript 71.04% <55.63%> (+0.14%) ⬆️
mysql 82.23% <65.30%> (?)
postgres 82.24% <65.30%> (?)
presto 81.77% <65.30%> (?)
python 82.72% <65.30%> (+0.58%) ⬆️
sqlite 81.92% <65.30%> (+0.31%) ⬆️

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

Impacted Files Coverage Δ
...set-frontend/src/views/CRUD/data/database/types.ts 100.00% <ø> (ø)
...aseModal/DatabaseConnectionForm/EncryptedField.tsx 23.63% <23.63%> (ø)
...abaseModal/DatabaseConnectionForm/TableCatalog.tsx 30.43% <30.43%> (ø)
...dal/DatabaseConnectionForm/ValidatedInputField.tsx 62.50% <62.50%> (ø)
superset/db_engine_specs/snowflake.py 76.10% <65.30%> (-8.97%) ⬇️
...eModal/DatabaseConnectionForm/CommonParameters.tsx 94.44% <94.44%> (ø)
...ase/DatabaseModal/DatabaseConnectionForm/index.tsx 100.00% <100.00%> (ø)
...controls/FilterControl/AdhocFilterOption/index.jsx 100.00% <0.00%> (ø)
superset/reports/commands/execute.py 91.22% <0.00%> (+0.38%) ⬆️
superset/db_engine_specs/base.py 88.56% <0.00%> (+0.38%) ⬆️
... and 29 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 40e9add...1d0d237. Read the comment docs.

* snowflake frontend

* snowflake frontend
@pull-request-size pull-request-size bot added size/L and removed size/M labels Sep 27, 2021
@hughhhh hughhhh changed the title feat: DBC UI Snowflake Form feat: DBC UI Snowflake Form [WIP] Sep 28, 2021
hughhhh and others added 3 commits September 29, 2021 10:42
* moved all non-BasicParameters into own field

* refactored DB Connection Form made ValidatedInput
@hughhhh
Copy link
Member Author

hughhhh commented Sep 30, 2021

/testenv up

@github-actions
Copy link
Contributor

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

@hughhhh hughhhh changed the title feat: DBC UI Snowflake Form [WIP] feat: DBC UI Snowflake Form Oct 1, 2021
{showCredentialsInfo && (
<>
<FormLabel required>
{t('How∂ do you want to enter service account credentials?')}
Copy link
Member

Choose a reason for hiding this comment

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

nit, weird character after How here

: db?.parameters?.[encryptedField];
return (
<CredentialInfoForm>
{db?.engine === 'gsheets' && (
Copy link
Member

Choose a reason for hiding this comment

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

did we ever find a way not to compare engines but do this more programmatically based on db attributes?

Copy link
Member Author

Choose a reason for hiding this comment

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

We did find out a way to apply attributes via the api, we just havent implemented it. @AAfghahi is working on that now with athena and then we can incorporate it into the other engines

Copy link
Member

Choose a reason for hiding this comment

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

Super!

Copy link
Member

@eschutho eschutho left a comment

Choose a reason for hiding this comment

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

Looks much cleaner!

@hughhhh hughhhh merged commit 40b88f0 into master Oct 17, 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
* update snowflake spec for dyanmic form

* feat(snowflake): Snowflake dynamic form (apache#16861)

* snowflake frontend

* snowflake frontend

* refactor(DB Connections): Build Snowflake Dynamic Form (apache#16875)

* moved all non-BasicParameters into own field

* refactored DB Connection Form made ValidatedInput

* quick fix

* fixed ValidatedInputField (apache#16934)

* add logic to check for required fields (apache#17022)

* fix

* fix linting

* remove host

* Update EncryptedField.tsx

Co-authored-by: AAfghahi <48933336+AAfghahi@users.noreply.github.com>
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.5.0 labels Mar 13, 2024
@mistercrunch mistercrunch deleted the pexdax/snowflake branch March 26, 2024 16:15
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/XXL 🚢 1.5.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants