Skip to content

Commit a223e72

Browse files
committed
fix
1 parent e8a1299 commit a223e72

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

src/shim/trace.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use cid::Cid;
1111
use fvm_ipld_encoding::{RawBytes, ipld_block::IpldBlock};
1212
use fvm2::trace::ExecutionEvent as E2;
1313
use fvm3::trace::ExecutionEvent as E3;
14-
use fvm4::trace::ExecutionEvent as E4;
14+
use fvm4::trace::{ExecutionEvent as E4, IpldOperation};
1515
use itertools::Either;
1616

1717
#[derive(Debug, Clone)]
@@ -23,6 +23,12 @@ pub enum ExecutionEvent {
2323
CallError(ShimSyscallError),
2424
Log(String),
2525
InvokeActor(Either<Cid, InvokeActor>),
26+
#[allow(dead_code)]
27+
Ipld {
28+
op: IpldOperation,
29+
cid: Cid,
30+
size: usize,
31+
},
2632
Unknown(Either<E3, Either<E4, E2>>),
2733
}
2834

@@ -146,6 +152,8 @@ impl From<E4> for ExecutionEvent {
146152
id,
147153
state: state.into(),
148154
})),
155+
E4::Log(s) => EShim::Log(s),
156+
E4::Ipld { op, cid, size } => EShim::Ipld { op, cid, size },
149157
e => EShim::Unknown(Either::Right(Either::Left(e))),
150158
}
151159
}

src/state_manager/utils.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -342,6 +342,7 @@ pub mod structured {
342342
}
343343
ExecutionEvent::Log(_ignored) => {}
344344
ExecutionEvent::InvokeActor(_cid) => {}
345+
ExecutionEvent::Ipld { .. } => {}
345346
ExecutionEvent::Unknown(u) => {
346347
return Err(BuildExecutionTraceError::UnrecognisedEvent(Box::new(u)));
347348
}
@@ -413,6 +414,7 @@ pub mod structured {
413414
};
414415
None
415416
}
417+
ExecutionEvent::Ipld { .. } => None,
416418
// RUST: This should be caught at compile time with #[deny(non_exhaustive_omitted_patterns)]
417419
// So that BuildExecutionTraceError::UnrecognisedEvent is never constructed
418420
// But that lint is not yet stabilised: https://github.com/rust-lang/rust/issues/89554

0 commit comments

Comments
 (0)