crypto-crawler / crypto-crawler-rs

A rock-solid cryptocurrency crawler library.
Apache License 2.0
217 stars 71 forks source link

fix: cannot parse binance ws endopint like wss://dstream.binance.com/… #51

Closed GhostLee closed 1 year ago

GhostLee commented 1 year ago
let url = Url::parse("wss://dstream.binance.com/stream").unwrap();
assert!(url.port() == None);

Binance endpoint cannot be parsed, it should use port_or_known_default to set default port value.

pan93412 commented 1 year ago

@soulmachine Maybe we shouldn't enforce a PR to pass Cargo test? I saw a lot of Operation timed out, and seems like GitHub Actions is not stable for sending a request.

soulmachine commented 1 year ago

Thanks for the bugfix!

Yeah, some tests are failing, so I skipped them and merged your PR.