Skip to content

Commit f0e29d6

Browse files
committed
Merge remote-tracking branch 'origin/main' into tamir/audit_fixes
2 parents 1b7a2e3 + 3c89370 commit f0e29d6

File tree

3 files changed

+26
-5
lines changed

3 files changed

+26
-5
lines changed

client/src/request.rs

+9-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ struct OffchainInput {
3838
}
3939

4040
#[allow(non_snake_case)]
41-
#[derive(Serialize, Deserialize)]
41+
#[derive(Serialize, Deserialize, Debug)]
4242
/// Proof data for a Succinct X function call.
4343
/// This is the data that is returned from the Succinct X API.
4444
struct SuccinctProofData {
@@ -81,6 +81,7 @@ const LOCAL_PROOF_FOLDER: &str = "./proofs";
8181

8282
/// Client to interact with the Succinct X API.
8383
#[allow(dead_code)]
84+
#[derive(Clone)]
8485
pub struct SuccinctClient {
8586
/// HTTP client.
8687
client: Client,
@@ -386,6 +387,13 @@ impl SuccinctClient {
386387
let client = Arc::new(SignerMiddleware::new(provider, wallet.clone()));
387388

388389
let address = get_gateway_address(succinct_proof_data.chain_id);
390+
if address.is_none() {
391+
info!(
392+
"Could not find canonical gateway address for chain {}",
393+
succinct_proof_data.chain_id
394+
);
395+
}
396+
389397
// If gateway_address is provided, use that instead of the canonical gateway address.
390398
let mut gateway_address = gateway_address.or(address).expect(
391399
"Gateway address must be provided when relaying a proof in local mode

client/src/utils.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
// List of Succinct Gateway addresses for chains.
2-
const GATEWAY_ADDRESSES: [(u32, &str); 6] = [
2+
const GATEWAY_ADDRESSES: [(u32, &str); 7] = [
33
(1, "0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803"),
44
(5, "0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803"),
55
(100, "0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803"),
6-
(420, "0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803"),
76
(17000, "0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803"),
7+
(42161, "0x2d27182206f0442885989626934ca9dd5290f979"),
8+
(421614, "0x2d27182206f0442885989626934ca9dd5290f979"),
89
(11155111, "0xaea9288f0b7a8c605c4d474c56e5e74f96bfd4b3"),
910
];
1011

contracts/README.md

+14-2
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,18 @@ forge test
2525
SUCCINCT_GATEWAY=[0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803](https://etherscan.io/address/0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803)
2626
SUCCINCT_FEE_VAULT=[0x5999d401444f15d262fdce310bb68bd234de11aa](https://etherscan.io/address/0x5999d401444f15d262fdce310bb68bd234de11aa)
2727

28+
| Chain | Chain ID | Address |
29+
|------------------|----------|------------------------------------------------------------------------------------------------------------------|
30+
| Mainnet | 1 | [0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803](https://etherscan.io/address/0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803) |
31+
| Goerli | 5 | [0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803](https://goerli.etherscan.io/address/0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803) |
32+
| Gnosis | 100 | [0x6e4f1e9eA315EBFd69d18C2DB974EEf6105FB803](https://gnosisscan.io/address/0x6e4f1e9eA315EBFd69d18C2DB974EEf6105FB803) |
33+
| Holesky | 17000 | [0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803](https://holesky.etherscan.io/address/0x6e4f1e9ea315ebfd69d18c2db974eef6105fb803) |
34+
| Arbitrum | 42161 | [0x2d27182206f0442885989626934ca9dd5290f979](https://arbiscan.io/address/0x2d27182206f0442885989626934ca9dd5290f979) |
35+
| Arbitrum Sepolia | 421614 | [0x2d27182206f0442885989626934ca9dd5290f979](https://sepolia.arbiscan.io/address/0x2d27182206f0442885989626934ca9dd5290f979) |
36+
| Sepolia | 11155111 | [0xaea9288f0b7a8c605c4d474c56e5e74f96bfd4b3](https://sepolia.etherscan.io/address/0xaea9288f0b7a8c605c4d474c56e5e74f96bfd4b3) |
37+
38+
39+
2840
## Deploying
2941

3042
Each contract has it's own deployment file in the form of `script/deploy/{Contract}.s.sol`. Inside each, there is a `Deploy{Contract}` script that will deploy the contract. This allows for programmatic cross-chain deployment of contracts using `script/deploy.sh`.
@@ -44,7 +56,7 @@ Contract verification will be automatically applied during deployment. However,
4456
For example, to verify both the proxy and implementation contract of SuccinctGateway (both of which have no `constructor_args`) on Chains 5, 420, 84531, and 421613, you would run:
4557

4658
```sh
47-
./script/verify.sh "SuccinctGateway" "5 420 84531 421613" "true"
59+
./script/verify.sh "SuccinctGateway" "5 420 84531 421613" "true"
4860
```
4961

5062
## Upgrading
@@ -59,7 +71,7 @@ Timelocked upgrades take place in two parts (`schedule` and then `execute` after
5971

6072
#### Step 1: Deploy a new implementation contract
6173

62-
Re-deploy the new contract via `script/deploy.sh`. This will generate a new `*_IMPL` implementation contract address with the current contract code.
74+
Re-deploy the new contract via `script/deploy.sh`. This will generate a new `*_IMPL` implementation contract address with the current contract code.
6375

6476
#### Step 2: Schedule the upgrade
6577

0 commit comments

Comments
 (0)