mirror of
https://github.com/luxfi/node.git
synced 2026-10-30 15:24:05 +00:00
chains/oraclevm is 213 lines and is not the chain. It re-exports github.com/luxfi/oracle/vm, which is 1628; chains/relayvm is 161 lines over luxfi/relay/vm's 2077. Of the eight chains the node runs that the differential did not cover, the two that looked smallest by an order of magnitude were the two that were not there. The O-chain's wire is not a codec frame. ParseBlock is json.Unmarshal and Bytes is json.Marshal, so the wire is whatever encoding/json writes for the chain's structs, and computeID hashes the block marshalled AGAIN rather than the bytes it was handed. So a block does not round-trip its own id, and a member the reader accepts and omitempty then drops does not change it. Both are vectors now. Its genesis block is built with time.Unix, which is local time, and MarshalJSON writes the offset: one genesis file gives block id 6cf00752 with TZ unset on a -08:00 box and f4970a27 under Asia/Kolkata. Two validators in two timezones are on different chains from block zero. No vector can carry that id, so O_GENESIS pins the genesis through a re-marshal instead and conformance/README.md says why rather than letting the workaround hide the bug. 153 O vectors: the JSON wire and the id over it, the request id that gives a request its name, the Merkle root a request's records commit to, and the three refusals the observation plane has. The Rust and C++ ports answer every one of them and decline nothing, and all three implementations agree on all six compared fields. The C++ port compiles chains/cpp/fhevm's id.cpp and json.cpp rather than carrying a second opinion about what encoding/json accepts. Those two files are chain-neutral and their name is a debt: the right home is a shared one, and moving them is a rename across fifteen F-chain files. Co-authored-by: Hanzo Dev <[email protected]>