dosubot[bot] commented on issue #30900:
URL: https://github.com/apache/superset/issues/30900#issuecomment-2473013004
<!-- Answer -->
Ensure that the JSON payload you are sending to the `/warm_up_cache`
endpoint is correctly structured according to the
`DatasetCacheWarmUpRequestSchema`. Here's what you need to do:
1. **Check the JSON Request Body**: Make sure it includes all required
fields and is correctly formatted. The required fields are `db_name` and
`table_name`. Optional fields include `dashboard_id` and `extra_filters`.
2. **Validate Data Types**: Ensure that the data types of the fields match
the expected types:
- `db_name` and `table_name` should be strings.
- `dashboard_id` should be an integer.
- `extra_filters` should be a string.
3. **Use the Correct HTTP Method**: The `warm_up_cache` endpoint requires
the PUT method.
By following these steps, you should be able to resolve the 400 Bad Request
error. If you continue to encounter issues, review any error messages returned
to identify specific fields causing the problem
<sup>[[1]](https://github.com/apache/superset/blob/master/superset/datasets/api.py)</sup><sup>[[2]](https://github.com/apache/superset/blob/master/superset/datasets/schemas.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: [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]