cosmpy icon indicating copy to clipboard operation
cosmpy copied to clipboard

Bug report: ParseError when use TxRestClient.GetTxsEvent method

Open SteveMBao opened this issue 1 year ago • 1 comments

Prerequisites

Expected Behavior

Hello Team, I'm using cosmpy 0.9.2 version and sei chain (atlantic-2 testnet) to code my idea, I'm use contract_address to get txs event, it work fine, like this: image

Current Behavior

But when I'm using message.sender='wallet address' to fetch txs, it can't parse and report bug: Can not find message descriptor by type_uri: /cosmos.bank.v1beta1.MsgSend image

To Reproduce

You can see the test wallet all txs at https://sei-testnet-api.polkachu.com/cosmos/tx/v1beta1/txs?events=message.sender=%27sei1304xws6x0t5wqzjmwq3fsffemtv4ayezvdvy36%27, image

the MsgSend tx can't parse in cosmpy package

Context

OS: Ubuntu 2204 LTS Python: 3.12.2 cosmpy: 0.9.2

Failure Logs

# it's all my code
from google.protobuf.json_format import MessageToDict
from cosmpy.tx.rest_client import RestClient, TxRestClient
from cosmpy.protos.cosmos.tx.v1beta1.service_pb2 import (
    GetTxsEventRequest,
)

rc = RestClient("http://sei-testnet-api.polkachu.com")
tr = TxRestClient(rc)

param1 = GetTxsEventRequest(
    events=[
        "execute._contract_address='sei1zpm70e2vtsskynmqfw4um3erdxw50g7tz99frmuv2v2t862exdfqxsrd89'"
    ]
)
# it's work fine
print(MessageToDict(param1))
resp = tr.GetTxsEvent(param1)
print(resp)

param2 = GetTxsEventRequest(
    events=[
        "message.sender='sei1304xws6x0t5wqzjmwq3fsffemtv4ayezvdvy36'"
    ]
)

# it's report can't parse MsgSend
print(MessageToDict(param2))
resp = tr.GetTxsEvent(param2)
print(resp)

SteveMBao avatar May 23 '24 08:05 SteveMBao

Hey @SteveMBao

Thank you for reporting this issue. Our team will investigate promptly.

kshipra-fetch avatar Jul 26 '24 11:07 kshipra-fetch