Bug description
Bug description
Scheduled dashboard reports can store dashboard state under ReportSchedule.extra.dashboard, including native filter state in dataMask.
During report generation, per-tab permalinks are created in superset/commands/report/execute.py. While building those tab-specific permalinks, the existing dashboard state from the report schedule is not preserved.
As a result, dataMask is dropped and scheduled report screenshots may ignore the filter state that was configured on the report schedule.
This is especially visible for scheduled reports that depend on native time filters. Even if the schedule stores the correct date filter state in extra.dashboard.dataMask, the generated permalink does not carry that
state forward, so the rendered report can show incorrect or unfiltered results.
How to reproduce the bug
- Create a dashboard with multiple tabs.
- Add native filters to the dashboard, including a time filter.
- Create a report schedule for that dashboard.
- Persist dashboard filter state in
ReportSchedule.extra.dashboard.dataMask.
- Enable
ALERT_REPORT_TABS.
- Run report generation for the scheduled dashboard.
- Inspect the generated permalink state or the resulting screenshots.
Expected behavior
Scheduled report generation should preserve the parent dashboard state stored in ReportSchedule.extra.dashboard when building per-tab permalinks.
That includes preserving:
dataMask
activeTabs
urlParams
As a result, generated screenshots should reflect the same native filter state stored on the report schedule.
Actual results
Per-tab permalink generation drops stored dashboard state, causing dataMask not to be respected during report execution.
Screenshots/recordings
N/A
Environment
- Superset version: current
master
- Feature flag:
ALERT_REPORT_TABS
Screenshots/recordings
No response
Superset version
master / latest-dev
Python version
3.9
Node version
16
Browser
Chrome
Additional context
No response
Checklist
Bug description
Bug description
Scheduled dashboard reports can store dashboard state under
ReportSchedule.extra.dashboard, including native filter state indataMask.During report generation, per-tab permalinks are created in
superset/commands/report/execute.py. While building those tab-specific permalinks, the existing dashboard state from the report schedule is not preserved.As a result,
dataMaskis dropped and scheduled report screenshots may ignore the filter state that was configured on the report schedule.This is especially visible for scheduled reports that depend on native time filters. Even if the schedule stores the correct date filter state in
extra.dashboard.dataMask, the generated permalink does not carry thatstate forward, so the rendered report can show incorrect or unfiltered results.
How to reproduce the bug
ReportSchedule.extra.dashboard.dataMask.ALERT_REPORT_TABS.Expected behavior
Scheduled report generation should preserve the parent dashboard state stored in
ReportSchedule.extra.dashboardwhen building per-tab permalinks.That includes preserving:
dataMaskactiveTabsurlParamsAs a result, generated screenshots should reflect the same native filter state stored on the report schedule.
Actual results
Per-tab permalink generation drops stored dashboard state, causing
dataMasknot to be respected during report execution.Screenshots/recordings
N/A
Environment
masterALERT_REPORT_TABSScreenshots/recordings
No response
Superset version
master / latest-dev
Python version
3.9
Node version
16
Browser
Chrome
Additional context
No response
Checklist