dosubot[bot] commented on issue #29541: URL: https://github.com/apache/superset/issues/29541#issuecomment-2222346798
<!-- Answer --> Since the task ID is printed, indicating that the connection to Redis is fine, but the task is not visible in Flower, let's focus on a few additional checks and configurations: 1. **Celery Task Registration**: Ensure that the `reports.scheduler` task is correctly registered with Celery. Verify that the task is imported and recognized by Celery. ```python from superset.tasks.scheduler import scheduler @celery_app.task(name="reports.scheduler") def scheduler_task(): scheduler() ``` 2. **Celery Worker Configuration**: Ensure that the Celery worker is configured to recognize and execute the `reports.scheduler` task. Check the worker logs for any errors or warnings related to task registration. 3. **Celery Beat Configuration**: Ensure that the Celery beat schedule includes the `reports.scheduler` task and that it is correctly configured to run at the desired intervals. ```python from celery.schedules import crontab class CeleryConfig: broker_url = "redis://localhost:6379/0" result_backend = "redis://localhost:6379/0" imports = ("superset.sql_lab", "superset.tasks.scheduler") beat_schedule = { "reports.scheduler": { "task": "reports.scheduler", "schedule": crontab(minute="*", hour="*"), }, "reports.prune_log": { "task": "reports.prune_log", "schedule": crontab(minute=0, hour=0), }, } CELERY_CONFIG = CeleryConfig ``` 4. **Check Celery Logs**: Review the Celery worker and beat logs for any errors or warnings that might indicate why the task is not being executed. Look for messages related to task registration, scheduling, and execution. 5. **Flower Configuration**: Ensure that Flower is correctly configured to monitor the Celery tasks. Sometimes, tasks might not appear in Flower due to configuration issues. Restart Flower and check if the tasks appear. 6. **Task Visibility in Flower**: Verify that the task is not filtered out in Flower. Check the Flower interface for any filters or settings that might hide certain tasks. By following these steps, you should be able to identify and resolve the issue with the `reports.scheduler` task not appearing in Flower and ensure it is correctly scheduled and executed by Celery <sup>[[1]](https://github.com/apache/superset/blob/master/superset/tasks/scheduler.py)</sup><sup>[[2]](https://github.com/apache/superset/blob/master/tests/integration_tests/reports/scheduler_tests.py)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* -- 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-unsubscr...@superset.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@superset.apache.org For additional commands, e-mail: notifications-h...@superset.apache.org