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

Network revision ran into issue #460

Open
robcxyz opened this issue Jun 28, 2024 · 0 comments
Open

Network revision ran into issue #460

robcxyz opened this issue Jun 28, 2024 · 0 comments

Comments

@robcxyz
Copy link
Contributor

robcxyz commented Jun 28, 2024

Leaving this up for posterity - next network revision can check again.

Got this error when submitting: https://tracker.icon.community/transaction/0xb708e3aa325ffd70293fa62c105d3806ab6fb144b48f6730ec213dc6a4065309

Issue was we gave the right payload but the value was coerced somehow. Payload should have been

[{'name': 'revision', 'value': {'revision': '0x19'}}]

Which if you decode the payload like this

import json

# The hex string
hex_string = "0x5b7b226e616d65223a227265766973696f6e222c2276616c7565223a7b227265766973696f6e223a2230783131227d7d5d"

# Step 1: Remove the '0x' prefix
hex_string = hex_string[2:]

# Step 2: Decode the hex string to bytes
bytes_data = bytes.fromhex(hex_string)

# Step 3: Decode the bytes to a string
json_string = bytes_data.decode('utf-8')

# Step 4: Parse the JSON string
json_data = json.loads(json_string)

print(json_data)
# [{'name': 'revision', 'value': {'revision': '0x11'}}]

So at least for one user, 0x19 was coerced to 0x11 somehow... Another user got this right via the tracker

https://tracker.icon.community/transaction/0x84859506330c96a91e330881cd29606836a7e989619486fa0aaed73be4ef7003

And that payload decodes correctly

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