wisespace-io / binance-rs

Rust Library for the Binance API
Other
688 stars 305 forks source link

missing `use binance::model::*` in readme market data example #153

Closed qtfkwk closed 2 years ago

qtfkwk commented 2 years ago

0.18.4 market data example in readme produces the error during cargo build:

error[E0412]: cannot find type `KlineSummary` in this scope
  --> src/bin/binance-kline.rs:84:32
   |
84 |                     let kline: KlineSummary = klines[0].clone(); // You need to iterate over the klines
   |                                ^^^^^^^^^^^^ not found in this scope
   |
help: consider importing this struct
   |
1  | use binance::futures::model::KlineSummary;
   |

For more information about this error, try `rustc --explain E0412`.
error: could not compile `cc` due to previous error

fix: add use binance::model::*;

wisespace-io commented 2 years ago

@qtfkwk Thank you for pointing it out.