[Python] S3UploadFailedError due to MissingContentLength when calling PutObject in MLflow...

Discussão em 'Python' iniciado por Stack, Janeiro 21, 2025.

  1. Stack

    Stack Membro Participativo

    When trying to save / upload a file using mlflow.log_artifact() to MinIO, our MLflow users are suddenly getting this error in previously working code, raised in boto3 package (dependency of the minio package utilized as data lake by our local installation of MLflow):

    S3UploadFailedError: Failed to upload ./dict-20231204.2.json to mlflow/24/<run_id>/artifacts/dict-20231204.2.json: An error occurred (MissingContentLength) when calling the PutObject operation: You must provide the Content-Length HTTP header.

    It is raised here: [..]/python3.11/site-packages/boto3/s3/transfer.py:378, in S3Transfer.upload_file()

    Any solutions or at least workarounds to restore file uploads to MinIO buckets?

    Continue reading...

Compartilhe esta Página