Skip to content

Commit 09f06c9

Browse files
committed
fix: do not panic! on ErrorMap::Panic
1 parent fc2b7a1 commit 09f06c9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

clarity/src/vm/clarity_wasm.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7810,7 +7810,9 @@ mod error_mapping {
78107810
Error::Runtime(RuntimeErrorType::UnwrapFailure, Some(Vec::new()))
78117811
}
78127812
ErrorMap::Panic => {
7813-
panic!("An error has been detected in the code")
7813+
// TODO: see issue: #531
7814+
// This RuntimeErrorType::UnwrapFailure need to have a proper context.
7815+
Error::Runtime(RuntimeErrorType::UnwrapFailure, Some(Vec::new()))
78147816
}
78157817
// TODO: UInt(42) value below is just a placeholder.
78167818
// It should be replaced by the current "thrown-value" when clarity-wasm issue #385 is resolved.

0 commit comments

Comments
 (0)