Skip to content

Commit 3904228

Browse files
mergify[bot]facundomedicatac0turtle
authored
fix: allow tx decoding to fail in GetBlockWithTxs (backport #20323) (#20329)
Co-authored-by: Facundo Medica <[email protected]> Co-authored-by: marbar3778 <[email protected]>
1 parent 9f8e3a5 commit 3904228

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

x/auth/tx/service.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -195,13 +195,13 @@ func (s txServer) GetBlockWithTxs(ctx context.Context, req *txtypes.GetBlockWith
195195
if req.Pagination != nil && req.Pagination.Reverse {
196196
for i, count := offset, uint64(0); i > 0 && count != limit; i, count = i-1, count+1 {
197197
if err = decodeTxAt(i); err != nil {
198-
return nil, err
198+
sdkCtx.Logger().Error("failed to decode tx", "error", err)
199199
}
200200
}
201201
} else {
202202
for i, count := offset, uint64(0); i < blockTxsLn && count != limit; i, count = i+1, count+1 {
203203
if err = decodeTxAt(i); err != nil {
204-
return nil, err
204+
sdkCtx.Logger().Error("failed to decode tx", "error", err)
205205
}
206206
}
207207
}

0 commit comments

Comments
 (0)