|
| 1 | +## Clean up of the old artifacts |
| 2 | + |
| 3 | +The following contracts have been preserved: |
| 4 | + |
| 5 | +- The University contracts (out-of-scope for now) |
| 6 | +- The ERC20 tokens and their faucets (unchanged): PinakionV2, PNK, PNKFaucet, DAI, DAIFaucet, WETH, WETHFaucet |
| 7 | +- The RNG contracts (unchanged): RandomizerOracle, BlockHashRNG, ChainlinkRNG, ChainlinkVRFCoordinator (mock) |
| 8 | +- KlerosV2NeoEarlyUser (unchanged, for Neo devnet) |
| 9 | + |
| 10 | +```shell |
| 11 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitClassic.json |
| 12 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitClassic_Implementation.json |
| 13 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitClassic_Proxy.json |
| 14 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitGated_Implementation.json |
| 15 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitGated_Proxy.json |
| 16 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitGated.json |
| 17 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter_Implementation.json |
| 18 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter_Proxy.json |
| 19 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter.json |
| 20 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitShutter.json |
| 21 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitShutter_Implementation.json |
| 22 | +rm deployments/arbitrumSepoliaDevnet/DisputeKitShutter_Proxy.json |
| 23 | +rm deployments/arbitrumSepoliaDevnet/DisputeResolver.json |
| 24 | +rm deployments/arbitrumSepoliaDevnet/DisputeResolverRuler.json |
| 25 | +rm deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry.json |
| 26 | +rm deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry_Implementation.json |
| 27 | +rm deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry_Proxy.json |
| 28 | +rm deployments/arbitrumSepoliaDevnet/EvidenceModule.json |
| 29 | +rm deployments/arbitrumSepoliaDevnet/EvidenceModule_Implementation.json |
| 30 | +rm deployments/arbitrumSepoliaDevnet/EvidenceModule_Proxy.json |
| 31 | +rm deployments/arbitrumSepoliaDevnet/KlerosCore.json |
| 32 | +rm deployments/arbitrumSepoliaDevnet/KlerosCoreRuler.json |
| 33 | +rm deployments/arbitrumSepoliaDevnet/KlerosCoreRuler_Implementation.json |
| 34 | +rm deployments/arbitrumSepoliaDevnet/KlerosCoreRuler_Proxy.json |
| 35 | +rm deployments/arbitrumSepoliaDevnet/KlerosCoreSnapshotProxy.json |
| 36 | +rm deployments/arbitrumSepoliaDevnet/KlerosCore_Implementation.json |
| 37 | +rm deployments/arbitrumSepoliaDevnet/KlerosCore_Proxy.json |
| 38 | +rm deployments/arbitrumSepoliaDevnet/PolicyRegistry.json |
| 39 | +rm deployments/arbitrumSepoliaDevnet/PolicyRegistry_Implementation.json |
| 40 | +rm deployments/arbitrumSepoliaDevnet/PolicyRegistry_Proxy.json |
| 41 | +rm deployments/arbitrumSepoliaDevnet/SortitionModule.json |
| 42 | +rm deployments/arbitrumSepoliaDevnet/SortitionModule_Implementation.json |
| 43 | +rm deployments/arbitrumSepoliaDevnet/SortitionModule_Proxy.json |
| 44 | +``` |
| 45 | + |
| 46 | +## Contracts Deployment - DRY RUN |
| 47 | + |
| 48 | +Shell 1: fork node |
| 49 | + |
| 50 | +```shell |
| 51 | +anvil --fork-url https://sepolia-rollup.arbitrum.io/rpc |
| 52 | +``` |
| 53 | + |
| 54 | +Shell 2: deployer |
| 55 | + |
| 56 | +```shell |
| 57 | +export ARBITRUM_SEPOLIA_RPC=http://127.0.0.1:8545 |
| 58 | + |
| 59 | +yarn clean |
| 60 | +yarn deploy --network arbitrumSepoliaDevnet --tags Resolver |
| 61 | +yarn deploy --network arbitrumSepoliaDevnet --tags ArbitrationRuler |
| 62 | + |
| 63 | +unset ARBITRUM_SEPOLIA_RPC |
| 64 | +``` |
| 65 | + |
| 66 | +:warning: Remember to delete all the deployed artifacts after each dry run. |
| 67 | + |
| 68 | +## Contracts Deployment - LIVE |
| 69 | + |
| 70 | +```shell |
| 71 | +yarn clean |
| 72 | +yarn deploy --network arbitrumSepoliaDevnet --tags Resolver |
| 73 | +yarn deploy --network arbitrumSepoliaDevnet --tags ArbitrationRuler |
| 74 | + |
| 75 | +# Contracts verification, marking proxies |
| 76 | +yarn etherscan-verify --network arbitrumSepoliaDevnet |
| 77 | +yarn etherscan-verify-proxies |
| 78 | + |
| 79 | +# Docs update |
| 80 | +./scripts/populateReadme.sh |
| 81 | +``` |
| 82 | + |
| 83 | +## Courts structure and policies configuration |
| 84 | + |
| 85 | +```shell |
| 86 | +yarn hardhat populate:courts --from v2_devnet --network arbitrumSepoliaDevnet |
| 87 | + |
| 88 | +yarn hardhat populate:policy-registry --from v2_devnet --network arbitrumSepoliaDevnet |
| 89 | +``` |
| 90 | + |
| 91 | +## Contracts SDK |
| 92 | + |
| 93 | +### Refresh the artifacts |
| 94 | + |
| 95 | +```shell |
| 96 | +# Viem artifacts |
| 97 | +yarn viem:generate-devnet |
| 98 | + |
| 99 | +# Hardhat artifacts |
| 100 | +yarn export:devnet |
| 101 | +``` |
| 102 | + |
| 103 | +### Update the contract helpers |
| 104 | + |
| 105 | +If there are new or removed contracts, edit the contract helpers in: |
| 106 | + |
| 107 | +- `scripts/utils/contracts.ts` (Hardhat runtime) |
| 108 | +- `deployments/contractsEthers.ts` (pure EthersJS) |
| 109 | +- `deployments/contractsViem.ts` (pure Viem) |
0 commit comments