You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/10/13 08:25:57 UTC

[GitHub] [superset] dpgaspar commented on a diff in pull request #21765: fix(alerts): restrict list view and gamma perms

dpgaspar commented on code in PR #21765:
URL: https://github.com/apache/superset/pull/21765#discussion_r994311029


##########
superset/reports/commands/execute.py:
##########
@@ -675,12 +673,13 @@ def __init__(self, task_id: str, model_id: int, scheduled_dttm: datetime):
     def run(self) -> None:
         with session_scope(nullpool=True) as session:
             try:
-                self.validate(session=session)
-                if not self._model:
-                    raise ReportScheduleExecuteUnexpectedError()
-                ReportScheduleStateMachine(
-                    session, self._execution_id, self._model, self._scheduled_dttm
-                ).run()
+                with override_user(_get_user()):

Review Comment:
   since this method always runs on a celery async context I see no issue here, but what are we trying to solve? 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org