-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
HTTPS Request: Invalid scheme for Http #1009
Comments
hyper no longer includes a default TLS library, so you'll need to pick one. I'd recommend hyper-native-tls. See #985 for reasoning. |
Ah, I see. Thanks for the link and reasoning! Would it be possible to make the error messages a little more clear though than they currently are? I tried quite a bit to debug this and was unable to find out anything by looking around with the error message. It probably would've helped if I've looked in the issues here more closely, but a quick search didn't show anything 😕 |
I could certainly see value in adding a |
That would be great! |
Of course, this would only alert you if you had some sort of logger setup... Separately, I wonder if it makes sense to change from suggesting |
Add native-tls + hyper-native-tls (see hyperium/hyper#1009) for now
I guess the good news is that when I searched for http-1009 this was the 2nd entry in Google's results, and the first one I clicked on, so you accomplished making information available for others who need help. |
Does this work with 0.11.0? It seems that |
This ^ im currently using 0.10 as hyper::net is gone. Any update on this..? |
Just ran into this. A couple of suggestions:
|
Related issue: <hyperium/hyper#1009>
Related issue: <hyperium/hyper#1009>
Just ran into this. I copy and pasted the snippet from the client guide, and changed the URL to https scheme, boom. This is 2019, please look around: plain http is not used any more. As for your example, http://httpbin.org: if i enter "httpbin.org" into my browser URL, it will use https://httpbin.org.
https should be the default, and the #1 rust http client library that shows up on Google (via https) should support it out-of-the-box, or have a feature matrix as the first section that clearly states that https requires extra effort. I'm already prepared to find out hyper doesn't support proxies ;) |
Why does this code still run into the error "invalid URL, scheme is not http". |
Thx |
This error is still as-is, in 2022. |
I don't know why but it worked for the last month, even with https urls, I didn't use any tls crates, and now it is throwing this error |
Commenting on 5 year old issues is not the best way to get assistance. |
I'm currently building against v0.10 and am experiencing some issues trying to send a request on macOS 10.12.
Here's a minimal example.
When I build against
hyper = { version = "0.9", default-features = false, features = ["security-framework"] }
this example runs just fine, so I'm guessing the issue has something to do with macOS' security-framework handling in hyper?The error does not occur when requesting http://httpbin.org/get.
The text was updated successfully, but these errors were encountered: