Skip to content

Commit a72c450

Browse files
committed
chore: beta contracts upgraded
1 parent 1d2e62a commit a72c450

17 files changed

+966
-603
lines changed

contracts/README.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -12,19 +12,19 @@ Refresh the list of deployed contracts by running `./scripts/generateDeployments
1212

1313
- [BlockHashRNG](https://arbiscan.io/address/0x39D123fc4cFD24EA5bB76195f9ecFE1f0DF35b0B)
1414
- [ChainlinkRNG](https://arbiscan.io/address/0x897d83a7d5F23555eFA15e1BE297d5503522cbA3)
15-
- [DisputeKitClassicNeo: proxy](https://arbiscan.io/address/0x70B464be85A547144C72485eBa2577E5D3A45421), [implementation](https://arbiscan.io/address/0xAF0325dbBFa812a574743Bb5A085266D31e3e03a)
15+
- [DisputeKitClassicNeo: proxy](https://arbiscan.io/address/0x70B464be85A547144C72485eBa2577E5D3A45421), [implementation](https://arbiscan.io/address/0x7F3C3C9f9c6238885d958afa1bCc92f1032ef81d)
1616
- [DisputeResolverNeo](https://arbiscan.io/address/0xb5526D022962A1fFf6eD32C93e8b714c901F4323)
1717
- [DisputeResolverRulerNeo](https://arbiscan.io/address/0xb3a5FdEAF461c42caCe148e978e6FBCa97bE6140)
1818
- [DisputeTemplateRegistry: proxy](https://arbiscan.io/address/0x0cFBaCA5C72e7Ca5fFABE768E135654fB3F2a5A2), [implementation](https://arbiscan.io/address/0x57EfD43DAfCeb6C58Df57932b2B299f46fef5c87)
19-
- [EvidenceModule: proxy](https://arbiscan.io/address/0x48e052B4A6dC4F30e90930F1CeaAFd83b3981EB3), [implementation](https://arbiscan.io/address/0xE22500Fa27f696d06702367246bd17Bd2C8a4c5d)
20-
- [KlerosCoreNeo: proxy](https://arbiscan.io/address/0x991d2df165670b9cac3B022f4B68D65b664222ea), [implementation](https://arbiscan.io/address/0x17c39AB53A7072b167A74a85D47b30385c98ae89)
19+
- [EvidenceModule: proxy](https://arbiscan.io/address/0x48e052B4A6dC4F30e90930F1CeaAFd83b3981EB3), [implementation](https://arbiscan.io/address/0xA502A3942abCF8e71FBD87ed442B39b798b192C8)
20+
- [KlerosCoreNeo: proxy](https://arbiscan.io/address/0x991d2df165670b9cac3B022f4B68D65b664222ea), [implementation](https://arbiscan.io/address/0xEb6D9E61921506f876dc662B2398E34C92330faB)
2121
- [KlerosCoreRulerNeo: proxy](https://arbiscan.io/address/0xc0169e0B19aE02ac4fADD689260CF038726DFE13), [implementation](https://arbiscan.io/address/0x85093b5EDa4F2e2E2fEDae34Da91239D6a08e324)
2222
- [KlerosCoreSnapshotProxy](https://arbiscan.io/address/0xEF719a5B3352F607e6C4E17b7e0cDAd8322fEC95)
2323
- [KlerosV2NeoEarlyUser](https://arbiscan.io/address/0xfE34a72c55e512601E7d491A9c5b36373cE34d63)
2424
- [Pinakion](https://arbiscan.io/address/0x330bD769382cFc6d50175903434CCC8D206DCAE5)
25-
- [PolicyRegistry: proxy](https://arbiscan.io/address/0x553dcbF6aB3aE06a1064b5200Df1B5A9fB403d3c), [implementation](https://arbiscan.io/address/0x15E5964C7751dF8563eA4bC000301582C79BC454)
25+
- [PolicyRegistry: proxy](https://arbiscan.io/address/0x553dcbF6aB3aE06a1064b5200Df1B5A9fB403d3c), [implementation](https://arbiscan.io/address/0xf7EE0Cd4E33C832DC05fB359896Add6E14E96C28)
2626
- [RandomizerRNG: proxy](https://arbiscan.io/address/0x044AfE0069C0fd641BC5f90d9A4218eF0b2Fa9d3), [implementation](https://arbiscan.io/address/0xF1a7Cd3115F5852966430f8E3877D2221F074A2e)
27-
- [SortitionModuleNeo: proxy](https://arbiscan.io/address/0x21A9402aDb818744B296e1d1BE58C804118DC03D), [implementation](https://arbiscan.io/address/0x7E13f295536FD6c48Ba792CFdEF691d592Fa0851)
27+
- [SortitionModuleNeo: proxy](https://arbiscan.io/address/0x21A9402aDb818744B296e1d1BE58C804118DC03D), [implementation](https://arbiscan.io/address/0x0cB3626Edf41F27a192102630D0502cCd93Cf043)
2828
- [TransactionBatcher](https://arbiscan.io/address/0xBC5ef8d9ad307154447AE148c088f083d2dEa4eF)
2929

3030
### Official Testnet

contracts/deploy/upgrade-all.ts

+37-9
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { DeployFunction } from "hardhat-deploy/types";
33
import { prompt, print } from "gluegun";
44
import { deployUpgradable } from "./utils/deployUpgradable";
55
import { HomeChains, isSkipped } from "./utils";
6-
import { getContractNamesFromNetwork } from "../scripts/utils/contracts";
6+
import { getContractNames, getContractNamesFromNetwork } from "../scripts/utils/contracts";
77

88
const { bold } = print.colors;
99

@@ -21,7 +21,23 @@ const deployUpgradeAll: DeployFunction = async (hre: HardhatRuntimeEnvironment)
2121
const upgrade = async (contractName: string, initializer: string, args: any[]) => {
2222
try {
2323
print.highlight(`🔍 Validating upgrade of ${bold(contractName)}`);
24-
await hre.run("compare-storage", { contract: contractName });
24+
25+
const contractNameWithoutNeo = contractName.replace(/Neo.*$/, "");
26+
let compareStorageOptions = { contract: contractName } as any;
27+
if (hre.network.name === "arbitrum") {
28+
switch (contractName) {
29+
case "KlerosCoreNeo":
30+
case "SortitionModuleNeo":
31+
compareStorageOptions = { deployedArtifact: `${contractName}_Implementation`, contract: contractName };
32+
break;
33+
default:
34+
compareStorageOptions = {
35+
deployedArtifact: `${contractName}_Implementation`,
36+
contract: contractNameWithoutNeo,
37+
};
38+
}
39+
}
40+
await hre.run("compare-storage", compareStorageOptions);
2541
print.newline();
2642
print.highlight(`💣 Upgrading ${bold(contractName)}`);
2743
const { confirm } = await prompt.ask({
@@ -35,13 +51,25 @@ const deployUpgradeAll: DeployFunction = async (hre: HardhatRuntimeEnvironment)
3551
}
3652
print.info(`Upgrading ${contractName}...`);
3753

38-
await deployUpgradable(deployments, contractName, {
39-
newImplementation: contractName,
40-
initializer,
41-
from: deployer,
42-
args, // Warning: do not reinitialize existing state variables, only the new ones
43-
});
44-
54+
switch (contractName) {
55+
case "DisputeKitClassicNeo":
56+
case "DisputeResolverNeo":
57+
await deployUpgradable(deployments, contractName, {
58+
contract: contractName,
59+
newImplementation: contractNameWithoutNeo,
60+
initializer,
61+
from: deployer,
62+
args, // Warning: do not reinitialize existing state variables, only the new ones
63+
});
64+
break;
65+
default:
66+
await deployUpgradable(deployments, contractName, {
67+
newImplementation: contractName,
68+
initializer,
69+
from: deployer,
70+
args, // Warning: do not reinitialize existing state variables, only the new ones
71+
});
72+
}
4573
print.info(`Verifying ${contractName} on Etherscan...`);
4674
await hre.run("etherscan-verify", { contractName: `${contractName}_Implementation` });
4775
} catch (err) {

contracts/deploy/upgrade-dispute-kit-v0.9.3.ts

-52
This file was deleted.

contracts/deploy/upgrade-kleros-core-v0.9.3.ts

-52
This file was deleted.

contracts/deploy/upgrade-sortition-module-v0.8.0.ts

-52
This file was deleted.

0 commit comments

Comments
 (0)