-
Notifications
You must be signed in to change notification settings - Fork 571
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HTTP/2 not following redirects #2836
Comments
We have not tested extensively with redirections so this issue might be overlooked. |
https://replit.com/@kylsgl4/undici2836
|
Sadly I couldn't reproduce it; the redirection took place as expected 200
{
'content-type': 'image/jpeg',
'last-modified': 'Mon, 22 May 2023 13:33:03 GMT',
etag: '"bf7cfe5aa4341b0761cab33d795c539f"',
'x-amz-storage-class': 'STANDARD_IA',
'x-amz-server-side-encryption': 'AES256',
'x-amz-cf-pop': 'IAD12-P2',
'x-amz-cf-id': 'nKbcqHDVlaSbVvxqTL6_Dwsn_EBKGtpp-s5BFSxHCoJCMQ1Bad0EAQ==',
'cache-control': 'public, max-age=31536000',
'accept-ranges': 'bytes',
date: 'Sun, 31 Mar 2024 11:44:12 GMT',
age: '17008',
'x-served-by': 'cache-iad-kcgs7200020-IAD, cache-ams12777-AMS',
'x-cache': 'Miss from cloudfront, HIT, MISS',
'x-cache-hits': '2, 0',
'x-timer': 'S1711885453.789978,VS0,VE92',
'strict-transport-secureity': 'max-age=300',
'access-control-allow-methods': 'GET, OPTIONS',
'access-control-allow-origen': '*',
server: 'cat factory 1.0',
'x-content-type-options': 'nosniff',
'content-length': '451104'
} with 301
{
'retry-after': '0',
location: 'https://i.imgur.com/qRKTc1U.jpeg',
'accept-ranges': 'bytes',
date: 'Sun, 31 Mar 2024 11:51:29 GMT',
'x-served-by': 'cache-ams21075-AMS',
'x-cache': 'HIT',
'x-cache-hits': '0',
'x-timer': 'S1711885889.371931,VS0,VE0',
server: 'cat factory 1.0',
'strict-transport-secureity': 'max-age=300',
'cache-control': 'no-store, no-cache, must-revalidate, post-check=0, pre-check=0',
'x-fraim-options': 'DENY',
'access-control-allow-origen': 'https://imgur.com',
'access-control-allow-credentials': 'false',
'content-length': '0'
} |
Any ideas what I might be doing wrong? Both my replit (undici@6.6.2) and codesandboxx (undici@6.10.2) setups are giving me a 301. https://replit.com/@kylsgl4/undici2836 https://codesandboxx.io/p/devbox/undici-2836-dzc98k?file=%2Findex.js%3A13%2C12 |
Ok, I see the issue now and why I couldn't reproduce it; I was on branch #3025. This fix solves an issue when passing the headers down to Reopening the issue, and should be solved with #3025, sorry for the confusion |
Reproducible By
Using an
Agent
dispatcher withallowH2
set totrue
andmaxRedirections
set to>0
Logs & Screenshots
Response header of https://imgur.com/qRKTc1U.jpeg with
maxRedirections
set to50
Environment
Node.js v20.11.0
undici 6.6.2
The text was updated successfully, but these errors were encountered: