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 2022/03/15 13:00:12 UTC

[GitHub] [superset] diegomedina248 opened a new pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

diegomedina248 opened a new pull request #19152:
URL: https://github.com/apache/superset/pull/19152


   ### SUMMARY
   Currently table names are not added to autocomplete in SQL Lab
   
   When the schema is selected, then a query is made to fetch the tables for the database/schema combination.
   Those options were not properly propagated and stored in the reducer, thus the tables never appeared.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   Before:
   
   https://user-images.githubusercontent.com/17252075/158382853-7bb64c55-a70d-484b-a3af-7e6a1c54bcc3.mov
   
   After:
   
   https://user-images.githubusercontent.com/17252075/158382643-dfabf74f-974f-4189-b31d-6b370cbb2e59.mov
   
   ### TESTING INSTRUCTIONS
   1. Go to SQL Lab
   2. Choose the Examples database and related schema (Pubic for Postgres)
   3. Check a name of a table ("Flights" should be present)
   4. Type "select * from Fli" in the Editor and notice that "Flights" doesn't appear in the dropdown
   
   ### ADDITIONAL INFORMATION
   Fixes https://github.com/apache/superset/issues/19008
   
   - [x] Has associated issue:
   - [ ] Required feature flags:
   - [x] Changes UI
   - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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] [superset] rusackas commented on pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

Posted by GitBox <gi...@apache.org>.
rusackas commented on pull request #19152:
URL: https://github.com/apache/superset/pull/19152#issuecomment-1069734339


   /testenv up


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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] [superset] rusackas merged pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

Posted by GitBox <gi...@apache.org>.
rusackas merged pull request #19152:
URL: https://github.com/apache/superset/pull/19152


   


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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] [superset] sadpandajoe commented on pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

Posted by GitBox <gi...@apache.org>.
sadpandajoe commented on pull request #19152:
URL: https://github.com/apache/superset/pull/19152#issuecomment-1071007727


   🏷️  preset:2022.11


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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] [superset] rusackas commented on a change in pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

Posted by GitBox <gi...@apache.org>.
rusackas commented on a change in pull request #19152:
URL: https://github.com/apache/superset/pull/19152#discussion_r828707831



##########
File path: superset-frontend/src/components/TableSelector/index.tsx
##########
@@ -208,15 +208,14 @@ const TableSelector: FunctionComponent<TableSelectorProps> = ({
               currentTable = option;
             }
           });
-          if (onTablesLoad) {
-            onTablesLoad(json.options);
-          }
+
+          onTablesLoad?.(json.options);
           setTableOptions(options);
           setCurrentTable(currentTable);
           setLoadingTables(false);
           if (forceRefresh) addSuccessToast('List updated');
         })
-        .catch(e => {
+        .catch(() => {

Review comment:
       Thanks for the extra cleanup along the way!




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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] [superset] github-actions[bot] commented on pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #19152:
URL: https://github.com/apache/superset/pull/19152#issuecomment-1070137655


   Ephemeral environment shutdown and build artifacts deleted.


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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] [superset] sadpandajoe commented on pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

Posted by GitBox <gi...@apache.org>.
sadpandajoe commented on pull request #19152:
URL: https://github.com/apache/superset/pull/19152#issuecomment-1071007727


   🏷️  preset:2022.11


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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] [superset] codecov[bot] commented on pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

Posted by GitBox <gi...@apache.org>.
codecov[bot] commented on pull request #19152:
URL: https://github.com/apache/superset/pull/19152#issuecomment-1069742538


   # [Codecov](https://codecov.io/gh/apache/superset/pull/19152?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#19152](https://codecov.io/gh/apache/superset/pull/19152?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (2c623cb) into [master](https://codecov.io/gh/apache/superset/commit/8d53db1db6c3211d6be6905bd1e4cd11043e8219?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (8d53db1) will **increase** coverage by `0.00%`.
   > The diff coverage is `40.00%`.
   
   > :exclamation: Current head 2c623cb differs from pull request most recent head 61dbdd5. Consider uploading reports for the commit 61dbdd5 to get more accurate results
   
   ```diff
   @@           Coverage Diff           @@
   ##           master   #19152   +/-   ##
   =======================================
     Coverage   66.54%   66.54%           
   =======================================
     Files        1646     1646           
     Lines       63630    63638    +8     
     Branches     6475     6477    +2     
   =======================================
   + Hits        42343    42350    +7     
   - Misses      19607    19609    +2     
   + Partials     1680     1679    -1     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | javascript | `51.30% <40.00%> (+<0.01%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/superset/pull/19152?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...d/src/SqlLab/components/AceEditorWrapper/index.tsx](https://codecov.io/gh/apache/superset/pull/19152/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL0FjZUVkaXRvcldyYXBwZXIvaW5kZXgudHN4) | `44.82% <0.00%> (-8.75%)` | :arrow_down: |
   | [...d/src/SqlLab/components/SqlEditorLeftBar/index.tsx](https://codecov.io/gh/apache/superset/pull/19152/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1NxbEVkaXRvckxlZnRCYXIvaW5kZXgudHN4) | `56.75% <55.55%> (+0.09%)` | :arrow_up: |
   | [...et-frontend/src/components/TableSelector/index.tsx](https://codecov.io/gh/apache/superset/pull/19152/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvVGFibGVTZWxlY3Rvci9pbmRleC50c3g=) | `68.29% <100.00%> (+5.64%)` | :arrow_up: |
   | [superset-frontend/src/components/Select/Select.tsx](https://codecov.io/gh/apache/superset/pull/19152/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvU2VsZWN0L1NlbGVjdC50c3g=) | `86.32% <0.00%> (+1.28%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/19152?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/19152?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [8d53db1...61dbdd5](https://codecov.io/gh/apache/superset/pull/19152?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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] [superset] github-actions[bot] commented on pull request #19152: fix: auto-complete of tables and names are not working in SQL lab

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #19152:
URL: https://github.com/apache/superset/pull/19152#issuecomment-1069735523


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


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

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