Commit Graph

2 Commits

Author SHA1 Message Date
Hugh A Miles II
b6b40457b9 fix(export): import boto3 lazily so app startup never requires it
superset/utils/s3.py imported boto3 at module level, and the dashboard API
imports the export task (which imports this module) at startup. Since boto3 is
not a base dependency, production images without it crashed on boot, failing
deploy health checks. Move the import into the client factory (matching
db_engine_specs/aws_iam.py); boto3 is only needed when an export actually runs.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-27 08:35:41 -04:00
Hugh A Miles II
dbea4b6c87 feat(export): S3 upload + presigned URL utility
Add superset.utils.s3 with upload_file_to_s3() (boto3 managed multipart) and
generate_presigned_url(). Credentials/region come from the standard boto3 chain;
operators can override client construction via EXCEL_EXPORT_S3_CLIENT_KWARGS
(e.g. endpoint_url for MinIO/LocalStack). Adds unit tests with mocked boto3.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-16 14:48:34 -07:00