---------------------
=== Redirect ===
GET https://httpbin.org/status/204
accept-encoding: gzip, deflate, br
accept: */*
user-agent: httpyac
HTTP/1.1 302 - FOUND
access-control-allow-credentials: true
access-control-allow-origin: *
connection: close
content-length: 0
content-type: text/html; charset=utf-8
date: Tue, 28 Jun 2022 04:39:27 GMT
location: https://httpbin.org/status/204
server: gunicorn/19.9.0
---------------------
=== Redirect ===
GET https://httpbin.org/status/204
accept-encoding: gzip, deflate, br
accept: */*
user-agent: httpyac
HTTP/1.1 204 - NO CONTENT
access-control-allow-credentials: true
access-control-allow-origin: *
connection: close
content-type: text/html; charset=utf-8
date: Tue, 28 Jun 2022 04:39:28 GMT
server: gunicorn/19.9.0
You can see that the GET https://httpbin.org/status/204 is shown twice, including for the initial request. The initial request is never shown.
While I suspect this is something which comes from the underlying http library... including here just in case.
In this case it's obvious something's missing... but just for some background... I got tripped by this while looking into an http to https redirect. Since it kept showing https the whole time, I couldn't understand why I was being redirected to the same URL one more time.
Thanks for the tip. I had overlooked that. Got before the hook call already updates the request options for the next call. For this reason I now remember the original request options myself and output them.
Given this:
I get this in the output:
You can see that the
GET https://httpbin.org/status/204
is shown twice, including for the initial request. The initial request is never shown.While I suspect this is something which comes from the underlying http library... including here just in case.
In this case it's obvious something's missing... but just for some background... I got tripped by this while looking into an
http
tohttps
redirect. Since it kept showinghttps
the whole time, I couldn't understand why I was being redirected to the same URL one more time.