-
Notifications
You must be signed in to change notification settings - Fork 219
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
CLType of {"ByteArray":32}
returned in deploy
#1437
Comments
That's an interesting point! I agree it's possible, and might make the ergonomics slightly better for users consuming the JSON. However, there are a couple of factors at play here. While it's true that many of the other variants of the A more practical problem with adopting the approach you suggest is that we currently just derive the In its binary format, the nested length of the So, on the one hand we need the I'll not close this issue for now so we can discuss further, but my current inclination is to not change from the status quo. Thanks anyway for raising the issue. It's a point I hadn't considered up until now :) |
Yeah, understand. If the types can be arbitrarily complex then objects are going to be required, it's just a pain to map JSON to an internal struct when the value can have different types (string or object). Although it would be possible to build a full JSON representation of a CLType that was well-defined and had a single defined structure, I very much doubt that it is worth your time to do so. I'll patch something up in my parser instead. Thanks for the detailed response. |
When querying the deploy with hash
f81d0a32890b47a5dfbb55c7bffe75d2a9301c442f7857b1908409b8e9921e83
on mainnet returns a JSON structure with the following:however
cl_type
is meant to be an enum rather than an object. Given the byte array size can be inferred from thebytes
field can this be altered so thecl_type
is just a simpleByteArray
value as per other CL types?The text was updated successfully, but these errors were encountered: