refactor
This commit is contained in:
@@ -247,8 +247,14 @@ class SupersetClient:
|
||||
def get_dataset_detail(self, dataset_id: int) -> Dict:
|
||||
with belief_scope("SupersetClient.get_dataset_detail", f"id={dataset_id}"):
|
||||
# Get base dataset info
|
||||
dataset = self.get_dataset(dataset_id)
|
||||
response = self.get_dataset(dataset_id)
|
||||
|
||||
# If the response is a dict and has a 'result' key, use that (standard Superset API)
|
||||
if isinstance(response, dict) and 'result' in response:
|
||||
dataset = response['result']
|
||||
else:
|
||||
dataset = response
|
||||
|
||||
# Extract columns information
|
||||
columns = dataset.get("columns", [])
|
||||
column_info = []
|
||||
|
||||
Reference in New Issue
Block a user