From 884b9004db4ca6f65a922292383ce3fa418b913a Mon Sep 17 00:00:00 2001 From: Geoff Stuart Date: Tue, 1 Nov 2022 10:12:22 +0000 Subject: [PATCH] bubble up errors properly from ApplyImplicitMessage --- chain/stmgr/call.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/chain/stmgr/call.go b/chain/stmgr/call.go index 3c40ced53..92066ca81 100644 --- a/chain/stmgr/call.go +++ b/chain/stmgr/call.go @@ -133,7 +133,9 @@ func (sm *StateManager) Call(ctx context.Context, msg *types.Message, ts *types. // TODO: maybe just use the invoker directly? ret, err := vmi.ApplyImplicitMessage(ctx, msg) - // Don't check for error here, we want to bubble it up, but also return ret as an InvocResult + if err != nil && ret == nil { + return nil, xerrors.Errorf("apply message failed: %w", err) + } var errs string if ret.ActorErr != nil {