Repository navigation
docs(deploy): gas-free chain checks and their results - #54
Conversation
Tron's 0x09 is BatchValidateSign, which returns 32 bytes.
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
Changes are documentation, NatSpec comments, and one additive test with no production bytecode change, and all cross-references, numbers, and the new test's logic were verified consistent.
Review effort: Balanced
Findings: None
What changed in this PR
This PR records the results of the pre-mainnet chain checks that require no gas (eth_call/eth_getCode/provider source reads and local Forge gas measurements) so that onboarding a new chain or provider can repeat them. It introduces a new contracts/evm/deploy/CHECKS.md as the single source for each check (command + pass rule), per-provider endpoint addresses, and the measured results as of 2026-10-07, then rewires the surrounding docs and code comments to point at it. The research resolves two previously-open uncertainties in NatSpec (Tron's CREATE2 0x41 prefix from java-tron, and the BLAKE2F-at-0x09 behavior on zkSync/Tron) and files four non-blocking issues (#50–#53) rather than fixing them here.
Changes:
- Adds
deploy/CHECKS.mdand repointsdeploy/README.md §2,docs/todo.md §1–§2, anddocs/provider-research.mdto it. - Settles Tron
0x41and BLAKE2F comments inAddressDerive,DivergentAccounts,Blake2b256, andCloneDerivation.t.sol; adds a test that a foreign 32-byte return at0x09fails closed. - Adds a "Adding a chain or a provider" section to
CLAUDE.md.
| File | Description |
|---|---|
contracts/evm/deploy/CHECKS.md |
New file: all gas-free checks, provider ids/endpoint addresses, and 2026-10-07 results. |
contracts/evm/deploy/README.md |
§2 now defers to CHECKS.md instead of inlining the check list. |
docs/todo.md |
§1–§2 rewritten to summarize findings and reference CHECKS.md and issues #50–#53. |
docs/provider-research.md |
Notes java-tron source settles the Tron formula; bytecode hash still needs a deployment. |
contracts/evm/src/derivation/AddressDerive.sol |
Comment: 0x41 origin explained via WalletUtil.generateContractAddress2. |
contracts/evm/src/derivation/Blake2b256.sol |
Comment: enumerates the three non-EIP-152 0x09 outcomes the size check guards against. |
contracts/evm/src/messaging/transceiver/DivergentAccounts.sol |
Comment: Tron formula settled; only TRON-solc bytecode hash unverified. |
contracts/evm/test/CommitmentScheme.t.sol |
New test that a 32-byte return at 0x09 reverts PrecompileFailed. |
contracts/evm/test/CloneDerivation.t.sol |
Comment: formulas checked vs Era/java-tron; artifact hashes still need deployment. |
CLAUDE.md |
New section on which deploy files apply when adding a chain vs a provider. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Runs every pre-mainnet chain check that needs no gas (eth_call, provider and node source, local measurement) and records them so a new chain or provider can repeat them.
contracts/evm/deploy/CHECKS.md: each check with its command and pass rule, each provider's ids and endpoint addresses per chain, results as of 2026-10-07, and what the checks cannot cover.deploy/README.md§2 points to it.docs/todo.md§1–§2 record the findings.0x41from java-tron's source; comments inAddressDerive,DivergentAccounts,CloneDerivation.t.sol, and provider-research updated.Blake2b256: a test that another precompile at0x09(Tron'sBatchValidateSign, 32 bytes) fails closed, and the comment says so. Comments only insrc/; sizes unchanged.CLAUDE.md: which deploy files apply when adding a chain vs a provider.Found and filed, not fixed here: #50 (LayerZero empty options revert on every endpoint), #51 (LayerZero cannot reach zkSync), #52 (default gas below a bootstrap's cost), #53 (no Wormhole quoter router on the configured chains).
755 tests pass;
forge lintclean on both profiles.