Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug report: send_tokens function #388

Open
mohammadworks opened this issue Mar 26, 2024 · 0 comments
Open

Bug report: send_tokens function #388

mohammadworks opened this issue Mar 26, 2024 · 0 comments

Comments

@mohammadworks
Copy link

mohammadworks commented Mar 26, 2024

I was using the send_tokens function.

private_key = ""
to_address = ""
memo = ""
amount = ""

client = LedgerClient(NetworkConfig(
            chain_id="cosmoshub-4",
            url="rest+https://cosmos-rest.publicnode.com",
            fee_minimum_gas_price=0.005,
            fee_denomination="uatom",
            staking_denomination="uatom",
        ))

wallet = LocalWallet(PrivateKey(private_key), 'cosmos')
transaction = client.send_tokens(
    destination=Address(to_address),
    amount=int(amount * Decimal('1_000_000')),
    denom='uatom',
    sender=wallet,
    memo=memo
)
transaction.wait_to_complete()

but recently I got the following error:

google.protobuf.json_format.ParseError: Failed to parse result field: Failed to parse events field: Failed to parse attributes field: Failed to parse key field: Invalid base64-encoded string: number of data characters (9) cannot be 1 more than a multiple of 4....

How can I solve this issue?

@mohammadworks mohammadworks changed the title Bug report: send_token function Bug report: send_tokens function Mar 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant