If-Range cannot be used correctly with etags
a weak entity tag must not be used with If-Range, but there is no easy way to check if an ETag is weak.
additionally, IfRange::etag is infallible, which means it is very easy to create an incorrect implementation.
Indeed! RFC 9110 Section 13.1.5:
A client MUST NOT generate an If-Range header field containing an entity tag that is marked as weak.
Welp, that's an unfortunate oversight. We can include adjustments in the next breaking change (which are not as catastrophic, since the trait is separate from the impls.) Would do well to design what the changes are here.
At the very least we should add an is_weak method to ETag so this can be mitigated in the meantime.
somewhat related, there's no way to get the string of an etag so i can nicely print it in error messages.