chore: bump version to 0.1.7

- Improve index parsing logic with better error handling
This commit is contained in:
ysq
2025-07-29 23:11:20 +08:00
parent 0a4be48b99
commit 3e41481cfa
4 changed files with 17 additions and 7 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
[package] [package]
name = "solana-streamer-sdk" name = "solana-streamer-sdk"
version = "0.1.6" version = "0.1.7"
edition = "2021" edition = "2021"
authors = ["William <byteblock6@gmail.com>", "sgxiang <sgxiang@gmail.com>", "wei <1415121722@qq.com>"] authors = ["William <byteblock6@gmail.com>", "sgxiang <sgxiang@gmail.com>", "wei <1415121722@qq.com>"]
repository = "https://github.com/0xfnzero/solana-streamer" repository = "https://github.com/0xfnzero/solana-streamer"
+2 -2
View File
@@ -33,14 +33,14 @@ Add the dependency to your `Cargo.toml`:
```toml ```toml
# Add to your Cargo.toml # Add to your Cargo.toml
solana-streamer-sdk = { path = "./solana-streamer", version = "0.1.6" } solana-streamer-sdk = { path = "./solana-streamer", version = "0.1.7" }
``` ```
### Use crates.io ### Use crates.io
```toml ```toml
# Add to your Cargo.toml # Add to your Cargo.toml
solana-streamer-sdk = "0.1.6" solana-streamer-sdk = "0.1.7"
``` ```
## Usage Examples ## Usage Examples
+2 -2
View File
@@ -33,14 +33,14 @@ git clone https://github.com/0xfnzero/solana-streamer
```toml ```toml
# 添加到您的 Cargo.toml # 添加到您的 Cargo.toml
solana-streamer-sdk = { path = "./solana-streamer", version = "0.1.6" } solana-streamer-sdk = { path = "./solana-streamer", version = "0.1.7" }
``` ```
### 使用 crates.io ### 使用 crates.io
```toml ```toml
# 添加到您的 Cargo.toml # 添加到您的 Cargo.toml
solana-streamer-sdk = "0.1.6" solana-streamer-sdk = "0.1.7"
``` ```
## 使用示例 ## 使用示例
+12 -2
View File
@@ -326,8 +326,18 @@ pub trait EventParser: Send + Sync {
let i_index_parent_index = i_index.split(".").nth(0).unwrap(); let i_index_parent_index = i_index.split(".").nth(0).unwrap();
let in_index_parent_index = in_index.split(".").nth(0).unwrap(); let in_index_parent_index = in_index.split(".").nth(0).unwrap();
if i_index_parent_index == in_index_parent_index { if i_index_parent_index == in_index_parent_index {
let i_index_child_index = i_index.split(".").nth(1).unwrap(); let i_index_child_index = i_index
let in_index_child_index = in_index.split(".").nth(1).unwrap(); .split(".")
.nth(1)
.unwrap()
.parse::<u32>()
.unwrap_or(0);
let in_index_child_index = in_index
.split(".")
.nth(1)
.unwrap()
.parse::<u32>()
.unwrap_or(0);
if in_index_child_index > i_index_child_index { if in_index_child_index > i_index_child_index {
instruction_event.merge(inner_instruction_event.clone_boxed()); instruction_event.merge(inner_instruction_event.clone_boxed());
break; break;