This is an automated email from the ASF dual-hosted git repository. Xuanwo pushed a commit to branch xuanwo/fix-s3-writer-abort-empty-200 in repository https://gitbox.apache.org/repos/asf/opendal.git
commit b1cf6ae2422f167b7b13736325edb123d8aadec9 Author: Xuanwo <[email protected]> AuthorDate: Wed Nov 25 15:42:45 2026 +0100 fix(services/s3): preserve multipart abort handling for HTTP 204 --- core/services/s3/src/core.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/core/services/s3/src/core.rs b/core/services/s3/src/core.rs index 06662249bb..0d7e12dc76 100644 --- a/core/services/s3/src/core.rs +++ b/core/services/s3/src/core.rs @@ -1524,8 +1524,9 @@ impl S3Core { let resp = self.send(ctx, req).await?; match resp.status() { + StatusCode::NO_CONTENT => Ok(()), // Supabase Storage returns an empty 200 after aborting the upload. - StatusCode::NO_CONTENT | StatusCode::OK if resp.body().is_empty() => Ok(()), + StatusCode::OK if resp.body().is_empty() => Ok(()), _ => Err(parse_error(ErrorContext::new(service_operation), resp)), } } @@ -1892,6 +1893,10 @@ mod tests { .unwrap(); let cases = [ (Some((StatusCode::NO_CONTENT, "")), None), + ( + Some((StatusCode::NO_CONTENT, "custom transport body")), + None, + ), (Some((StatusCode::OK, "")), None), ( Some((
