Open ameten opened 1 month ago
Initial investigation tells me that we just need to add merkleTree to the Warp core artifacts. The addresses.yaml will then be created with this registry fn: https://github.com/hyperlane-xyz/hyperlane-registry/blob/8b5b0a4618dd824c4765ce9dac08eaca9bda6e07/src/registry/FileSystemRegistry.ts#L97-L106
Problem
Observed behaviour
When Hyperlane is deployed to a chain which contains a standard official deployment of Hyperlane already, validator will use the MerkleTreeHook contact from the official deployment.
Expected behaviour
When Hyperlane is deployed to a chain which contains a standard official deployment of Hyperlane already, validator should use MerkleTreeHook contact from the custom deployment of Hyperlane.
Root cause
Hyperlane CLI does not populate MerkleTreeHook contract address into
addresses.json
file when it deployed core contracts to a change. Hence, CLI uses official MerkleTreeHook contract address inagent-config.json
. Therefore, Validator reads the official MerkleTreeHook and indexes it instead of the one deployed by a developer.Solution
addresses.json
file of chain when core contracts are deployed byhyperlane core deploy
.addresses.json
when generating agent config byhyperlane registry agent-config
.