-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: proposal to deploy v2.2.0 (#317)
- Loading branch information
1 parent
e920757
commit c743044
Showing
5 changed files
with
236 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
= History of Proposals | ||
|
||
. https://dashboard.internetcomputer.org/proposal/133448[133448]: re-install the EVM RPC canister |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,163 @@ | ||
# Proposal to reinstall the EVM RPC canister | ||
|
||
Repository: `https://github.com/internet-computer-protocol/evm-rpc-canister.git` | ||
|
||
Git hash: `3de8830e509cb97411367a153494e524573903f4` | ||
|
||
New compressed Wasm hash: `636442e4349a007316dcc1452d9a256d22203186181d2534f33bd264162305b3` | ||
|
||
Target canister: `7hfb6-caaaa-aaaar-qadga-cai` | ||
|
||
Previous EVM RPC proposal: https://dashboard.internetcomputer.org/proposal/132550 | ||
|
||
--- | ||
|
||
## Motivation | ||
|
||
This proposal does a complete re-installation of the EVM RPC canister using [v2.2.0](https://github.com/internet-computer-protocol/evm-rpc-canister/releases/tag/v2.2.0). | ||
The main changes are: | ||
* Immutable providers: providers are now hard-coded and could only be changed via a NNS proposal. | ||
* The URLs used are hard-coded and contain a placeholder for an API key, in case the provider does not support bearer authentication which is otherwise preferred. | ||
* Privileged principals (see install args below) can manage the API keys at runtime, without requiring a NNS proposal. The provided keys are validated by the canister, ensuring for example that URL escaping is not possible. Excepted for API keys, those privileged principals cannot change in any way the specified providers. | ||
* See this [forum post](https://forum.dfinity.org/t/evm-rpc-canister/23313/53) for more information. | ||
* Support a new threshold strategy to aggregate responses from multiple providers. This allows callers to be more robust against a single provider failure. | ||
* Added a new convenience method for `eth_call` to allow calling read-only functions of a smart contract. | ||
|
||
## Install args | ||
|
||
``` | ||
git fetch | ||
git checkout 3de8830e509cb97411367a153494e524573903f4 | ||
didc encode -d candid/evm_rpc.did -t '(InstallArgs)' '(record {demo = opt false; manageApiKeys = opt vec {principal "mf7xa-laaaa-aaaar-qaaaa-cai"}; logFilter = null})' | xxd -r -p | sha256sum | ||
``` | ||
|
||
* The `demo` flag is set to `false`, requiring callers to attach cycles to use the EVM RPC canister. | ||
* The principal `mf7xa-laaaa-aaaar-qaaaa-cai` is a DFINITY-controlled wallet that can manage API keys. | ||
* The `logFilter` is set to `null`, meaning that all logs will be visible. | ||
|
||
## Release Notes | ||
|
||
``` | ||
git log --format='%C(auto) %h %s' 79681296c422710d6acd6be87726741c1cda499f..3de8830e509cb97411367a153494e524573903f4 -- | ||
3de8830 chore: release v2.2.0 (#315) | ||
71f2fe7 ci: conventional commit checks (#316) | ||
2b8be23 fix: switch Alchemy with Llama nodes (#314) | ||
de5d3a4 build(deps): bump futures from 0.3.30 to 0.3.31 (#300) | ||
a8bb3b6 build(deps): bump regex from 1.10.6 to 1.11.0 (#296) | ||
8d15e59 fix: add missing `serde::Deserialize` annotation (#313) | ||
4b4942a fix: always deserialize `Block::totalDifficulty` to `None` (#312) | ||
f45b0c2 feat: support for `eth_call` (#308) | ||
453f932 fix: Candid interface compatibility (#310) | ||
460fb05 Update changelog and versions for upcoming release (#309) | ||
7a4695e refactor: improve debug of `RpcApi` (#307) | ||
f353ed3 refactor: Remove Ankr as a default provider (#305) | ||
ff91b91 refactor: improve debug and display representations (#304) | ||
916dce8 ci: Docker build on CI (#303) | ||
82fb737 chore: add changelog file (#302) | ||
47915da fix: `repository` link in `evm_rpc_types/Cargo.toml` (#301) | ||
4f799fa refactor: Move `InstallArgs` and `Provider` to the `evm_rpc_types` crate (#299) | ||
5f0221b refactor: use `evm_rpc_types` in Rust E2E canister (#295) | ||
93d3e9f fix: maximum value for `max_response_bytes` (#297) | ||
30e6b53 feat: implement `Error` trait for error types (#298) | ||
f968d1e chore: upgrade all dependencies (#294) | ||
a043a32 feat: optional console log message filter (#241) | ||
05743f9 chore: Remove dependencies on the IC repository (#293) | ||
9a94dba refactor: Use strongly typed fields in JSON requests and responses (#291) | ||
f32960e chore: bump dfx version (#221) | ||
c180aa4 fix: `TransactionReceipt` fields `status` and `to` should be optional (#290) | ||
691f840 feat: implement threshold strategy (#287) | ||
4661cef feat: Choose a consensus strategy (#286) | ||
7ec2f47 Update README.md (#280) | ||
bd0c177 refactor: move types (#285) | ||
eaf4764 refactor: simplify `CheckedAmountOf` (#283) | ||
bbd7046 refactor: consolidate JSON requests and responses (#279) | ||
557cd56 refactor: simplify `EthRpcClient` (#278) | ||
48b8f3d refactor: remove `cketh_eth_rpc_call_retry_count` metrics (#277) | ||
ecffde6 refactor: re-enable logs (#276) | ||
d03f343 refactor: Remove dependency on `ic-cketh-minter` (#275) | ||
4a15f9f fix!: change number of subnet nodes from 31 to 34 (#282) | ||
e6db092 fix!: change number of subnet nodes from 28 to 31 (#281) | ||
b5db0eb candid: rename `InitArgs` to `InstallArgs` (#272) | ||
cbbc772 candid!: remove `RpcService::Chain()` variant (#273) | ||
476e489 refactor: move types related to result to `evm-rpc-types` (#274) | ||
27f43f0 refactor: move types related to providers to `evm-rpc-types` crate (#271) | ||
e2158f0 test: RPC provider API key modifications (#269) | ||
98aed25 refactor: move `GetTransactionCountArgs` and `SendRawTransactionStatus` to `evm_rpc_types` (#270) | ||
a98a9bf refactor: move `Block` to `evm_rpc_types` (#268) | ||
f7eddd9 build(deps): bump async-trait from 0.1.81 to 0.1.82 (#265) | ||
c3b16ad build(deps): bump serde_json from 1.0.127 to 1.0.128 (#266) | ||
48ec38c build(deps): bump serde from 1.0.209 to 1.0.210 (#267) | ||
1e5ba9a feat!: NNS-managed RPC providers (#252) | ||
8ce8414 Minor typo in the README.md (#260) | ||
30cccbe refactor: move `TransactionReceipt` to `evm_rpc_types` (#263) | ||
0a39ab5 refactor: move `GetLogsArgs` and `LogEntry` to the `evm_rpc_types` crate (#261) | ||
c4f1bb3 build(deps): bump serde from 1.0.207 to 1.0.209 (#258) | ||
eccce39 build(deps): bump serde_json from 1.0.124 to 1.0.127 (#259) | ||
4da98ad build(deps): bump ic-cdk from 0.10.0 to 0.10.1 (#256) | ||
a55cd77 Merge pull request #257 from internet-computer-protocol/gdemay/243-types-crate | ||
56b282e 243: clean-up | ||
fb2a8c4 243: simplify test | ||
1171335 243: fix candid rename | ||
7a13e05 Revert "243: undo Candid changes in FeeHistory, since not yet used" | ||
f4537ca 243: use FeeHistory from new crate | ||
d5f3993 243: undo Candid changes in FeeHistory, since not yet used | ||
a42424e 243: update CHANGELOG.md | ||
8122891 243: fix candid | ||
c4cd5c5 243: fix conversion | ||
5dc3dcd 243: use FeeHistoryArgs from new crate | ||
b60d7d0 243: Nat256 conversion from rust unsigned int | ||
5ee3f72 243: Nat256::into_be_bytes | ||
897f925 243: Update FeeHistory to use Nat256 | ||
15fe5b2 243: tests nat 256 | ||
22a1717 243: nat 256 | ||
171150f 243: Candid types for fee history | ||
bbbc4b2 243: move serde to workspace dependencies | ||
93c459f 243: new crate for EVM RPC canister types | ||
4a30752 build(deps): bump serde from 1.0.206 to 1.0.207 (#251) | ||
8c343ca build(deps): bump serde from 1.0.204 to 1.0.206 (#249) | ||
aae7ca9 build(deps): bump serde_json from 1.0.122 to 1.0.124 (#250) | ||
94a94ec chore: misc. (#247) | ||
e8c1565 build(deps): bump async-trait from 0.1.80 to 0.1.81 (#237) | ||
8dd0a3c build(deps): bump serde_json from 1.0.121 to 1.0.122 (#246) | ||
3dc4fa7 build(deps): bump serde_json from 1.0.120 to 1.0.121 (#245) | ||
04505cc docs: minimal change to readme (#239) | ||
189469e Remove optional in 'eth_feeHistory' result type (#242) | ||
5bba82e build(deps): bump serde from 1.0.203 to 1.0.204 (#238) | ||
e6696d7 build(deps): bump serde_json from 1.0.118 to 1.0.120 (#236) | ||
3cce151 Merge pull request #235 from internet-computer-protocol/233-various-fields-in-block-should-be-optional | ||
c0aa689 233: add test for pre-london block | ||
d51e9cd 233: fix test | ||
622f60b 233: update candid file | ||
32b1e17 233: update cketh-common dependency | ||
4d9d625 build(deps): bump serde_json from 1.0.117 to 1.0.118 (#231) | ||
ef6b703 build(deps): bump serde_bytes from 0.11.14 to 0.11.15 (#232) | ||
b429db9 candid: remove hostname from `UpdateProviderArgs` (#229) | ||
024a8b3 Skip combination of Ankr + Arbitrum One + eth_getLogs (#230) | ||
b189828 build(deps): bump url from 2.5.1 to 2.5.2 (#228) | ||
5f608ca Allow any principal to call 'getAuthorized' (#225) | ||
50ea22b Bump 'setup-protoc' action to v3 (#226) | ||
0a074c4 ci: mitigate rate limits / inconsistent responses (#227) | ||
a8dc915 Add Llama RPC providers (#222) | ||
1ebaa83 build(deps): bump url from 2.5.0 to 2.5.1 (#223) | ||
24a7779 build(deps): bump serde from 1.0.202 to 1.0.203 (#217) | ||
89ecb93 dfx: add default canister init args (#220) | ||
b2efb2c Update README.md (#219) | ||
ad07855 feat: ability to update chain IDs via `manageProvider` method (#215) | ||
934075d build(deps): bump num from 0.4.2 to 0.4.3 (#210) | ||
435bae6 build(deps): bump num-traits from 0.2.18 to 0.2.19 (#207) | ||
4d84652 build(deps): bump serde_json from 1.0.116 to 1.0.117 (#209) | ||
a5abe61 build(deps): bump serde from 1.0.198 to 1.0.202 (#211) | ||
e814144 Update README.md (#216) | ||
0445e3b Add pull metadata (#214) | ||
``` | ||
|
||
## Wasm Verification | ||
|
||
Verify that the hash of the gzipped WASM matches the proposed hash. | ||
|
||
``` | ||
git fetch | ||
git checkout 3de8830e509cb97411367a153494e524573903f4 | ||
"./scripts/docker-build" | ||
sha256sum ./evm_rpc.wasm.gz | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
#!/bin/bash | ||
|
||
set -e -x | ||
|
||
# Pass API keys by environment variables | ||
# Fail if the variable is not set | ||
set -u # or set -o nounset | ||
: "$CLOUDFLARE_ETHEREUM_MAINNET_API_KEY" | ||
: "$ANKR_OPTIMISM_MAINNET_API_KEY" | ||
: "$ANKR_BASE_MAINNET_API_KEY" | ||
: "$ANKR_ETHEREUM_MAINNET_API_KEY" | ||
: "$ANKR_ARBITRUM_ONE_API_KEY" | ||
: "$BLOCK_PI_OPTIMISM_MAINNET_API_KEY" | ||
: "$BLOCK_PI_BASE_MAINNET_API_KEY" | ||
: "$BLOCK_PI_ETHEREUM_MAINNET_API_KEY" | ||
: "$BLOCK_PI_ARBITRUM_ONE_API_KEY" | ||
: "$ALCHEMY_OPTIMISM_MAINNET_API_KEY" | ||
: "$ALCHEMY_BASE_MAINNET_API_KEY" | ||
: "$ALCHEMY_ETHEREUM_MAINNET_API_KEY" | ||
: "$ALCHEMY_ARBITRUM_ONE_API_KEY" | ||
|
||
NETWORK="ic" | ||
IDENTITY="hsm" | ||
WALLET=$(dfx identity get-wallet --network=$NETWORK --identity=$IDENTITY) | ||
CANISTER="evm_rpc" | ||
FLAGS="--network=$NETWORK --identity=$IDENTITY --wallet=$WALLET" | ||
|
||
CLOUDFLARE_ETHEREUM_MAINNET_PROVIDER_ID="0"; | ||
|
||
ANKR_OPTIMISM_MAINNET_PROVIDER_ID="18"; | ||
ANKR_BASE_MAINNET_PROVIDER_ID="14"; | ||
ANKR_ETHEREUM_MAINNET_PROVIDER_ID="1"; | ||
ANKR_ARBITRUM_ONE_PROVIDER_ID="10"; | ||
|
||
BLOCK_PI_OPTIMISM_MAINNET_PROVIDER_ID="20"; | ||
BLOCK_PI_BASE_MAINNET_PROVIDER_ID="16"; | ||
BLOCK_PI_ETHEREUM_MAINNET_PROVIDER_ID="3"; | ||
BLOCK_PI_ARBITRUM_ONE_PROVIDER_ID="12"; | ||
|
||
ALCHEMY_OPTIMISM_MAINNET_PROVIDER_ID="19"; | ||
ALCHEMY_BASE_MAINNET_PROVIDER_ID="15"; | ||
ALCHEMY_ETHEREUM_MAINNET_PROVIDER_ID="8"; | ||
ALCHEMY_ARBITRUM_ONE_PROVIDER_ID="11"; | ||
|
||
dfx canister call ${CANISTER} updateApiKeys "(vec { | ||
record { ${CLOUDFLARE_ETHEREUM_MAINNET_PROVIDER_ID} : nat64; opt \"${CLOUDFLARE_ETHEREUM_MAINNET_API_KEY}\" }; | ||
record { ${ANKR_OPTIMISM_MAINNET_PROVIDER_ID} : nat64; opt \"${ANKR_OPTIMISM_MAINNET_API_KEY}\" }; | ||
record { ${ANKR_BASE_MAINNET_PROVIDER_ID} : nat64; opt \"${ANKR_BASE_MAINNET_API_KEY}\" }; | ||
record { ${ANKR_ETHEREUM_MAINNET_PROVIDER_ID} : nat64; opt \"${ANKR_ETHEREUM_MAINNET_API_KEY}\" }; | ||
record { ${ANKR_ARBITRUM_ONE_PROVIDER_ID} : nat64; opt \"${ANKR_ARBITRUM_ONE_API_KEY}\" }; | ||
record { ${BLOCK_PI_OPTIMISM_MAINNET_PROVIDER_ID} : nat64; opt \"${BLOCK_PI_OPTIMISM_MAINNET_API_KEY}\" }; | ||
record { ${BLOCK_PI_BASE_MAINNET_PROVIDER_ID} : nat64; opt \"${BLOCK_PI_BASE_MAINNET_API_KEY}\" }; | ||
record { ${BLOCK_PI_ETHEREUM_MAINNET_PROVIDER_ID} : nat64; opt \"${BLOCK_PI_ETHEREUM_MAINNET_API_KEY}\" }; | ||
record { ${BLOCK_PI_ARBITRUM_ONE_PROVIDER_ID} : nat64; opt \"${BLOCK_PI_ARBITRUM_ONE_API_KEY}\" }; | ||
record { ${ALCHEMY_OPTIMISM_MAINNET_PROVIDER_ID} : nat64; opt \"${ALCHEMY_OPTIMISM_MAINNET_API_KEY}\" }; | ||
record { ${ALCHEMY_BASE_MAINNET_PROVIDER_ID} : nat64; opt \"${ALCHEMY_BASE_MAINNET_API_KEY}\" }; | ||
record { ${ALCHEMY_ETHEREUM_MAINNET_PROVIDER_ID} : nat64; opt \"${ALCHEMY_ETHEREUM_MAINNET_API_KEY}\" }; | ||
record { ${ALCHEMY_ARBITRUM_ONE_PROVIDER_ID} : nat64; opt \"${ALCHEMY_ARBITRUM_ONE_API_KEY}\" }; | ||
})" ${FLAGS} | ||
|