-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Program is stuck after calling .text() on Response in WSL 2 #1604
Comments
Does the response text ever end? Or does it just download more text forever (normally)? What if you stream the body in chunks? |
@seanmonstar - The response body has a finite length. When doing a curl request, you will get the whole response at once. I just tried using the
But, it stops execution at around 15% of the data. The last record I can see in the logs is |
I am seeing a similar behaviour; E.g.
There is an The other site (busybox httpd) runs on the same host and sends data
(I ran this later, but relation of timestamps is always the same: server |
my problem seems to be caused by slirp4netns (rootless containers, rootless-containers/slirp4netns#302) |
The following issue seems to only be reproducable in WSL 2 (Ubuntu 20.04).
Rust version: 1.63.0
cargo.toml
main.rs
Output:
The last
println!()
never executes and there is no panic.Further information:
url
is replaced withhttp://www.google.com
.bytes()
leads to the same issue200
with.status()
on the Response structcurl
request from WSL 2 does return the correct response (curl --location --request GET 'https://query1.finance.yahoo.com/v7/finance/download/MSF.DE?period1=0&period2=1660519459&interval=1d&events=history'
)I also enabled the
RUST_LOG=debug
logging. This is the only output I am seeing:The text was updated successfully, but these errors were encountered: