Skip to content

2.3.0

Choose a tag to compare

@neonmoe neonmoe released this 04 Jan 12:38

Changed

  • Breaking (sort of): the redirection code was improved to match RFC 7231 section 7.1.2, which could subtly break some programs relying on very specific redirects, which is why this should be investigated if you come across weird behaviour after updating. No API changes though, so only a minor version bump. The following two points are now fixed when redirecting:
    • Fragments, the bit after a #-character in the url. If the redirecting url has a fragment, and the one in Location does not, the original fragment should be included in the new url. If Location does have a fragment, it should override the one in the redirecting url.
    • Relative urls. Minreq now properly redirects when Location is relative, e.g. /Foo.html instead of https://example.com/Foo.html. Thanks, @fjt523!

Fixed

  • The Content-Length: 0 header is now inserted into requests that should have it. Thanks, @KarthikNedunchezhiyan!
  • Status line parsing is now fixed, so "400 Bad Request" is not parsed as "400 Bad". Thanks, @KarthikNedunchezhiyan!

Added

  • M1 Mac support by bumping the ring dependency. Thanks, @ryanmcgrath!