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/11/16 16:14:31 UTC

[GitHub] [superset] john-bodley commented on pull request #22085: chore: Change get_table_names/get_view_names return type

john-bodley commented on PR #22085:
URL: https://github.com/apache/superset/pull/22085#issuecomment-1317273743

   @ktmud regarding your comment, 
   
   > I don't understand why you have to return set. Shouldn't DBAPI return unique table names to begin with?
   
   Yes the DB-API will return a unique set of table names so the set logic isn't for deduping purposes (except for when we need to do set differing for determining the tables vs. views). Personally I think—from reading the code—that the type hints help one grok the logic of the code better, i.e., when I see `Set[str]` I know the values are unique whereas when I see `List[str]` I'm not as evident. We should really only use `List[...]` when order matters.


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