aristidb/aws — pull request #115 by romanb (2014-08-07 16:41:08+00:00)
Title: Better error handling for S3 HEAD requests.

As it stands, the headers of a `HEAD` response are blindly parsed, without looking at the response code. As a result it is impossible to clearly identify the most common error case of such a request, which is a `404` (you get a `HeaderException` about a missing `E-Tag`). Since it is a main use case of `HEAD` requests to check for the existence of a resource, I propose to make that case explicit in the types via a `Maybe` and raise any other non-`200` response as a `StatusCodeException`.