mirror of
https://github.com/apache/superset.git
synced 2026-04-20 08:34:37 +00:00
chore(pre-commit): Add pyupgrade and pycln hooks (#24197)
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
"""Utils to provide dashboards for tests"""
|
||||
|
||||
import json
|
||||
from typing import Any, Dict, List, Optional
|
||||
from typing import Optional
|
||||
|
||||
from pandas import DataFrame
|
||||
|
||||
@@ -65,7 +65,7 @@ def create_table_metadata(
|
||||
|
||||
|
||||
def create_slice(
|
||||
title: str, viz_type: str, table: SqlaTable, slices_dict: Dict[str, str]
|
||||
title: str, viz_type: str, table: SqlaTable, slices_dict: dict[str, str]
|
||||
) -> Slice:
|
||||
return Slice(
|
||||
slice_name=title,
|
||||
@@ -77,7 +77,7 @@ def create_slice(
|
||||
|
||||
|
||||
def create_dashboard(
|
||||
slug: str, title: str, position: str, slices: List[Slice]
|
||||
slug: str, title: str, position: str, slices: list[Slice]
|
||||
) -> Dashboard:
|
||||
dash = db.session.query(Dashboard).filter_by(slug=slug).one_or_none()
|
||||
if dash:
|
||||
|
||||
Reference in New Issue
Block a user