ithacaxyz / odyssey

A testnet open-source Layer 2 from the future, co-designed with the developer tools stack.
https://www.ithaca.xyz/updates/odyssey
Apache License 2.0
137 stars 28 forks source link

Use quantity for chainid key type #49

Open mattsse opened 4 hours ago

mattsse commented 4 hours ago

this should serialize chainid as quantity (U64)

https://github.com/ithacaxyz/odyssey/blob/bc8c87e08ca07dfec3a6cc00bb0488c1e24248c4/crates/wallet/src/lib.rs#L60-L60

this could be made nicer if we had https://github.com/alloy-rs/alloy/issues/1502

but for now we need to use the alloy-primitives::U64 type here instead of u64

TODO

0xurb commented 4 hours ago

request (alloy_rpc_types::TransactionRequest) chainId is u64 tho

mattsse commented 4 hours ago

ah sorry my issue was vague, I was referring to serde here

HashMap<ChainId, Capabilities>

should serialize chainid keys as quantity (hex)