Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyFuncIfNoError ¶
This function lets you run the function f, but if theres an error or panic drop the state machine change and log the error. If there is no error, proceeds as normal (but with some slowdown due to SDK store weirdness) Try to avoid usage of iterators in f.
If its an out of gas panic, this function will also panic like in normal tx execution flow. This is still safe for beginblock / endblock code though, as they do not have out of gas panics.
func IsOutOfGasError ¶
Frustratingly, this has to return the error descriptor, not an actual error itself because the SDK errors here are not actually errors. (They don't implement error interface)
func PrintPanicRecoveryError ¶
PrintPanicRecoveryError error logs the recoveryError, along with the stacktrace, if it can be parsed. If not emits them to stdout.
Types ¶
This section is empty.