-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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: use reqwest as http client #2822
feat: use reqwest as http client #2822
Conversation
I'm getting compilation errors related to mismatched crate versions. It looks like @ry does this situation disqualify using |
@ry PTAL, this is now feature complete. If you're fine with downgrading Benefits of using
|
@piscisaureus can you run gnargo on this? |
Does this patch add proxy support? |
Implicitly - it's done by |
I suppose that means there's an environmental variable? Can you add some docs for this? |
Ah, sorry. It's not on by default:
I'll enable & document it in a follow up PR. |
I'm fine with landing this as two PRs, but I think we should see a proof-of-concept for proxy before landing this, since that's the whole purpose of reqwest (?). Maybe just do that work in this branch. |
@@ -87,26 +87,3 @@ impl AsyncRead for HttpBody { | |||
} | |||
} | |||
} | |||
|
|||
#[test] | |||
fn test_body_async_read() { |
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.
Unfortunately all methods of Decoder
are private or crate scoped, so there's no way to construct it manually...
@bartlomieju Url can be downgraded back to 1.7.2 IMO. |
@piscisaureus can you update deps in |
@bartlomieju I've added reqwest to the GN build. It builds for me but there are a few test failures. |
@piscisaureus tests fixed, please decide on the DNS resolver (I suggest we try the new one) and review |
7faaeec
to
d764ea8
Compare
d764ea8
to
19839f6
Compare
@@ -539,11 +531,6 @@ fn filter_shebang(bytes: Vec<u8>) -> Vec<u8> { | |||
} | |||
} | |||
|
|||
fn url_into_uri(url: &url::Url) -> http::uri::Uri { |
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.
Nice to see this go!
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.
LGTM.
@ry I noticed you had some comments about a POC HTTP proxy, but that isn't implemented at this point.
You still want to wait for that?
@piscisaureus proxy support is enabled - see |
If it can go green I’m ok with landing it |
19839f6
to
723284f
Compare
I landed this patch without the The patch that adds trust-dns (master...piscisaureus:reqwest_trust_dns) still applies, so we can land that at a later time if the tests can be made to go green. |
Closes #2720