Closed ayrat555 closed 4 years ago
@ayrat555 Can you provide more details. I tried to reproduce it but it works for me. Please have a look at #90.
@andy128k Thank you for looking into the issue.
I'm not sure but I think when you saved the feed to file you fixed its encoding. Can you try using from_url
feature?
@ayrat555 Actually file is in cp1251. It is github who converts it. If you open a file and click "Raw", you will see it is still cp1251.
I am going to remove from_url
feature soon. (see #88).
ok. I'll look into it again on the weekend. Currently, I use rss
for https://github.com/ayrat555/el_monitorro . And it doesn't handle the encoding well. Initially, I used from_url
feature, but got rid of it, and result is the same. I get symbols like Заначка
the values come directly from rss
, I don't do any pre-processing
@ayrat555 Looks like double decoding happens here.
quick-xml
(it is used by rss
).Try to change your read_url
function to return Vec<u8>
instead of String
.
@andy128k thank you. it was exactly that. https://github.com/ayrat555/el_monitorro/commit/87e1f5bbead4627aedf9434a4f74536e2401024b
rss
uses wrong encoding for non-utf8 text For example https://pikabu.ru/xmlfeeds.php?cmd=popular