Skip to content
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

feat: Support redirections #341

Merged
merged 15 commits into from
Dec 29, 2023
Merged

feat: Support redirections #341

merged 15 commits into from
Dec 29, 2023

Conversation

guibwl
Copy link
Contributor

@guibwl guibwl commented Dec 14, 2023

Some registries will redirect and return with 302;

It will cause corepack error;

Internal Error: Server answered with HTTP 302

This PR helps redirections supported when a request responds with a 302 or 301 status code.

Associated with:
#302
#336

sources/httpUtils.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@aduh95 aduh95 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add tests?

@guibwl
Copy link
Contributor Author

guibwl commented Dec 15, 2023

Can we add tests?

Sure, let me add some.

@guibwl
Copy link
Contributor Author

guibwl commented Dec 16, 2023

Can we add tests?

done

@guibwl guibwl requested review from aduh95 and ljharb December 16, 2023 07:42
tests/httpUtils.test.ts Outdated Show resolved Hide resolved
tests/httpUtils.test.ts Outdated Show resolved Hide resolved
tests/httpUtils.test.ts Outdated Show resolved Hide resolved
tests/httpUtils.test.ts Outdated Show resolved Hide resolved
tests/httpUtils.test.ts Outdated Show resolved Hide resolved
guibwl and others added 5 commits December 17, 2023 21:01
Co-authored-by: Antoine du Hamel <[email protected]>
Co-authored-by: Antoine du Hamel <[email protected]>
Co-authored-by: Antoine du Hamel <[email protected]>
Co-authored-by: Antoine du Hamel <[email protected]>
@guibwl guibwl requested a review from aduh95 December 17, 2023 13:29
@guibwl
Copy link
Contributor Author

guibwl commented Dec 25, 2023

@aduh95 Hi, can I ask when will this feature be released?

sources/httpUtils.ts Outdated Show resolved Hide resolved
Co-authored-by: Antoine du Hamel <[email protected]>
@guibwl guibwl requested a review from aduh95 December 27, 2023 01:53
tests/httpUtils.test.ts Outdated Show resolved Hide resolved
tests/httpUtils.test.ts Show resolved Hide resolved
guibwl and others added 2 commits December 27, 2023 23:16
Co-authored-by: Antoine du Hamel <[email protected]>
Co-authored-by: Antoine du Hamel <[email protected]>
@guibwl guibwl requested a review from aduh95 December 27, 2023 15:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants