dosubot[bot] commented on issue #32655: URL: https://github.com/apache/superset/issues/32655#issuecomment-2722041284
<!-- Answer --> A similar issue was previously reported and resolved by installing the `flask-cors` module, which is an optional dependency necessary for the `ENABLE_CORS` feature <sup>[[1]](https://github.com/apache/superset/issues/27102)</sup>. In Superset 4.1.1, `flask_cors` is listed as a dependency with version `4.0.2` <sup>[[2]](https://github.com/apache/superset/blob/c5a2bc5484edf86f672f3bef66b2bbb4060c9e01/requirements/development.txt#L199-L290)</sup>. To resolve this issue in a Kubernetes environment, you can modify your Helm chart's `values.yaml` or `dev-values.yaml` file to include a bootstrap script that installs the `flask-cors` module. Here's an example of how you can do this: ```yaml bootstrapScript: | #!/bin/bash set -e # Update system packages and install dependencies apt update && apt install -y gcc libpq-dev python3-dev pkg-config libmariadb-dev-compat && \ # Install Python dependencies /app/.venv/bin/pip install \ flask-cors==4.0.2 && \ # Create a bootstrap log file if not already created if [ ! -f ~/bootstrap ]; then echo "Running Superset with uid {{ .Values.runAsUser }}" > ~/bootstrap fi ``` This script ensures that the `flask-cors` module is installed during the deployment process, preventing the `ModuleNotFoundError` and allowing your Superset pods to start successfully <sup>[[3]](https://github.com/apache/superset/discussions/31431)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* --- <sup>Help Dosu learn! Give it feedback: [Great Response](https://app.dosu.dev/response-feedback/db8bc779-6b8d-4af7-943e-8559925309a8?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/db8bc779-6b8d-4af7-943e-8559925309a8?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/db8bc779-6b8d-4af7-943e-8559925309a8?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/db8bc779-6b8d-4af7-943e-8559925309a8?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/db8bc779-6b8d-4af7-943e-8559925309a8?feedback_type=hallucination) | [Bug Report](https://app.dosu.dev/response-feedback/db8bc779-6b8d-4af7-943e-8559925309a8?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/db8bc779-6b8d-4af7-943e-8559925309a8?feedback_type=other)</sup> -- 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]
