Basic Info
- Faraday Version: 1.4.1
- Ruby Version: 2.7
Issue description
Proxy silently ignored without http:. For example, if you set proxy to something:1234 it will be silently ignored. The correct proxy setting would be http://something:1234. This is an important issue because it's undocumented, difficult to debug, and can have serious consequences for crawling projects.
I propose either:
- In ProxyOptions.from, reject strings that lack a scheme.
or
- In ProxyOptions.from, default to
http:// for strings that lack a scheme.
Let me know if you agree with one of these options and I'l put together a PR. Thanks!
Steps to reproduce
> Faraday::ProxyOptions.from("something:1234").host
# => nil
> Faraday::ProxyOptions.from("http://something:1234").host
# => "something"
Basic Info
Issue description
Proxy silently ignored without
http:. For example, if you set proxy tosomething:1234it will be silently ignored. The correct proxy setting would behttp://something:1234. This is an important issue because it's undocumented, difficult to debug, and can have serious consequences for crawling projects.I propose either:
or
http://for strings that lack a scheme.Let me know if you agree with one of these options and I'l put together a PR. Thanks!
Steps to reproduce