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/01/31 17:34:56 UTC

[GitHub] [incubator-superset] etr2460 commented on a change in pull request #9033: feat: Add schema to function retrieval and implement for Snowflake

etr2460 commented on a change in pull request #9033: feat: Add schema to function retrieval and implement for Snowflake
URL: https://github.com/apache/incubator-superset/pull/9033#discussion_r373597481
 
 

 ##########
 File path: superset/db_engine_specs/presto.py
 ##########
 @@ -947,13 +948,20 @@ def latest_sub_partition(cls, table_name, schema, database, **kwargs):
         return df.to_dict()[field_to_return][0]
 
     @classmethod
-    @cache.memoize()
-    def get_function_names(cls, database: "Database") -> List[str]:
+    def get_function_names(
+        cls, database: "Database", schema: Optional[str]
+    ) -> List[str]:
         """
         Get a list of function names that are able to be called on the database.
         Used for SQL Lab autocomplete.
 
         :param database: The database to get functions for
+        :param schema: The schema to get functions for (N/A for Presto)
 
 Review comment:
   Won't a schema still be passed for Presto even if it isn't being used? That would mean we'd still cache at the db + schema level for Presto (and hive) which isn't necessary.

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


With regards,
Apache Git Services

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