Skip to content

Commit b3493c0

Browse files
authored
Merge pull request #3048 from kamilbednarz/accept-other-compressions
FastHttpUser: Accept brotli and zstd compression encoding
2 parents bb24746 + 7cd7de6 commit b3493c0

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Diff for: docs/running-in-debugger.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ Example output (for FastHttpUser):
9191
REQUEST: http://example.com/
9292
GET / HTTP/1.1
9393
user-agent: python/gevent-http-client-1.5.3
94-
accept-encoding: gzip, deflate
94+
accept-encoding: gzip, deflate, br, zstd
9595
host: example.com
9696
9797
RESPONSE: HTTP/1.1 200

Diff for: locust/contrib/fasthttp.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ def request(
229229
elif self.auth_header:
230230
headers["Authorization"] = self.auth_header
231231
if "Accept-Encoding" not in headers and "accept-encoding" not in headers:
232-
headers["Accept-Encoding"] = "gzip, deflate"
232+
headers["Accept-Encoding"] = "gzip, deflate, br, zstd"
233233

234234
if not data and json is not None:
235235
data = unshadowed_json.dumps(json)

0 commit comments

Comments
 (0)