Bytes
Closed this issue · 1 comments
wotori commented
How to use type bytes?
let value: TagValue<Bytes> = client.read_tag(tag).await?;
error[E0412]: cannot find type `Bytes` in this scope
--> src/main.rs:12:25
|
12 | let value: TagValue<Bytes> = client.read_tag(tag.clone()).await?;
| ^^^^^ not found in this scope
|
help: consider importing one of these items
|
1 | use core::str::Bytes;
|
1 | use std::io::Bytes;
|
1 | use std::str::Bytes;
|
I have tried all imports suggested by the compiler but did not succeed
Joylei commented
you need to add bytes to your Cargo.toml
bytes = "1"
Then you have byte::Bytes