Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
// SPDX-License-Identifier: Apache-2.0
pragma solidity 0.8.16;

import {Script} from "forge-std/Script.sol";
import {console} from "forge-std/console.sol";

import {ProxyAdmin} from "@openzeppelin/contracts/proxy/transparent/ProxyAdmin.sol";

import {L2ArbitrumGovernor} from "src/L2ArbitrumGovernor.sol";
import {L2ArbitrumToken} from "src/L2ArbitrumToken.sol";
import {ActivateDvpQuorumAction} from "src/gov-action-contracts/AIPs/ActivateDvpQuorumAction.sol";

/// @notice Deploys the ActivateDvpQuorumAction contract with the appropriate parameters.
/// Uses CREATE2 for deterministic address and easy verification.
contract DeployActivateDvpQuorumUpgrade is Script{
function run() external {
vm.startBroadcast();

bytes32 salt = bytes32(uint256(1));

address l2GovernorImpl = address(new L2ArbitrumGovernor{salt: salt}());
address l2TokenImpl = address(new L2ArbitrumToken{salt: salt}());

ActivateDvpQuorumAction action = new ActivateDvpQuorumAction{salt: salt}({
_l2AddressRegistry: 0x56C4E9Eb6c63aCDD19AeC2b1a00e4f0d7aBda9d3,
_arbTokenProxy: 0x912CE59144191C1204E64559FE8253a0e49E6548,
_govProxyAdmin: ProxyAdmin(0xdb216562328215E010F819B5aBe947bad4ca961e),
_newGovernorImpl: l2GovernorImpl,
_newTokenImpl: l2TokenImpl,
_newCoreQuorumNumerator: 5000, // denominator is 10_000, so this is 50%
_coreMinimumQuorum: 150_000_000 ether,
_coreMaximumQuorum: 450_000_000 ether,
_newTreasuryQuorumNumerator: 4000, // 40%
_treasuryMinimumQuorum: 100_000_000 ether,
_treasuryMaximumQuorum: 300_000_000 ether,
_initialTotalDelegationEstimate: 5477825566840547165171692750 // include EXCLUDED tokens
});

console.log("ActivateDvpQuorumAction deployed at:", address(action));

vm.stopBroadcast();
}
}
10 changes: 10 additions & 0 deletions scripts/proposals/ActivateDvpQuorum/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Activate DVP Quorum Proposal Payload

Total DVP is calculated using this Dune Query: https://dune.com/queries/6707930

How to verify:

1. Read `DeployActivateDvpQuorumUpgrade.s.sol`
1. Run `DeployActivateDvpQuorumUpgrade.s.sol` with no rpc. Ensure the printed action address has code on arb1.
1. Read `generate.bash` and ensure that the printed action is included
1. Run `generate.bash` to regenerate `data.json`
6 changes: 4 additions & 2 deletions scripts/proposals/ActivateDvpQuorum/data.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
{
"actionChainIds": [
42161,
42161
],
"actionAddresses": [
"0x19C8Ea5F8288abF138D72a13344E699a7A71400c"
"0xbeA14C43EE8324B764D699B4E1B5dD9d1f1825c9",
"0x1D62fFeB72e4c360CcBbacf7c965153b00260417"
],
"arbSysSendTxToL1Args": {
"l1Timelock": "0xE6841D92B0C345144506576eC13ECf5103aC7f49",
"calldata": "0x8f2a0bb000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000000b7c5875f8d6dac043d4278efb5a58e9834260314ac17df813eaf54545f5a149f000000000000000000000000000000000000000000000000000000000003f4800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000a723c008e76e379c55599d2e4d93879beafda79c000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000001800000000000000000000000004dbd4fc535ac27206064b68ffcf827b0a60bab3f000000000000000000000000cf57572261c7c2bcf21ffd220ea7d1a27d40a82700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000841cff79cd00000000000000000000000019c8ea5f8288abf138d72a13344e699a7a71400c00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000004b147f40c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
"calldata": "0x8f2a0bb000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000018000000000000000000000000000000000000000000000000000000000000000005575a1202bdeb87fb924e3fd1901a3212c7fd42a35c39915ed94cec7697d6716000000000000000000000000000000000000000000000000000000000003f4800000000000000000000000000000000000000000000000000000000000000002000000000000000000000000a723c008e76e379c55599d2e4d93879beafda79c000000000000000000000000a723c008e76e379c55599d2e4d93879beafda79c0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000001e000000000000000000000000000000000000000000000000000000000000001800000000000000000000000004dbd4fc535ac27206064b68ffcf827b0a60bab3f000000000000000000000000cf57572261c7c2bcf21ffd220ea7d1a27d40a82700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000841cff79cd000000000000000000000000bea14c43ee8324b764d699b4e1b5dd9d1f1825c900000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000004b147f40c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000004dbd4fc535ac27206064b68ffcf827b0a60bab3f000000000000000000000000cf57572261c7c2bcf21ffd220ea7d1a27d40a82700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000a4bca8c7b50000000000000000000000001d62ffeb72e4c360ccbbacf7c965153b002604170000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000002437f66aa7263080bed3962d0476fa84fbb32ab81dfff1244e2b145f9864da24353b2f3b050000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
}
}
26 changes: 26 additions & 0 deletions scripts/proposals/ActivateDvpQuorum/generate.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/bin/bash

# todo: redeploy action contract with better estimate and replace address below

# constitution hash comes from: https://github.com/ArbitrumFoundation/docs/pull/1164/changes/001d57cfc17a2fd6c7f23a01ff99c351480c3e69

yarn gen:proposalData \
--govChainProviderRPC https://arb1.arbitrum.io/rpc \
--actionTypes \
0 \
1 \
--actionChainIds \
42161 \
42161 \
--actionAddresses \
0xbeA14C43EE8324B764D699B4E1B5dD9d1f1825c9 \
0x1D62fFeB72e4c360CcBbacf7c965153b00260417 \
--upgradeValues \
0 \
0 \
--upgradeDatas \
"$(cast sig "perform()")" \
"$(cast calldata "setConstitutionHash(bytes32)" 0x263080bed3962d0476fa84fbb32ab81dfff1244e2b145f9864da24353b2f3b05)" \
--predecessor \
0x0000000000000000000000000000000000000000000000000000000000000000 \
--writeToJsonPath ./scripts/proposals/ActivateDvpQuorum/data.json
Loading