Describe the bug
Requesting a suffix range from an existing zero-byte S3 object fails with Error::Generic(GetResultError::NotPartial). S3 returns a 200 for the suffix-range GET when the object is 0 bytes, but object_store expects a 206.
To Reproduce
let options =
GetOptions::new().with_range(Some(GetRange::Suffix(512 * 1024)));
let result = store.get_opts(&path, options).await;
For a zero-byte object, AWS S3 responds with:
HTTP/1.1 200 OK
Content-Length: 0
Expected behavior
Either the call should return success, or fail with some error with a specific type that the caller can use to discriminate and handle this case specifically (e.g. by falling back to a HEAD).
Describe the bug
Requesting a suffix range from an existing zero-byte S3 object fails with
Error::Generic(GetResultError::NotPartial). S3 returns a 200 for the suffix-range GET when the object is 0 bytes, but object_store expects a 206.To Reproduce
For a zero-byte object, AWS S3 responds with:
Expected behavior
Either the call should return success, or fail with some error with a specific type that the caller can use to discriminate and handle this case specifically (e.g. by falling back to a HEAD).