I'm very new to rust so forgive me if this is a poor question. However all I am trying to do is get the data from a url and read it into a Document however I keep getting this error
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Custom { kind: InvalidData, error: StringError("stream did not contain valid UTF-8") }'
I took a look at this issue however my code still isn't too happy. All I'm doing is this..
let url = "http://www.google.com";
let resp = reqwest::get(url).unwrap();
let document = Document::from_read(resp).unwrap();
It works on other websites, but no all (including google). Am I doing something wrong? Could someone point me in the right direction?
I'm very new to rust so forgive me if this is a poor question. However all I am trying to do is get the data from a url and read it into a
Documenthowever I keep getting this errorI took a look at this issue however my code still isn't too happy. All I'm doing is this..
It works on other websites, but no all (including google). Am I doing something wrong? Could someone point me in the right direction?