hxtmdev commented on code in PR #33108:
URL: https://github.com/apache/superset/pull/33108#discussion_r2042776691


##########
superset/dashboards/api.py:
##########
@@ -1307,6 +1308,11 @@ def thumbnail(self, pk: int, digest: str, **kwargs: Any) 
-> WerkzeugResponse:
                 dashboard_id=dashboard.id,
                 force=False,
             )
+
+        if (
+            cache_payload.should_trigger_task()

Review Comment:
   IMO `should_trigger_task` is correct:  
   trigger task if either
   1. force
   2. PENDING
   3. ERROR and error ttl expired
   
   COMPUTING should not trigger a new task because (as I understand it) that 
means it's already running.
   
   So I add the COMPUTING check here because that's an additional case to 
return 202 (even if we didn't need to create a new task again).



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to