-
Notifications
You must be signed in to change notification settings - Fork 243
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use non-compliant URL from 'url' for socks urls (#242)
`new URL('socks://host:port')` gives different results in browser and Node.js because `socks` is not among the "special schemes" specified by WHATWG and thus the hostname is treated as an opaque value (without parsing the port). Node.js implementation, however, parses the `port`. Since `proxy-agent` can be used in Electron, unless `URL` is imported directly from the Node's `url` module - it is going to use the Browser's version of it which won't work with socks urls.
- Loading branch information
1 parent
e625d10
commit 1d39f6c
Showing
4 changed files
with
10 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
'socks-proxy-agent': patch | ||
'pac-proxy-agent': patch | ||
'proxy-agent': patch | ||
--- | ||
|
||
Fix Electron support by using Node.js native URL object |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1d39f6c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
proxy-agents – ./
proxy-agents-git-main-tootallnate.vercel.app
proxy-agents-tootallnate.vercel.app
proxy-agents.vercel.app
proxy-agents.n8.io