You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2020/12/04 03:49:53 UTC

[GitHub] [incubator-superset] betodealmeida opened a new pull request #11924: feat: add modal to import dashboards

betodealmeida opened a new pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924


   ### SUMMARY
   <!--- Describe the change below, including rationale and design decisions -->
   
   Identical to https://github.com/apache/incubator-superset/pull/11923/files, but for charts.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   <!--- Skip this if not applicable -->
   
   ![2020-12-03-194846_772x242_scrot](https://user-images.githubusercontent.com/1534870/101119617-9376ad80-35a0-11eb-8230-a22ebf94f39d.png)
   
   
   ### TEST PLAN
   <!--- What steps should be taken to verify the changes -->
   
   Tested importing dashboard to an existing database/chart, as well as a dashboard to a new database, works as expected.
   
   Also added tests.
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [X] Has associated issue: https://github.com/apache/incubator-superset/issues/11167
   - [ ] Changes UI
   - [ ] Requires DB Migration.
   - [ ] Confirm DB Migration upgrade and downgrade tested.
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] eschutho commented on a change in pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
eschutho commented on a change in pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#discussion_r537947981



##########
File path: superset-frontend/src/dashboard/components/ImportModal/ImportModal.test.tsx
##########
@@ -0,0 +1,106 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import React from 'react';
+import thunk from 'redux-thunk';

Review comment:
       do we still need this?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (89bbdcf) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `4.11%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   63.58%   -4.12%     
   ==========================================
     Files         940      465     -475     
     Lines       45586    28584   -17002     
     Branches     4378        0    -4378     
   ==========================================
   - Hits        30861    18176   -12685     
   + Misses      14622    10408    -4214     
   + Partials      103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.58% <86.66%> (-0.66%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/sql\_validators/postgres.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvc3FsX3ZhbGlkYXRvcnMvcG9zdGdyZXMucHk=) | `50.00% <0.00%> (-50.00%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.61% <0.00%> (-29.62%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `69.95% <0.00%> (-12.45%)` | :arrow_down: |
   | [superset/db\_engine\_specs/sqlite.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3NxbGl0ZS5weQ==) | `65.62% <0.00%> (-9.38%)` | :arrow_down: |
   | ... and [491 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (89bbdcf) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `4.16%`.
   > The diff coverage is `65.78%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   63.52%   -4.17%     
   ==========================================
     Files         940      941       +1     
     Lines       45586    45648      +62     
     Branches     4378     4388      +10     
   ==========================================
   - Hits        30861    29000    -1861     
   - Misses      14622    16471    +1849     
   - Partials      103      177      +74     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `62.90% <60.65%> (-0.01%)` | :arrow_down: |
   | python | `63.90% <86.66%> (-0.35%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `69.15% <41.66%> (-8.74%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `65.30% <65.30%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset-frontend/src/SqlLab/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9BcHAuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [superset-frontend/src/explore/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvQXBwLmpzeA==) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [superset-frontend/src/dashboard/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9BcHAuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | ... and [179 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (89bbdcf) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `4.36%`.
   > The diff coverage is `65.78%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   63.33%   -4.37%     
   ==========================================
     Files         940      941       +1     
     Lines       45586    45633      +47     
     Branches     4378     4388      +10     
   ==========================================
   - Hits        30861    28901    -1960     
   - Misses      14622    16555    +1933     
   - Partials      103      177      +74     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `62.90% <60.65%> (-0.01%)` | :arrow_down: |
   | python | `63.58% <86.66%> (-0.66%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `69.15% <41.66%> (-8.74%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `65.30% <65.30%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset-frontend/src/SqlLab/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9BcHAuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [superset-frontend/src/explore/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvQXBwLmpzeA==) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [superset-frontend/src/dashboard/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9BcHAuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | ... and [198 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (33ecffb) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `4.63%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   63.44%   -4.64%     
   ===========================================
     Files          939      459     -480     
     Lines        48362    28171   -20191     
     Branches      4862        0    -4862     
   ===========================================
   - Hits         32927    17874   -15053     
   + Misses       15332    10297    -5035     
   + Partials       103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.44% <86.66%> (-2.14%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.08% <0.00%> (-32.09%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `69.76% <0.00%> (-12.65%)` | :arrow_down: |
   | [superset/dashboards/commands/importers/v0.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjAucHk=) | `80.51% <0.00%> (-12.34%)` | :arrow_down: |
   | [superset/views/sql\_lab.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3Mvc3FsX2xhYi5weQ==) | `59.57% <0.00%> (-9.85%)` | :arrow_down: |
   | ... and [518 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...33ecffb](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] eschutho commented on a change in pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
eschutho commented on a change in pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#discussion_r537949782



##########
File path: superset-frontend/src/views/CRUD/dashboard/types.ts
##########
@@ -0,0 +1,26 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+export type DashboardObject = {

Review comment:
       just as an fyi, there are also some types in `src/types`. We may want to move everything there eventually. 




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (89bbdcf) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `3.94%`.
   > The diff coverage is `65.78%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   63.75%   -3.95%     
   ==========================================
     Files         940      941       +1     
     Lines       45586    45648      +62     
     Branches     4378     4388      +10     
   ==========================================
   - Hits        30861    29102    -1759     
   - Misses      14622    16369    +1747     
   - Partials      103      177      +74     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `62.90% <60.65%> (-0.01%)` | :arrow_down: |
   | python | `64.25% <86.66%> (+0.01%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `69.15% <41.66%> (-8.74%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `65.30% <65.30%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset-frontend/src/SqlLab/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9BcHAuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [superset-frontend/src/explore/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvQXBwLmpzeA==) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [superset-frontend/src/dashboard/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9BcHAuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | ... and [176 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] betodealmeida commented on a change in pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
betodealmeida commented on a change in pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#discussion_r537995324



##########
File path: superset-frontend/src/views/CRUD/dashboard/types.ts
##########
@@ -0,0 +1,26 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+export type DashboardObject = {

Review comment:
       Yeah, I feel we should have a way of automatically generating these and `schema.py` from a single source of truth.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (b2fee54) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `4.05%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   63.64%   -4.06%     
   ==========================================
     Files         940      465     -475     
     Lines       45586    28584   -17002     
     Branches     4378        0    -4378     
   ==========================================
   - Hits        30861    18192   -12669     
   + Misses      14622    10392    -4230     
   + Partials      103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.64% <86.66%> (-0.61%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.61% <0.00%> (-29.62%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `69.95% <0.00%> (-12.45%)` | :arrow_down: |
   | [superset/db\_engine\_specs/sqlite.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3NxbGl0ZS5weQ==) | `65.62% <0.00%> (-9.38%)` | :arrow_down: |
   | [superset/utils/celery.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdXRpbHMvY2VsZXJ5LnB5) | `96.42% <0.00%> (-3.58%)` | :arrow_down: |
   | ... and [488 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (b2fee54) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `3.44%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   64.25%   -3.45%     
   ==========================================
     Files         940      465     -475     
     Lines       45586    28599   -16987     
     Branches     4378        0    -4378     
   ==========================================
   - Hits        30861    18377   -12484     
   + Misses      14622    10222    -4400     
   + Partials      103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `64.25% <86.66%> (+0.01%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [...nd/src/dashboard/util/getDetailedComponentWidth.js](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC91dGlsL2dldERldGFpbGVkQ29tcG9uZW50V2lkdGguanM=) | | |
   | [superset-frontend/src/components/Select/styles.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvU2VsZWN0L3N0eWxlcy50c3g=) | | |
   | [superset-frontend/src/dashboard/index.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9pbmRleC5qc3g=) | | |
   | [...rontend/src/SqlLab/components/SqlEditorLeftBar.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1NxbEVkaXRvckxlZnRCYXIuanN4) | | |
   | [.../src/components/dataViewCommon/TableCollection.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvZGF0YVZpZXdDb21tb24vVGFibGVDb2xsZWN0aW9uLnRzeA==) | | |
   | ... and [469 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] betodealmeida commented on a change in pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
betodealmeida commented on a change in pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#discussion_r537994097



##########
File path: superset-frontend/src/dashboard/components/ImportModal/index.tsx
##########
@@ -0,0 +1,190 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import React, { FunctionComponent, useEffect, useRef, useState } from 'react';
+import { t } from '@superset-ui/core';
+
+import Modal from 'src/common/components/Modal';
+import {
+  StyledIcon,
+  StyledInputContainer,
+} from 'src/views/CRUD/data/database/DatabaseModal';
+import { useImportResource } from 'src/views/CRUD/hooks';
+import { DashboardObject } from 'src/views/CRUD/dashboard/types';
+
+export interface ImportDashboardModalProps {
+  addDangerToast: (msg: string) => void;
+  addSuccessToast: (msg: string) => void;
+  onDashboardImport: () => void;
+  show: boolean;
+  onHide: () => void;
+  passwordFields?: string[];
+  setPasswordFields?: (passwordFields: string[]) => void;
+}
+
+const ImportDashboardModal: FunctionComponent<ImportDashboardModalProps> = ({
+  addDangerToast,
+  addSuccessToast,
+  onDashboardImport,
+  show,
+  onHide,
+  passwordFields = [],
+  setPasswordFields = () => {},
+}) => {
+  const [uploadFile, setUploadFile] = useState<File | null>(null);
+  const [isHidden, setIsHidden] = useState<boolean>(true);
+  const [passwords, setPasswords] = useState<Record<string, string>>({});
+  const fileInputRef = useRef<HTMLInputElement>(null);
+
+  const clearModal = () => {
+    setUploadFile(null);
+    setPasswordFields([]);
+    setPasswords({});
+    if (fileInputRef && fileInputRef.current) {
+      fileInputRef.current.value = '';
+    }
+  };
+
+  const handleErrorMsg = (msg: string) => {
+    clearModal();
+    addDangerToast(msg);
+  };
+
+  const {
+    state: { passwordsNeeded },
+    importResource,
+  } = useImportResource<DashboardObject>(
+    'dashboard',
+    t('dashboard'),
+    handleErrorMsg,
+  );
+
+  useEffect(() => {
+    setPasswordFields(passwordsNeeded);
+  }, [passwordsNeeded]);
+
+  // Functions
+  const hide = () => {
+    setIsHidden(true);
+    onHide();
+  };
+
+  const onUpload = () => {
+    if (uploadFile === null) {
+      return;
+    }
+
+    importResource(uploadFile, passwords).then(result => {
+      if (result) {

Review comment:
       Actually no, if there's a validation error other than password needed the `importResource` will
   
   - show a danger toast
   - not set `passwordFields`
   - return `false`
   
   So having an empty `passwordFields` does not guarantee success. This is because there's 3 states:
   
   1. Upload OK (returns `true` and `passwordFields` is empty)
   2. File validated but needs password (returns `false` and `passwordFields` is set)
   3. Validation failed in other ways (returns `false` and `passwordFields` is empty)




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (b2fee54) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `0.16%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   63.75%   63.58%   -0.17%     
   ==========================================
     Files         940      465     -475     
     Lines       45576    28584   -16992     
     Branches     4378        0    -4378     
   ==========================================
   - Hits        29055    18176   -10879     
   + Misses      16344    10408    -5936     
   + Partials      177        0     -177     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | javascript | `?` | |
   | python | `63.58% <86.66%> (-0.66%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/sql\_validators/postgres.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvc3FsX3ZhbGlkYXRvcnMvcG9zdGdyZXMucHk=) | `50.00% <0.00%> (-50.00%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.61% <0.00%> (-29.62%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `69.95% <0.00%> (-12.45%)` | :arrow_down: |
   | [superset/db\_engine\_specs/sqlite.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3NxbGl0ZS5weQ==) | `65.62% <0.00%> (-9.38%)` | :arrow_down: |
   | ... and [491 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] betodealmeida merged pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
betodealmeida merged pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (b2fee54) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `3.44%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   64.25%   -3.45%     
   ==========================================
     Files         940      465     -475     
     Lines       45586    28599   -16987     
     Branches     4378        0    -4378     
   ==========================================
   - Hits        30861    18377   -12484     
   + Misses      14622    10222    -4400     
   + Partials      103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `64.25% <86.66%> (+0.01%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [...ontend/src/dashboard/util/getDashboardFilterKey.ts](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC91dGlsL2dldERhc2hib2FyZEZpbHRlcktleS50cw==) | | |
   | [...et-frontend/src/dashboard/util/isDashboardEmpty.ts](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC91dGlsL2lzRGFzaGJvYXJkRW1wdHkudHM=) | | |
   | [.../src/explore/components/FilterDefinitionOption.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9GaWx0ZXJEZWZpbml0aW9uT3B0aW9uLmpzeA==) | | |
   | [...src/components/FilterableTable/FilterableTable.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvRmlsdGVyYWJsZVRhYmxlL0ZpbHRlcmFibGVUYWJsZS50c3g=) | | |
   | [...d/src/dashboard/components/FiltersBadge/Styles.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ZpbHRlcnNCYWRnZS9TdHlsZXMudHN4) | | |
   | ... and [469 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] eschutho commented on a change in pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
eschutho commented on a change in pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#discussion_r537948085



##########
File path: superset-frontend/src/dashboard/components/ImportModal/index.tsx
##########
@@ -0,0 +1,190 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import React, { FunctionComponent, useEffect, useRef, useState } from 'react';
+import { t } from '@superset-ui/core';
+
+import Modal from 'src/common/components/Modal';
+import {
+  StyledIcon,
+  StyledInputContainer,
+} from 'src/views/CRUD/data/database/DatabaseModal';
+import { useImportResource } from 'src/views/CRUD/hooks';
+import { DashboardObject } from 'src/views/CRUD/dashboard/types';
+
+export interface ImportDashboardModalProps {
+  addDangerToast: (msg: string) => void;
+  addSuccessToast: (msg: string) => void;
+  onDashboardImport: () => void;
+  show: boolean;
+  onHide: () => void;
+  passwordFields?: string[];
+  setPasswordFields?: (passwordFields: string[]) => void;
+}
+
+const ImportDashboardModal: FunctionComponent<ImportDashboardModalProps> = ({
+  addDangerToast,
+  addSuccessToast,
+  onDashboardImport,
+  show,
+  onHide,
+  passwordFields = [],
+  setPasswordFields = () => {},
+}) => {
+  const [uploadFile, setUploadFile] = useState<File | null>(null);
+  const [isHidden, setIsHidden] = useState<boolean>(true);
+  const [passwords, setPasswords] = useState<Record<string, string>>({});
+  const fileInputRef = useRef<HTMLInputElement>(null);
+
+  const clearModal = () => {
+    setUploadFile(null);
+    setPasswordFields([]);
+    setPasswords({});
+    if (fileInputRef && fileInputRef.current) {
+      fileInputRef.current.value = '';
+    }
+  };
+
+  const handleErrorMsg = (msg: string) => {
+    clearModal();
+    addDangerToast(msg);
+  };
+
+  const {
+    state: { passwordsNeeded },
+    importResource,
+  } = useImportResource<DashboardObject>(
+    'dashboard',
+    t('dashboard'),
+    handleErrorMsg,
+  );
+
+  useEffect(() => {
+    setPasswordFields(passwordsNeeded);
+  }, [passwordsNeeded]);
+
+  // Functions
+  const hide = () => {
+    setIsHidden(true);
+    onHide();
+  };
+
+  const onUpload = () => {
+    if (uploadFile === null) {
+      return;
+    }
+
+    importResource(uploadFile, passwords).then(result => {
+      if (result) {

Review comment:
       small nit, but you could also check the passwordFields state here, right, instead of returning it in the result?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (fc34750) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `0.62%`.
   > The diff coverage is `65.78%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   67.46%   -0.63%     
   ===========================================
     Files          939      920      -19     
     Lines        48362    44819    -3543     
     Branches      4862     4246     -616     
   ===========================================
   - Hits         32927    30235    -2692     
   + Misses       15332    14481     -851     
     Partials       103      103              
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `54.82% <42.59%> (-0.26%)` | :arrow_down: |
   | javascript | `62.81% <60.65%> (+0.12%)` | :arrow_up: |
   | python | `64.04% <86.66%> (-1.54%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `73.83% <41.66%> (-4.07%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `65.30% <65.30%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/dashboards/commands/importers/v0.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjAucHk=) | `80.51% <0.00%> (-12.34%)` | :arrow_down: |
   | [...rontend/src/visualizations/FilterBox/FilterBox.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3Zpc3VhbGl6YXRpb25zL0ZpbHRlckJveC9GaWx0ZXJCb3guanN4) | `58.12% <0.00%> (-10.63%)` | :arrow_down: |
   | [superset/views/sql\_lab.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3Mvc3FsX2xhYi5weQ==) | `59.57% <0.00%> (-9.85%)` | :arrow_down: |
   | ... and [102 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...fc34750](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (fc34750) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `7.97%`.
   > The diff coverage is `52.17%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   60.10%   -7.98%     
   ===========================================
     Files          939      874      -65     
     Lines        48362    42996    -5366     
     Branches      4862     3793    -1069     
   ===========================================
   - Hits         32927    25844    -7083     
   - Misses       15332    17152    +1820     
   + Partials       103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `54.23% <42.59%> (-0.85%)` | :arrow_down: |
   | javascript | `?` | |
   | python | `63.19% <86.66%> (-2.39%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `67.41% <36.36%> (-10.48%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `44.18% <44.18%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [...uperset-frontend/src/dashboard/util/dnd-reorder.js](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC91dGlsL2RuZC1yZW9yZGVyLmpz) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...rset-frontend/src/dashboard/util/getEmptyLayout.js](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC91dGlsL2dldEVtcHR5TGF5b3V0Lmpz) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...dashboard/components/resizable/ResizableHandle.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL3Jlc2l6YWJsZS9SZXNpemFibGVIYW5kbGUuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | ... and [393 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...fc34750](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (b2fee54) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `4.01%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   63.67%   -4.02%     
   ==========================================
     Files         940      465     -475     
     Lines       45586    28584   -17002     
     Branches     4378        0    -4378     
   ==========================================
   - Hits        30861    18202   -12659     
   + Misses      14622    10382    -4240     
   + Partials      103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.67% <86.66%> (-0.57%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.61% <0.00%> (-29.62%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `69.95% <0.00%> (-12.45%)` | :arrow_down: |
   | [superset/examples/world\_bank.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZXhhbXBsZXMvd29ybGRfYmFuay5weQ==) | `97.10% <0.00%> (-2.90%)` | :arrow_down: |
   | [superset/examples/birth\_names.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZXhhbXBsZXMvYmlydGhfbmFtZXMucHk=) | `96.51% <0.00%> (-2.33%)` | :arrow_down: |
   | ... and [484 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (33ecffb) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `4.73%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   63.35%   -4.74%     
   ===========================================
     Files          939      459     -480     
     Lines        48362    28171   -20191     
     Branches      4862        0    -4862     
   ===========================================
   - Hits         32927    17847   -15080     
   + Misses       15332    10324    -5008     
   + Partials       103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.35% <86.66%> (-2.23%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.08% <0.00%> (-32.09%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `69.76% <0.00%> (-12.65%)` | :arrow_down: |
   | [superset/dashboards/commands/importers/v0.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjAucHk=) | `80.51% <0.00%> (-12.34%)` | :arrow_down: |
   | [superset/db\_engine\_specs/mysql.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL215c3FsLnB5) | `79.59% <0.00%> (-12.25%)` | :arrow_down: |
   | ... and [522 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...33ecffb](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655






----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] betodealmeida commented on a change in pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
betodealmeida commented on a change in pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#discussion_r537995007



##########
File path: superset-frontend/src/dashboard/components/ImportModal/index.tsx
##########
@@ -0,0 +1,190 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import React, { FunctionComponent, useEffect, useRef, useState } from 'react';
+import { t } from '@superset-ui/core';
+
+import Modal from 'src/common/components/Modal';
+import {
+  StyledIcon,
+  StyledInputContainer,
+} from 'src/views/CRUD/data/database/DatabaseModal';
+import { useImportResource } from 'src/views/CRUD/hooks';
+import { DashboardObject } from 'src/views/CRUD/dashboard/types';
+
+export interface ImportDashboardModalProps {
+  addDangerToast: (msg: string) => void;
+  addSuccessToast: (msg: string) => void;
+  onDashboardImport: () => void;
+  show: boolean;
+  onHide: () => void;
+  passwordFields?: string[];
+  setPasswordFields?: (passwordFields: string[]) => void;
+}
+
+const ImportDashboardModal: FunctionComponent<ImportDashboardModalProps> = ({
+  addDangerToast,
+  addSuccessToast,
+  onDashboardImport,
+  show,
+  onHide,
+  passwordFields = [],
+  setPasswordFields = () => {},
+}) => {
+  const [uploadFile, setUploadFile] = useState<File | null>(null);
+  const [isHidden, setIsHidden] = useState<boolean>(true);
+  const [passwords, setPasswords] = useState<Record<string, string>>({});
+  const fileInputRef = useRef<HTMLInputElement>(null);
+
+  const clearModal = () => {
+    setUploadFile(null);
+    setPasswordFields([]);
+    setPasswords({});
+    if (fileInputRef && fileInputRef.current) {
+      fileInputRef.current.value = '';
+    }
+  };
+
+  const handleErrorMsg = (msg: string) => {
+    clearModal();
+    addDangerToast(msg);
+  };
+
+  const {
+    state: { passwordsNeeded },
+    importResource,
+  } = useImportResource<DashboardObject>(
+    'dashboard',
+    t('dashboard'),
+    handleErrorMsg,
+  );
+
+  useEffect(() => {
+    setPasswordFields(passwordsNeeded);
+  }, [passwordsNeeded]);
+
+  // Functions
+  const hide = () => {
+    setIsHidden(true);
+    onHide();
+  };
+
+  const onUpload = () => {
+    if (uploadFile === null) {
+      return;
+    }
+
+    importResource(uploadFile, passwords).then(result => {
+      if (result) {
+        addSuccessToast(t('The dashboards have been imported'));
+        clearModal();
+        onDashboardImport();
+      }
+    });
+  };
+
+  const changeFile = (event: React.ChangeEvent<HTMLInputElement>) => {
+    const { files } = event.target as HTMLInputElement;
+    setUploadFile((files && files[0]) || null);
+  };
+
+  const renderPasswordFields = () => {
+    if (passwordFields.length === 0) {
+      return null;
+    }
+
+    return (
+      <>
+        <h5>Database passwords</h5>
+        <StyledInputContainer>
+          <div className="helper">
+            {t(
+              'The passwords for the databases below are needed in order to ' +
+                'import them together with the dashboards. Please note that the ' +
+                '"Secure Extra" and "Certificate" sections of ' +
+                'the database configuration are not present in export files, and ' +
+                'should be added manually after the import if they are needed.',
+            )}
+          </div>
+        </StyledInputContainer>
+        {passwordFields.map(fileName => (
+          <StyledInputContainer key={`password-for-${fileName}`}>
+            <div className="control-label">
+              {fileName}
+              <span className="required">*</span>
+            </div>
+            <input
+              name={`password-${fileName}`}
+              autoComplete="off"

Review comment:
       Cool, #TIL. I'll fix it in https://github.com/apache/incubator-superset/pull/11936https://github.com/apache/incubator-superset/pull/11936




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io commented on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io commented on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (33ecffb) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `4.73%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   63.35%   -4.74%     
   ===========================================
     Files          939      459     -480     
     Lines        48362    28169   -20193     
     Branches      4862        0    -4862     
   ===========================================
   - Hits         32927    17846   -15081     
   + Misses       15332    10323    -5009     
   + Partials       103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.35% <86.66%> (-2.23%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.08% <0.00%> (-32.09%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `69.76% <0.00%> (-12.65%)` | :arrow_down: |
   | [superset/dashboards/commands/importers/v0.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjAucHk=) | `80.51% <0.00%> (-12.34%)` | :arrow_down: |
   | [superset/db\_engine\_specs/mysql.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL215c3FsLnB5) | `79.59% <0.00%> (-12.25%)` | :arrow_down: |
   | ... and [523 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...33ecffb](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (33ecffb) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `4.69%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   63.39%   -4.70%     
   ===========================================
     Files          939      459     -480     
     Lines        48362    28171   -20191     
     Branches      4862        0    -4862     
   ===========================================
   - Hits         32927    17858   -15069     
   + Misses       15332    10313    -5019     
   + Partials       103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.39% <86.66%> (-2.19%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.08% <0.00%> (-32.09%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `69.76% <0.00%> (-12.65%)` | :arrow_down: |
   | [superset/dashboards/commands/importers/v0.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjAucHk=) | `80.51% <0.00%> (-12.34%)` | :arrow_down: |
   | [superset/db\_engine\_specs/mysql.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL215c3FsLnB5) | `79.59% <0.00%> (-12.25%)` | :arrow_down: |
   | ... and [519 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...33ecffb](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (33ecffb) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `4.20%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   63.88%   -4.21%     
   ===========================================
     Files          939      459     -480     
     Lines        48362    28171   -20191     
     Branches      4862        0    -4862     
   ===========================================
   - Hits         32927    17996   -14931     
   + Misses       15332    10175    -5157     
   + Partials       103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.88% <86.66%> (-1.70%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/dashboards/commands/importers/v0.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjAucHk=) | `80.51% <0.00%> (-12.34%)` | :arrow_down: |
   | [superset/views/sql\_lab.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3Mvc3FsX2xhYi5weQ==) | `59.57% <0.00%> (-9.85%)` | :arrow_down: |
   | [superset/datasets/commands/importers/v0.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGF0YXNldHMvY29tbWFuZHMvaW1wb3J0ZXJzL3YwLnB5) | `81.67% <0.00%> (-9.61%)` | :arrow_down: |
   | [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `73.65% <0.00%> (-8.76%)` | :arrow_down: |
   | [superset/databases/commands/delete.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGF0YWJhc2VzL2NvbW1hbmRzL2RlbGV0ZS5weQ==) | `89.65% <0.00%> (-8.02%)` | :arrow_down: |
   | ... and [516 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...33ecffb](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] eschutho commented on a change in pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
eschutho commented on a change in pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#discussion_r537948464



##########
File path: superset-frontend/src/dashboard/components/ImportModal/index.tsx
##########
@@ -0,0 +1,190 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import React, { FunctionComponent, useEffect, useRef, useState } from 'react';
+import { t } from '@superset-ui/core';
+
+import Modal from 'src/common/components/Modal';
+import {
+  StyledIcon,
+  StyledInputContainer,
+} from 'src/views/CRUD/data/database/DatabaseModal';
+import { useImportResource } from 'src/views/CRUD/hooks';
+import { DashboardObject } from 'src/views/CRUD/dashboard/types';
+
+export interface ImportDashboardModalProps {
+  addDangerToast: (msg: string) => void;
+  addSuccessToast: (msg: string) => void;
+  onDashboardImport: () => void;
+  show: boolean;
+  onHide: () => void;
+  passwordFields?: string[];
+  setPasswordFields?: (passwordFields: string[]) => void;
+}
+
+const ImportDashboardModal: FunctionComponent<ImportDashboardModalProps> = ({
+  addDangerToast,
+  addSuccessToast,
+  onDashboardImport,
+  show,
+  onHide,
+  passwordFields = [],
+  setPasswordFields = () => {},
+}) => {
+  const [uploadFile, setUploadFile] = useState<File | null>(null);
+  const [isHidden, setIsHidden] = useState<boolean>(true);
+  const [passwords, setPasswords] = useState<Record<string, string>>({});
+  const fileInputRef = useRef<HTMLInputElement>(null);
+
+  const clearModal = () => {
+    setUploadFile(null);
+    setPasswordFields([]);
+    setPasswords({});
+    if (fileInputRef && fileInputRef.current) {
+      fileInputRef.current.value = '';
+    }
+  };
+
+  const handleErrorMsg = (msg: string) => {
+    clearModal();
+    addDangerToast(msg);
+  };
+
+  const {
+    state: { passwordsNeeded },
+    importResource,
+  } = useImportResource<DashboardObject>(
+    'dashboard',
+    t('dashboard'),
+    handleErrorMsg,
+  );
+
+  useEffect(() => {
+    setPasswordFields(passwordsNeeded);
+  }, [passwordsNeeded]);
+
+  // Functions
+  const hide = () => {
+    setIsHidden(true);
+    onHide();
+  };
+
+  const onUpload = () => {
+    if (uploadFile === null) {
+      return;
+    }
+
+    importResource(uploadFile, passwords).then(result => {
+      if (result) {
+        addSuccessToast(t('The dashboards have been imported'));
+        clearModal();
+        onDashboardImport();
+      }
+    });
+  };
+
+  const changeFile = (event: React.ChangeEvent<HTMLInputElement>) => {
+    const { files } = event.target as HTMLInputElement;
+    setUploadFile((files && files[0]) || null);
+  };
+
+  const renderPasswordFields = () => {
+    if (passwordFields.length === 0) {
+      return null;
+    }
+
+    return (
+      <>
+        <h5>Database passwords</h5>
+        <StyledInputContainer>
+          <div className="helper">
+            {t(
+              'The passwords for the databases below are needed in order to ' +
+                'import them together with the dashboards. Please note that the ' +
+                '"Secure Extra" and "Certificate" sections of ' +
+                'the database configuration are not present in export files, and ' +
+                'should be added manually after the import if they are needed.',
+            )}
+          </div>
+        </StyledInputContainer>
+        {passwordFields.map(fileName => (
+          <StyledInputContainer key={`password-for-${fileName}`}>
+            <div className="control-label">
+              {fileName}
+              <span className="required">*</span>
+            </div>
+            <input
+              name={`password-${fileName}`}
+              autoComplete="off"

Review comment:
       this may not work for Chrome. You may want to try something like `autoComplete="new-password"`




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (89bbdcf) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `4.33%`.
   > The diff coverage is `65.78%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   63.36%   -4.34%     
   ==========================================
     Files         940      941       +1     
     Lines       45586    45648      +62     
     Branches     4378     4388      +10     
   ==========================================
   - Hits        30861    28924    -1937     
   - Misses      14622    16547    +1925     
   - Partials      103      177      +74     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `62.90% <60.65%> (-0.01%)` | :arrow_down: |
   | python | `63.63% <86.66%> (-0.62%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `69.15% <41.66%> (-8.74%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `65.30% <65.30%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset-frontend/src/SqlLab/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9BcHAuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [superset-frontend/src/explore/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvQXBwLmpzeA==) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [superset-frontend/src/dashboard/App.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9BcHAuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | ... and [188 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (fc34750) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `4.88%`.
   > The diff coverage is `86.66%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   63.19%   -4.89%     
   ===========================================
     Files          939      459     -480     
     Lines        48362    28169   -20193     
     Branches      4862        0    -4862     
   ===========================================
   - Hits         32927    17802   -15125     
   + Misses       15332    10367    -4965     
   + Partials       103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `?` | |
   | javascript | `?` | |
   | python | `63.19% <86.66%> (-2.39%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [superset/db\_engines/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lcy9oaXZlLnB5) | `0.00% <0.00%> (-85.72%)` | :arrow_down: |
   | [superset/db\_engine\_specs/hive.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2hpdmUucHk=) | `54.08% <0.00%> (-32.09%)` | :arrow_down: |
   | [superset/dashboards/commands/importers/v0.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjAucHk=) | `80.51% <0.00%> (-12.34%)` | :arrow_down: |
   | [superset/db\_engine\_specs/mysql.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL215c3FsLnB5) | `79.59% <0.00%> (-12.25%)` | :arrow_down: |
   | [superset/views/sql\_lab.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3Mvc3FsX2xhYi5weQ==) | `59.57% <0.00%> (-9.85%)` | :arrow_down: |
   | ... and [527 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...fc34750](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] betodealmeida commented on a change in pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
betodealmeida commented on a change in pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#discussion_r537994199



##########
File path: superset-frontend/src/dashboard/components/ImportModal/ImportModal.test.tsx
##########
@@ -0,0 +1,106 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import React from 'react';
+import thunk from 'redux-thunk';

Review comment:
       I'll remove in https://github.com/apache/incubator-superset/pull/11936




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (89bbdcf) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **increase** coverage by `0.00%`.
   > The diff coverage is `65.78%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master   #11924   +/-   ##
   =======================================
     Coverage   67.69%   67.70%           
   =======================================
     Files         940      941    +1     
     Lines       45586    45658   +72     
     Branches     4378     4388   +10     
   =======================================
   + Hits        30861    30911   +50     
   - Misses      14622    14644   +22     
     Partials      103      103           
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `54.75% <42.59%> (-0.02%)` | :arrow_down: |
   | javascript | `62.90% <60.65%> (-0.01%)` | :arrow_down: |
   | python | `64.25% <86.66%> (+0.01%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `73.83% <41.66%> (-4.07%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `65.30% <65.30%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [...set-frontend/src/dashboard/util/getDropPosition.js](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC91dGlsL2dldERyb3BQb3NpdGlvbi5qcw==) | `93.65% <0.00%> (+1.58%)` | :arrow_up: |
   | [...ntend/src/dashboard/components/PropertiesModal.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL1Byb3BlcnRpZXNNb2RhbC5qc3g=) | `84.82% <0.00%> (+1.78%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (89bbdcf) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `0.00%`.
   > The diff coverage is `65.78%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   67.69%   -0.01%     
   ==========================================
     Files         940      941       +1     
     Lines       45586    45658      +72     
     Branches     4378     4388      +10     
   ==========================================
   + Hits        30861    30908      +47     
   - Misses      14622    14647      +25     
     Partials      103      103              
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `54.72% <42.59%> (-0.05%)` | :arrow_down: |
   | javascript | `62.90% <60.65%> (-0.01%)` | :arrow_down: |
   | python | `64.25% <86.66%> (+0.01%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `73.83% <41.66%> (-4.07%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `65.30% <65.30%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (89bbdcf) into [master](https://codecov.io/gh/apache/incubator-superset/commit/33325f9fa6292f45483d67c77332382acd2820ad?el=desc) (33325f9) will **decrease** coverage by `0.12%`.
   > The diff coverage is `65.78%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #11924      +/-   ##
   ==========================================
   - Coverage   67.69%   67.57%   -0.13%     
   ==========================================
     Files         940      941       +1     
     Lines       45586    45658      +72     
     Branches     4378     4388      +10     
   ==========================================
   - Hits        30861    30852       -9     
   - Misses      14622    14699      +77     
   - Partials      103      107       +4     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `54.15% <42.59%> (-0.62%)` | :arrow_down: |
   | javascript | `62.90% <60.65%> (-0.01%)` | :arrow_down: |
   | python | `64.25% <86.66%> (+0.01%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `73.83% <41.66%> (-4.07%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `65.30% <65.30%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `86.46% <100.00%> (+0.11%)` | :arrow_up: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [...et-frontend/src/SqlLab/reducers/getInitialState.js](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9yZWR1Y2Vycy9nZXRJbml0aWFsU3RhdGUuanM=) | `33.33% <0.00%> (-16.67%)` | :arrow_down: |
   | [superset-frontend/src/reduxUtils.ts](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3JlZHV4VXRpbHMudHM=) | `70.88% <0.00%> (-8.87%)` | :arrow_down: |
   | [...rontend/src/SqlLab/components/TabbedSqlEditors.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1RhYmJlZFNxbEVkaXRvcnMuanN4) | `76.12% <0.00%> (-5.17%)` | :arrow_down: |
   | ... and [8 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [33325f9...89bbdcf](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [incubator-superset] codecov-io edited a comment on pull request #11924: feat: add modal to import dashboards

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #11924:
URL: https://github.com/apache/incubator-superset/pull/11924#issuecomment-738722655


   # [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=h1) Report
   > Merging [#11924](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=desc) (fc34750) into [PISQL-2](https://codecov.io/gh/apache/incubator-superset/commit/b934e6ee96e673b512e17b5c033cd0310ee131c2?el=desc) (b934e6e) will **decrease** coverage by `7.77%`.
   > The diff coverage is `52.17%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-superset/pull/11924/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l)](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff             @@
   ##           PISQL-2   #11924      +/-   ##
   ===========================================
   - Coverage    68.08%   60.31%   -7.78%     
   ===========================================
     Files          939      874      -65     
     Lines        48362    42996    -5366     
     Branches      4862     3793    -1069     
   ===========================================
   - Hits         32927    25931    -6996     
   - Misses       15332    17065    +1733     
   + Partials       103        0     -103     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | cypress | `54.82% <42.59%> (-0.26%)` | :arrow_down: |
   | javascript | `?` | |
   | python | `63.19% <86.66%> (-2.39%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [superset/dashboards/commands/export.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9leHBvcnQucHk=) | `91.17% <0.00%> (ø)` | |
   | [...rontend/src/views/CRUD/dashboard/DashboardList.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGFzaGJvYXJkL0Rhc2hib2FyZExpc3QudHN4) | `67.41% <36.36%> (-10.48%)` | :arrow_down: |
   | [...end/src/dashboard/components/ImportModal/index.tsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL0ltcG9ydE1vZGFsL2luZGV4LnRzeA==) | `44.18% <44.18%> (ø)` | |
   | [...erset/dashboards/commands/importers/v1/\_\_init\_\_.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvdjEvX19pbml0X18ucHk=) | `94.69% <85.71%> (-0.60%)` | :arrow_down: |
   | [superset/dashboards/api.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9hcGkucHk=) | `84.27% <100.00%> (-2.07%)` | :arrow_down: |
   | [...perset/dashboards/commands/importers/dispatcher.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9jb21tYW5kcy9pbXBvcnRlcnMvZGlzcGF0Y2hlci5weQ==) | `80.64% <100.00%> (+1.33%)` | :arrow_up: |
   | [superset/dashboards/schemas.py](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9zY2hlbWFzLnB5) | `98.78% <100.00%> (ø)` | |
   | [...uperset-frontend/src/dashboard/util/dnd-reorder.js](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC91dGlsL2RuZC1yZW9yZGVyLmpz) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...rset-frontend/src/dashboard/util/getEmptyLayout.js](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC91dGlsL2dldEVtcHR5TGF5b3V0Lmpz) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...dashboard/components/resizable/ResizableHandle.jsx](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2Rhc2hib2FyZC9jb21wb25lbnRzL3Jlc2l6YWJsZS9SZXNpemFibGVIYW5kbGUuanN4) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | ... and [392 more](https://codecov.io/gh/apache/incubator-superset/pull/11924/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=footer). Last update [b934e6e...fc34750](https://codecov.io/gh/apache/incubator-superset/pull/11924?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org