You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by mi...@apache.org on 2022/08/31 11:49:09 UTC

[superset] 01/03: Fixes lint errors

This is an automated email from the ASF dual-hosted git repository.

michaelsmolina pushed a commit to branch 1.5
in repository https://gitbox.apache.org/repos/asf/superset.git

commit 5a3bb82b8dad09081893b4b6a784d9057ec89861
Author: Michael S. Molina <mi...@gmail.com>
AuthorDate: Tue Aug 30 13:57:03 2022 -0300

    Fixes lint errors
---
 superset/db_engine_specs/trino.py | 1 -
 superset/utils/core.py            | 9 +++++++++
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/superset/db_engine_specs/trino.py b/superset/db_engine_specs/trino.py
index 1759345069..1692018efa 100644
--- a/superset/db_engine_specs/trino.py
+++ b/superset/db_engine_specs/trino.py
@@ -26,7 +26,6 @@ from sqlalchemy.engine.url import make_url, URL
 from sqlalchemy.orm import Session
 
 from superset.db_engine_specs.base import BaseEngineSpec
-from superset.db_engine_specs.presto import PrestoEngineSpec
 from superset.models.sql_lab import Query
 from superset.utils import core as utils
 
diff --git a/superset/utils/core.py b/superset/utils/core.py
index 4177e01841..74b033fe5d 100644
--- a/superset/utils/core.py
+++ b/superset/utils/core.py
@@ -174,6 +174,15 @@ class GenericDataType(IntEnum):
     # ROW = 7
 
 
+class DatasourceType(str, Enum):
+    SLTABLE = "sl_table"
+    TABLE = "table"
+    DATASET = "dataset"
+    QUERY = "query"
+    SAVEDQUERY = "saved_query"
+    VIEW = "view"
+
+
 class DatasourceDict(TypedDict):
     type: str
     id: int