InputUsername / listenbrainz-rs

ListenBrainz API bindings for Rust
https://crates.io/crates/listenbrainz
MIT License
11 stars 6 forks source link

Replace ureq with attohttpc #3

Closed shymega closed 3 years ago

shymega commented 3 years ago

As discussed here using attohttpc could be a viable repalcement for ureq.

InputUsername commented 3 years ago

The same person also mentioned ureq should work fine for api.listenbrainz.org, but I'd have to investigate that. ureq might still break for other hosts though, so maybe attohttpc is the best option regardless.

Thoughts?

shymega commented 3 years ago

Hm. I'm not sure myself but as ureq works on api.listenbrainz.org, we don't know for sure that it'll work on alternative hosts. So, we either do more investigations with ureq and alternate hosts, or we switch to attohttpc completely and bypass proper testing.

InputUsername commented 3 years ago

I say we go with attohttpc then.

shymega commented 3 years ago

OK, so we'll have to rewrite the agent calls in raw/client.rs module. Can I leave that to you? Once that's done, there shouldn't be any other usages of ureq, as the crate abstracts over the client.