You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+14Lines changed: 14 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,19 @@ Change Log
5
5
6
6
See [4.x Change log](https://square.github.io/okhttp/changelogs/changelog_4x/) for the stable version changelogs.
7
7
8
+
## Version 5.1.0
9
+
10
+
_2025-07-07_
11
+
12
+
* New: `Response.peekTrailers()`. When we changed `Response.trailers()` to block instead of
13
+
throwing in 5.0.0, we inadvertently removed the ability for callers to peek the trailers
14
+
(by catching the `IllegalStateException` if they weren't available). This new API restores that
15
+
capability.
16
+
17
+
* Fix: Don't crash on `trailers()` if the response doesn't have a body. We broke [Retrofit] users
18
+
who read the trailers on the `raw()` OkHttp response, after its body was decoded.
Copy file name to clipboardExpand all lines: README.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -120,10 +120,10 @@ Releases
120
120
121
121
Our [change log][changelog] has release history.
122
122
123
-
The latest release is available on [Maven Central](https://search.maven.org/artifact/com.squareup.okhttp3/okhttp/5.0.0/jar).
123
+
The latest release is available on [Maven Central](https://search.maven.org/artifact/com.squareup.okhttp3/okhttp/5.1.0/jar).
// define any required OkHttp artifacts without version
139
139
implementation("com.squareup.okhttp3:okhttp")
@@ -146,10 +146,10 @@ MockWebServer
146
146
147
147
OkHttp includes a library for testing HTTP, HTTPS, and HTTP/2 clients.
148
148
149
-
The latest release is available on [Maven Central](https://search.maven.org/artifact/com.squareup.okhttp3/mockwebserver/5.0.0/jar).
149
+
The latest release is available on [Maven Central](https://search.maven.org/artifact/com.squareup.okhttp3/mockwebserver/5.1.0/jar).
0 commit comments