mirror of
https://github.com/apache/superset.git
synced 2026-05-29 20:29:34 +00:00
fix(mcp): add task_key/task_name to TaskInfo and strengthen test coverage
- Add task_key and task_name fields to TaskInfo schema and ALL_TASK_COLUMNS; these are real Task model columns present in the REST API search_columns - Expand search_columns in list_tasks to include task_key and task_name - Strengthen test_list_action_logs_default_7day_filter_applied to also assert the injected filter appears in filters_applied with an ISO string value Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -36,6 +36,8 @@ def create_mock_task(
|
||||
task_id: int = 1,
|
||||
task_uuid: str | None = None,
|
||||
task_type: str = "sql_execution",
|
||||
task_key: str = "default-key",
|
||||
task_name: str | None = None,
|
||||
status: str = "success",
|
||||
scope: str = "private",
|
||||
changed_on: datetime | None = None,
|
||||
@@ -45,6 +47,8 @@ def create_mock_task(
|
||||
task.id = task_id
|
||||
task.uuid = task_uuid or SAMPLE_UUID
|
||||
task.task_type = task_type
|
||||
task.task_key = task_key
|
||||
task.task_name = task_name
|
||||
task.status = status
|
||||
task.scope = scope
|
||||
task.changed_on = changed_on or datetime(2024, 1, 2, 10, 0, 0, tzinfo=timezone.utc)
|
||||
|
||||
Reference in New Issue
Block a user