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

fix(git): normalize repo url without legacy url.parse #5100

Merged
merged 2 commits into from Nov 30, 2022

Conversation

merceyz
Copy link
Member

@merceyz merceyz commented Nov 26, 2022

What's the problem this PR addresses?

Node introduced a breaking change to url.parse in v19.1.0 that prevents it from parsing certain git URLs.
That change was reverted and made into a documentation only deprecation in v19.2.0, will be a runtime warning in v20, and then probably throw again in v21.

How did you fix it?

Replace the use of url.parse with the parse function from https://github.com/npm/hosted-git-info/blob/cf8115d6fa056fbfb0d63d4d13bde6116b2a02e0/lib/parse-url.js.

Checklist

  • I have read the Contributing Guide.
  • I have set the packages that need to be released for my changes to be effective.
  • I will check that all automated PR checks pass before the PR gets reviewed.

@paul-soporan
Copy link
Member

Is there a reason for not depending on hosted-git-info directly?

@merceyz
Copy link
Member Author

merceyz commented Nov 29, 2022

Yes, its package.json#engines.node range doesn't line up with ours.

@arcanis arcanis merged commit 8aa8d5c into master Nov 30, 2022
@arcanis arcanis deleted the merceyz/fix/parse-git branch November 30, 2022 13:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants