fix(client/v2): *big.Int unmarshal (#21853)

This commit is contained in:
Julien Robert
2024-10-08 15:14:23 +00:00
committed by GitHub
parent 5fea67d59c
commit 43c41be136
5 changed files with 62 additions and 8 deletions
+5 -5
View File
@@ -112,7 +112,7 @@ var marshalOption = proto.MarshalOptions{
func (w *builder) getTx() (*gogoTxWrapper, error) {
anyMsgs, err := msgsV1toAnyV2(w.msgs)
if err != nil {
return nil, err
return nil, fmt.Errorf("unable to convert messages: %w", err)
}
body := &txv1beta1.TxBody{
Messages: anyMsgs,
@@ -136,12 +136,12 @@ func (w *builder) getTx() (*gogoTxWrapper, error) {
bodyBytes, err := marshalOption.Marshal(body)
if err != nil {
return nil, err
return nil, fmt.Errorf("unable to marshal body: %w", err)
}
authInfoBytes, err := marshalOption.Marshal(authInfo)
if err != nil {
return nil, err
return nil, fmt.Errorf("unable to marshal auth info: %w", err)
}
txRawBytes, err := marshalOption.Marshal(&txv1beta1.TxRaw{
@@ -150,12 +150,12 @@ func (w *builder) getTx() (*gogoTxWrapper, error) {
Signatures: w.signatures,
})
if err != nil {
return nil, err
return nil, fmt.Errorf("unable to marshal tx raw: %w", err)
}
decodedTx, err := w.decoder.Decode(txRawBytes)
if err != nil {
return nil, err
return nil, fmt.Errorf("unable to decode tx: %w", err)
}
return newWrapperFromDecodedTx(w.addressCodec, w.codec, decodedTx)