GitHub user dosubot[bot] added a comment to the discussion: Alerts & reports nothing triggered
<!-- Answer --> To set up MACHINE_AUTH_PROVIDER_CLASS and WEBDRIVER_AUTH_FUNC for Superset alerts/reports, add these options to your superset_config.py: ```python # Use the default machine auth provider (handles background login for screenshots/reports) MACHINE_AUTH_PROVIDER_CLASS = "superset.utils.machine_auth.MachineAuthProvider" # Optionally override the webdriver authentication function (for Selenium/Playwright) WEBDRIVER_AUTH_FUNC = None # Or set to a Python callable for custom auth logic ``` The default MachineAuthProvider logs in a user via Flask-Login and injects session cookies into the Selenium WebDriver session, so background tasks can access protected dashboards for screenshots and notifications. If you use SSO or custom authentication, you may need to implement your own provider class or authentication function and reference it here (e.g., `"my_module.MySSOAuthProvider"` or `WEBDRIVER_AUTH_FUNC = my_custom_auth_func`). Authentication is mandatory unless anonymous access is allowed in your Superset instance. For more details, see the config comments and usage patterns in the codebase [[source]](https://github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/superset/config.py), and background on how authentication works for automated screenshots [[source]](https://github.com/apache/superset/discussions/34131). If you need to support SSO, your custom class/function should handle login and inject the necessary cookies/session into the WebDriver. Let me know if you need a code example for a custom provider! <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/59cb19d0-d413-4815-91f8-e1275a3d0579?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/59cb19d0-d413-4815-91f8-e1275a3d0579?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/59cb19d0-d413-4815-91f8-e1275a3d0579?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/59cb19d0-d413-4815-91f8-e1275a3d0579?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/59cb19d0-d413-4815-91f8-e1275a3d0579?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/59cb19d0-d413-4815-91f8-e1275a3d0579?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/59cb19d0-d413-4815-91f8-e1275a3d0579?feedback_type=other)</sup> [](https://app.dosu.dev/a28d3c7e-a9d3-459e-9fb6-3a6f9ff4f357/ask?utm_source=github)& nbsp;[](https://go.dosu.dev/discord-bot) [](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/discussions/35138) GitHub link: https://github.com/apache/superset/discussions/35138#discussioncomment-14400572 ---- This is an automatically sent email for [email protected]. To unsubscribe, please send an email to: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
