Skip to content

Commit

Permalink
Resolve conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
makoto committed Dec 1, 2023
2 parents 381345a + 6865e7b commit be7eee5
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 21 deletions.
10 changes: 5 additions & 5 deletions arb-gateway/README.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
# @ensdomains/arb-gateway

An instantiation of [evm-gateway](https://github.com/ensdomains/evmgateway/tree/main/evm-gateway) that targets Optimism - that is, it implements a CCIP-Read gateway that generates proofs of contract state on Optimism.
An instantiation of [evm-gateway](https://github.com/ensdomains/evmgateway/tree/main/evm-gateway) that targets Arbitrum - that is, it implements a CCIP-Read gateway that generates proofs of contract state on Arbitrum.

For a detailed readme and usage instructions, see the [monorepo readme](https://github.com/ensdomains/evmgateway/tree/main).

## How to use op-gateway locally via cloudflare dev env (aka wrangler)
## How to use arb-gateway locally via cloudflare dev env (aka wrangler)

```
npm install -g bun
cd op-gateway
cd arb-gateway
bun install
touch .dev.vars
## set L1_PROVIDER_URL, L2_PROVIDER_URL, L2_ROLLUP
yarn dev
```

## How to deploy op-gateway to cloudflare
## How to deploy arb-gateway to cloudflare

```
cd op-gateway
cd arb-gateway
npm install -g wrangler
wrngler login
Expand Down
2 changes: 1 addition & 1 deletion arb-verifier/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# @ensdomains/op-verifier
# @ensdomains/arb-verifier

A complete Solidity library that facilitates sending CCIP-Read requests for Arbitrum state, and verifying the responses.

Expand Down
5 changes: 2 additions & 3 deletions arb-verifier/contracts/ArbVerifier.sol
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,13 @@ contract ArbVerifier is IEVMVerifier {
* Decodes a block by extracting and converting the bytes32 value from the RLP-encoded block information.
*
* @param {bytes} rlpEncodedBlock - The RLP-encoded block information.
* @returns {bytes32} The decoded bytes32 value extracted from the RLP-encoded block information.
*
* @notice This function is designed to be used internally within the contract.
* @returns {bytes32} The stateRoot extracted from the RLP-encoded block information.
*/
function decodeBlock(
bytes memory rlpEncdoedBlock
) internal pure returns (bytes32) {
RLPReader.RLPItem[] memory i = RLPReader.readList(rlpEncdoedBlock);
//StateRoot is located at idx 3
return bytes32(RLPReader.readBytes(i[3]));
}
}
22 changes: 12 additions & 10 deletions arb-verifier/hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@ import '@nomicfoundation/hardhat-toolbox';
import 'hardhat-deploy';
import 'hardhat-deploy-ethers';
import { HardhatUserConfig } from 'hardhat/config';
import 'ethers'
const DEPLOYER_PRIVATE_KEY = process.env.DEPLOYER_PRIVATE_KEY || "ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80";
import 'ethers';
const DEPLOYER_PRIVATE_KEY =
process.env.DEPLOYER_PRIVATE_KEY ||
'ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80';
const L1_PROVIDER_URL = process.env.L1_PROVIDER_URL || '';
const L1_ETHERSCAN_API_KEY = process.env.L1_ETHERSCAN_API_KEY;
const L2_ETHERSCAN_API_KEY = process.env.L2_ETHERSCAN_API_KEY;
Expand All @@ -12,26 +14,26 @@ const config: HardhatUserConfig = {
solidity: '0.8.19',
networks: {
arbDevnetL1: {
url: "http://127.0.0.1:8545/",
url: 'http://127.0.0.1:8545/',
accounts: [
'0xb6b15c8cb491557369f3c7d2c287b053eb229daa9c22138887752191c9520659',
],
deploy: ["deploy_l1/"],
deploy: ['deploy_l1/'],
companionNetworks: {
l2: "arbDevnetL2",
l2: 'arbDevnetL2',
},
},
arbDevnetL2: {
url: "http://127.0.0.1:8547/",
url: 'http://127.0.0.1:8547/',
accounts: [
'0xb6b15c8cb491557369f3c7d2c287b053eb229daa9c22138887752191c9520659',
],
deploy: ["deploy_l2/"],
deploy: ['deploy_l2/'],
},
goerli: {
url: L1_PROVIDER_URL,
accounts: [DEPLOYER_PRIVATE_KEY],
deploy: ["deploy_l1/"],
deploy: ['deploy_l1/'],
companionNetworks: {
l2: 'arbitrumGoerli',
},
Expand Down Expand Up @@ -59,8 +61,8 @@ const config: HardhatUserConfig = {
],
},
namedAccounts: {
'deployer': 0,
}
deployer: 0,
},
};

export default config;
2 changes: 0 additions & 2 deletions arb-verifier/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@
},
"dependencies": {
"@ensdomains/evm-verifier": "^0.1.0",
"@eth-optimism/contracts": "^0.6.0",
"@eth-optimism/contracts-bedrock": "^0.16.2",
"@arbitrum/nitro-contracts": "^1.1.0"
}
}

0 comments on commit be7eee5

Please sign in to comment.