v3.2.0
·
4 commits
to main
since this release
Release Notes
- Migrated from the release-candidate builds to stable
wreq 0.16.0andwreq-util 0.2.0. - Source builds now require Rust 1.98. Regular installations using prebuilt native binaries are unaffected.
HTTP and WebSocket transport
- Added the
tcpLingeroption to HTTP requests, reusable clients, and WebSocket connections. - Setting
tcpLingerto0enables an abortive close, while leaving it unset preserves the operating system default. - Native DNS failures now expose the stable
ERR_DNSerror code and can be targeted throughretry.errorCodes. - WebSocket cookie-jar lookups now treat
ws:andwss:URLs as their equivalenthttp:andhttps:origins.
Redirect compatibility and privacy
300 Multiple Choicesresponses are now returned to the caller instead of being followed automatically.- Redirects honor the response鈥檚
Referrer-Policy, including origin changes and HTTPS-to-HTTP downgrades. - Authorization, proxy authorization, and explicit cookie headers are removed when a redirect crosses origins.
- Redirect URL and referrer handling now follows standard URL sanitization and length limits more closely.
Performance
- HTTP request dispatch and response-stream reads now run on the shared Tokio runtime instead of creating a separate operating-system thread for each operation.
- Convenience body readers use a native whole-body fast path for lower overhead.
- Existing WHATWG stream behavior remains available when
response.bodyis accessed or a response is cloned. - Body locking,
bodyUsed, cloning, cancellation, error propagation, and single-consumption guarantees remain compatible with the existing API.