Closed gartnera closed 2 weeks ago
This update introduces enhancements to the lib/addresses.ts
and lib/types.ts
files. The lib/addresses.ts
file now includes an Address
interface and a setAdditionalAddresses
function to better manage additional addresses. The lib/types.ts
file has been expanded to add two new network types to the ParamChainName
enum, specifically eth_developnet
and zeta_developnet
, to support a broader range of network options within the system.
Files | Change Summary |
---|---|
lib/addresses.ts |
Introduced Address interface, added setAdditionalAddresses function, and updated getAddress . |
lib/types.ts |
Added eth_developnet and zeta_developnet to the ParamChainName enum. |
sequenceDiagram
participant User
participant App
participant getAddress
participant AdditionalAddresses
participant Mainnet
participant Testnet
User->>App: Request address
App->>getAddress: call getAddress(chainName)
getAddress->>AdditionalAddresses: Check additional addresses
alt Address found
AdditionalAddresses-->>getAddress: Return address
else Address not found
getAddress->>Mainnet: Check mainnet addresses
alt Address found
Mainnet-->>getAddress: Return address
else Address not found
getAddress->>Testnet: Check testnet addresses
Testnet-->>getAddress: Return address
end
end
getAddress-->>App: Return address
App-->>User: Send address
In the land of code, changes abound,
New networks are added, variety unbound.
Addresses managed with method so clear,
Witheth_developnet
, progress is near.
A rabbit rejoices, in code it has found,
A system more robust, truly profound. 🐇✨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
All modified and coverable lines are covered by tests :white_check_mark:
Please upload report for BASE (
main@6785f39
). Learn more about missing BASE report.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Closing as inactive
Allow downstream users to inject their own contract addresses if desired.
The contract addresses on localnet and developnet are not stable and must be pulled at runtime. This information will be retrieved from a json file via a network request. I had considered adding the logic here, but that doesn't seem quite right.
Related to https://github.com/zeta-chain/networks/pull/49
Summary by CodeRabbit
eth_developnet
andzeta_developnet
.