-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add geyser plugin runner #83
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we use workspaces here? https://doc.rust-lang.org/cargo/reference/workspaces.html
would be good to have rust-toolchain.toml
so rust version would be fixed https://rust-lang.github.io/rustup/overrides.html
} | ||
|
||
impl DataFrame { | ||
pub fn from_bytes(data: Vec<u8>) -> Result<DataFrame, Box<dyn Error>> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
anyhow
+ thiserror
usually is idiomatic error handing in rust
pub fn from_bytes(data: Vec<u8>) -> Result<DataFrame, Box<dyn Error>> { | ||
let decoded_data: serde_cbor::Value = serde_cbor::from_slice(&data).unwrap(); | ||
let data_frame = DataFrame::from_cbor(decoded_data)?; | ||
return Ok(data_frame); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return Ok(data_frame); | |
Ok(data_frame) |
I guess there more things like this, would be good to have cargo tree
/ fmt
/ clippy
in CI
This PR adds the rust code that can be used to read old-faithful CAR files and send their contents to a Solana geyser plugin.
This PR provides the rust libraries to read CAR files, and a CLI to dum a CAR file to a geyser plugin.