Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: deployments #602

Open
wants to merge 35 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
0e98585
feat: oz votes trace 208 voting strategy
May 1, 2024
69c45dc
chore: comments
May 1, 2024
4e74ff9
chore: protocol deployer script
Nov 20, 2023
5613f7d
chore: yarn script
Nov 20, 2023
0eab3b3
chore: starknet goerli deployment
Nov 20, 2023
f71908c
chore: add space class hash to goerli deployment
Nov 23, 2023
355ceb0
chore: mainnet deployments
Nov 23, 2023
9f3193a
chore: added class hashes to goerli deployment
Nov 23, 2023
dbfbb45
chore: eth tx deployment with starknet commit
Nov 23, 2023
5865c29
chore: add optimizations to sol code
Nov 23, 2023
2060a10
chore: starknet commit deployer script via create3
Nov 23, 2023
1a0a621
chore: fix deployment params
Nov 27, 2023
b6803ef
chore: vanilla voting to deployment script
Nov 30, 2023
b2a802b
chore: added vanilla voting strategy to deployments json
Nov 30, 2023
593a444
chore: added json formatter to scripts
Nov 30, 2023
11ed828
chore: added evm slot value strategy to deployer script
Dec 5, 2023
1c43df4
chore: goerli evm slot value deployment
Dec 5, 2023
42639ed
chore: camel case for deployment args
Dec 5, 2023
62fea91
chore: sepolia deployment and update others
Dec 21, 2023
36847d0
chore: updated deployer script
Jan 8, 2024
ed7e34e
chore: sepolia evmSlotValueVotingStrategy deployment
Jan 8, 2024
fe39837
chore: updated env example
Jan 8, 2024
acc569f
chore: mainnet evmSlotValueVotingStrategy deployment
Jan 9, 2024
39d615c
chore: formatting
Jan 9, 2024
21f8597
chore: fix sepolia factory deployment
Jan 9, 2024
3068232
chore: goerli and mainnet deployment of OZ Votes strategy
Jan 25, 2024
c70422c
chore: updated herodotus interaction demo
Jan 25, 2024
3b5f7de
chore: sepolia Oz votes strategy
Jan 29, 2024
42d3661
chore: re-add evm slot proof strategy to deployments jsons
Jan 29, 2024
9cc0355
chore: added timelock to deployer script
Feb 14, 2024
a5eaeaf
chore: timelock goerli deployment
Feb 14, 2024
abb4894
chore: timelock sepolia deployment
Feb 14, 2024
65f4c0d
chore: timelock mainnet deployment
Feb 14, 2024
b4561b4
chore: trace 208 OZ votes strat and latest herodotus deployments
May 1, 2024
3ab4649
chore: update deployer script
May 8, 2024
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
6 changes: 6 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,9 @@ PK=
STARKNET_SIERRA_COMPILE_PATH=
# Needed for Devnet Postman Endpoint to work
OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES
HERODOTUS_API_KEY=

# DEPLOYMENT ADDRESSES - Update to the deployments on the relevant network when deploying
STARKNET_COMMIT_ADDRESS=
FACTS_REGISTRY_ADDRESS=
TIMESTAMP_REMAPPERS_ADDRESS=
83 changes: 83 additions & 0 deletions deployments/goerli.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
{
"erc20VotesVotingStrategy": {
"address": "0x30258c0b5832763b16f4e5d2ddbf97b3d61b8ff3368a3e3f112533b8549dd29",
"classHash": "0x073d2613af4c68f4cffeedd5ed07610a5fd5bb560606a51f034af9aac65fb86c"
},
"ethRelayerExecutionStrategy": {
"address": "0xa0a4bcf464e29f46dfb103521f33807271b4300ac5cd3118b15f31f89ecd94",
"classHash": "0x01cbb577fa06b452701a62c7428ed72dcaf0e7d67375e436aad6b3789001a687"
},
"timeLockExecutionStrategy": {
"classHash": "0x070cea434b3bdcf9f74f0bf25007e16806ceb8e5dbbcace68033f2a9302dc200"
},
"ethSigAuthenticator": {
"address": "0x048b33fe56e9b9354d4278ffdd5f6d546b13aa3d8c33149db2e2e2fdb48a369e",
"classHash": "0x07c2680d397168aec487597e9ac5283a426f783210a0f1d88c17a53a99a46327"
},
"ethTxAuthenticator": {
"address": "0xd6f14d3df9ea2db12ed9572ab41d527f18dd24192e1744d3c100b2cd470812",
"classHash": "0x02e25598c32a13ee7aa5f807aa7e36aba1fe623b4c02d87f1d403287903438f4",
"params": {
"starknetCommitAddress": "0x8bF85537c80beCbA711447f66A9a4452e3575E29"
}
},
"OZVotesStorageProofVotingStrategy": {
"address": "0x1b3cbb267de6d0f30ddf521cd385a2e11836f0c5ba6f7b2224cf77a6ed86acf",
"classHash": "0x017f352f6e4e3e1c15a43b85bb36851a877419f3e0a9a27ef6048538eded8f9f",
"params": {
"factsRegistry": "0x01b2111317eb693c3ee46633edd45a4876db14a3a53acdbf4e5166976d8e869d",
"timestampRemapper": "0x2ee57d848297bc7dfc8675111b9aa3bd3085e4038e475250770afe303b772af"
}
},
"evmSlotValueVotingStrategy": {
"address": "0x035dbd4e4f46a059557e1b299d17f4568b49488bad5da9a003b171d90052139e",
"classHash": "0x0153ce0a7fed79b6a655eac427ed420f01ccca7fc44c09dc6e6c5c1b7a0d32fe",
"params": {
"factsRegistry": "0x01b2111317eb693c3ee46633edd45a4876db14a3a53acdbf4e5166976d8e869d",
"timestampRemapper": "0x2ee57d848297bc7dfc8675111b9aa3bd3085e4038e475250770afe303b772af"
}
},
"factory": {
"address": "0x63c62258e1ba4d9ad72eab809ea5c3d1a4545b721bc444d6068ced6246c2f3c",
"classHash": "0x031288bda2c55c988f582a3c8cd81798bc936081f592c66c5084c25fb2fb3d3b"
},
"merkleWhitelistVotingStrategy": {
"address": "0xe3ca14dcb7862116bbbe4331a9927c6693b141aa8936bb76e2bdfa4b551a52",
"classHash": "0x013d1b3a970113cbf7027ecfd117e2805deddcc588e1ad064e5272533da27f27"
},
"noExecutionSimpleMajorityExecutionStrategy": {
"address": "0x4a5658d6b9fe62283147719a8b13d72f96e8959afacc716569b936c91089147",
"classHash": "0x012b2958bc28e88c6474599ed4efdd859196c4abf48cac33679a4dd7e908c272"
},
"propositionPowerProposalValidationStrategy": {
"address": "0x3ff398ab4e0aa9109c0cc889ff968c6215053a5e2176519b59f8ba87927c631",
"classHash": "0x032880a1385677b921be41172ef3308335c7e2c63d14cc7d6c9c6496d3c651de"
},
"space": {
"classHash": "0x04b61126a7def0956cb4ff342ba72d850ea6b78b0ddb3e0b45f3a99bc9eb5995"
},
"starkSigAuthenticator": {
"address": "0x5280813396bf63dd47531ccdbfa5887099d44421d3f62db3de8f7bed68794f5",
"classHash": "0x06cd9cbb9ec3d8b9b65bfe957ec5a8554baeadb931e9b73dfbd9cdecc7268c8e",
"params": {
"name": "sx-starknet",
"version": "0.1.0"
}
},
"starkTxAuthenticator": {
"address": "0x573a7fc4d8dd3a860b376741c251772cd4d15508dd94564ff23a645d28042d",
"classHash": "0x0074bed8a722e660589c8caa9409aec16497ea270104c8b3b4763f173e4bdf23"
},
"vanillaAuthenticator": {
"address": "0x046ad946f22ac4e14e271f24309f14ac36f0fde92c6831a605813fefa46e0893",
"classHash": "0x07b14f6390f7f386d28190ae21c4b30812fbc11f47d6786994879c39b16995ad"
},
"vanillaProposalValidationStrategy": {
"address": "0x2247f5d86a60833da9dd8224d8f35c60bde7f4ca3b2a6583d4918d48750f69",
"classHash": "0x0156a0db2f92fe7d0850f7487c040a3bce3e1ce7bc6f630f5f6cd194956b4828"
},
"vanillaVotingStrategy": {
"address": "0x066b87187b3c079f443fa39b169a43b0832aee3ab49699fa0652572d3d21820b",
"classHash": "0x00995129dccbef6bf6d8ee3c6dbd0ce51ac6d9cda038da661b27a6b015c570f8"
}
}
83 changes: 83 additions & 0 deletions deployments/mainnet.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
{
"erc20VotesVotingStrategy": {
"address": "0x02429becc80a90bbeb38c6566617c584f79c60f684e8e73313af58b109b7d637",
"classHash": "0x073d2613af4c68f4cffeedd5ed07610a5fd5bb560606a51f034af9aac65fb86c"
},
"ethRelayerExecutionStrategy": {
"address": "0x041c679daa4de984c72e2671405294b6064da964d1cee9db2fb26ba974f99fed",
"classHash": "0x01cbb577fa06b452701a62c7428ed72dcaf0e7d67375e436aad6b3789001a687"
},
"timeLockExecutionStrategy": {
"classHash": "0x070cea434b3bdcf9f74f0bf25007e16806ceb8e5dbbcace68033f2a9302dc200"
},
"ethSigAuthenticator": {
"address": "0x00b610082a0f39458e03a96663767ec25d6fb259f32c1e0dd19bf2be7a52532c",
"classHash": "0x07c2680d397168aec487597e9ac5283a426f783210a0f1d88c17a53a99a46327"
},
"ethTxAuthenticator": {
"address": "0x063c89d1c6b938b68e88db2719cf2546a121c23642974c268515238b442b0ea0",
"classHash": "0x02e25598c32a13ee7aa5f807aa7e36aba1fe623b4c02d87f1d403287903438f4",
"params": {
"starknetCommitAddress": "0xF1EC7b0276aA5aF11eceFE56efb0F198A77016E9"
}
},
"OZVotesStorageProofVotingStrategy": {
"address": "0x7ee3cf64f1072fe21570356eb57d4e9f78169ea9235ba610f60a8b33c36cc6e",
"classHash": "0x017f352f6e4e3e1c15a43b85bb36851a877419f3e0a9a27ef6048538eded8f9f",
"params": {
"factsRegistry": "0x014bf62fadb41d8f899bb5afeeb2da486fcfd8431852def56c5f10e45ae72765",
"timestampRemapper": "0x0050e1a1a352049b29103d8b42cf00f6faa2d5e88e94ed71962a1bfb24e5b0b2"
}
},
"evmSlotValueVotingStrategy": {
"address": "0x699e53f4b40e19d96b8020386dbeeb156f40172d7bbb78b2a4204cf64ae75f",
"classHash": "0x0153ce0a7fed79b6a655eac427ed420f01ccca7fc44c09dc6e6c5c1b7a0d32fe",
"params": {
"factsRegistry": "0x014bf62fadb41d8f899bb5afeeb2da486fcfd8431852def56c5f10e45ae72765",
"timestampRemapper": "0x0050e1a1a352049b29103d8b42cf00f6faa2d5e88e94ed71962a1bfb24e5b0b2"
}
},
"factory": {
"address": "0x0250e28c97e729842190c3672f9fcf8db0fc78b8080e87a894831dc69e4f4439",
"classHash": "0x031288bda2c55c988f582a3c8cd81798bc936081f592c66c5084c25fb2fb3d3b"
},
"merkleWhitelistVotingStrategy": {
"address": "0x0528b83a6af52c56cb2134fd9190a441e930831af437c1cb0fa6e459ad1435ba",
"classHash": "0x013d1b3a970113cbf7027ecfd117e2805deddcc588e1ad064e5272533da27f27"
},
"noExecutionSimpleMajorityExecutionStrategy": {
"address": "0x0477fadae876724682a6b0716a01ad5564f106b85bc373067e7c6975e9db9c26",
"classHash": "0x012b2958bc28e88c6474599ed4efdd859196c4abf48cac33679a4dd7e908c272"
},
"propositionPowerProposalValidationStrategy": {
"address": "0x01b28f95cbc5bcbe52014ef974d609f14497517f31d3c9e079a2464edf988751",
"classHash": "0x032880a1385677b921be41172ef3308335c7e2c63d14cc7d6c9c6496d3c651de"
},
"space": {
"classHash": "0x04b61126a7def0956cb4ff342ba72d850ea6b78b0ddb3e0b45f3a99bc9eb5995"
},
"starkSigAuthenticator": {
"address": "0x06e9de29d8c3551e7f845888f323e864ff214359b56a137633bf7e191035b442",
"classHash": "0x06cd9cbb9ec3d8b9b65bfe957ec5a8554baeadb931e9b73dfbd9cdecc7268c8e",
"params": {
"name": "sx-starknet",
"version": "0.1.0"
}
},
"starkTxAuthenticator": {
"address": "0x0687b57bc5459d05d9575483be8ed8e623c379484fdb1aad18b073ffd4602099",
"classHash": "0x0074bed8a722e660589c8caa9409aec16497ea270104c8b3b4763f173e4bdf23"
},
"vanillaAuthenticator": {
"address": "0x00c4b0a7d8626638e7dd410b16ccbc48fe36e68f864dec75b23ef41e3732d5d2",
"classHash": "0x07b14f6390f7f386d28190ae21c4b30812fbc11f47d6786994879c39b16995ad"
},
"vanillaProposalValidationStrategy": {
"address": "0x054883d24fe788f72181101372a2fc171bc73152c399f195fdcabc94e743dcf3",
"classHash": "0x0156a0db2f92fe7d0850f7487c040a3bce3e1ce7bc6f630f5f6cd194956b4828"
},
"vanillaVotingStrategy": {
"address": "0x0790772fb61f58630d5418016aea41a64a45b4ffc39a9adf66e6446fdc0e8088",
"classHash": "0x00995129dccbef6bf6d8ee3c6dbd0ce51ac6d9cda038da661b27a6b015c570f8"
}
}
91 changes: 91 additions & 0 deletions deployments/sepolia.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
{
"erc20VotesVotingStrategy": {
"address": "0x72067addfebbaf2d20ed07303a2c9b8e19154e8797e6e9d6819b37fea2a2963",
"classHash": "0x073d2613af4c68f4cffeedd5ed07610a5fd5bb560606a51f034af9aac65fb86c"
},
"ethRelayerExecutionStrategy": {
"address": "0x72a0e53450c9c297225042d26b05ad62bf417c33ea30775e663538c0a29143a",
"classHash": "0x01cbb577fa06b452701a62c7428ed72dcaf0e7d67375e436aad6b3789001a687"
},
"timeLockExecutionStrategy": {
"classHash": "0x070cea434b3bdcf9f74f0bf25007e16806ceb8e5dbbcace68033f2a9302dc200"
},
"ethSigAuthenticator": {
"address": "0x053d98050a9738da0eac7498d909ea03f6eb03d07fb95877b54ff8acf7712276",
"classHash": "0x07c2680d397168aec487597e9ac5283a426f783210a0f1d88c17a53a99a46327"
},
"ethTxAuthenticator": {
"address": "0x47ee3743ce7ad0ffcdb1ba51c9730a77cafd0ca51539714e711258f86c9f8af",
"classHash": "0x02e25598c32a13ee7aa5f807aa7e36aba1fe623b4c02d87f1d403287903438f4",
"params": {
"starknetCommitAddress": "0xf1ec7b0276aa5af11ecefe56efb0f198a77016e9"
}
},
"evmSlotValueVotingStrategy": {
"address": "0x1f8544918b5d9b4833fb2ba2d0c7ceb0d699ae7f2b8b23ea129c9a10fe8046c",
"classHash": "0x0153ce0a7fed79b6a655eac427ed420f01ccca7fc44c09dc6e6c5c1b7a0d32fe",
"params": {
"factsRegistry": "0x07d3550237ecf2d6ddef9b78e59b38647ee511467fe000ce276f245a006b40bc",
"timestampRemapper": "0x00cdd51fbc4e008f4ef807eaf26f5043521ef5931bbb1e04032a25bd845d286b"
}
},
"OZVotesStorageProofVotingStrategy": {
"address": "0xfefaf2dd8aa036a9142d07468414d66da9a22fdaa77c9885bccd3ce8c2f535",
"classHash": "0x17f352f6e4e3e1c15a43b85bb36851a877419f3e0a9a27ef6048538eded8f9f",
"params": {
"factsRegistry": "0x008ec19768587f3d7362d83b644253de560c9d46eda096619df5942d56079abb",
"timestampRemapper": "0x00cdd51fbc4e008f4ef807eaf26f5043521ef5931bbb1e04032a25bd845d286b"
}
},
"OZVotesTrace208StorageProofVotingStrategy": {
"address": "0xa5cf9a95d2e164ab7807654b9810eb8f15a394f2a9077b3a8fc392bbfc305c",
"classHash": "0x045d9774a3de7a9506d7cfa256584a9feee96a3243388de4d5bb31a5c70f5125",
"params": {
"factsRegistry": "0x008ec19768587f3d7362d83b644253de560c9d46eda096619df5942d56079abb",
"timestampRemapper": "0x00cdd51fbc4e008f4ef807eaf26f5043521ef5931bbb1e04032a25bd845d286b"
}
},
"factory": {
"address": "0x63c62258e1ba4d9ad72eab809ea5c3d1a4545b721bc444d6068ced6246c2f3c",
"classHash": "0x0302d332e9aceb184e5f301cb62c85181e7fc3b30559935c5736e987de579f6e"
},
"merkleWhitelistVotingStrategy": {
"address": "0x13bcbe7318fb8aa219d264dcf5916feb873e596389ba93d923f9a23378cb743",
"classHash": "0x013d1b3a970113cbf7027ecfd117e2805deddcc588e1ad064e5272533da27f27"
},
"noExecutionSimpleMajorityExecutionStrategy": {
"address": "0x5327bdc6522d531b7770cd51aa641fb91c280a30cdece29edbf9edd970167f6",
"classHash": "0x012b2958bc28e88c6474599ed4efdd859196c4abf48cac33679a4dd7e908c272"
},
"propositionPowerProposalValidationStrategy": {
"address": "0x296e1a5ad28c9bf32b9570d6e1bedae77917866cd5d92aea4ef9271905ef549",
"classHash": "0x032880a1385677b921be41172ef3308335c7e2c63d14cc7d6c9c6496d3c651de"
},
"space": {
"classHash": "0x04b61126a7def0956cb4ff342ba72d850ea6b78b0ddb3e0b45f3a99bc9eb5995"
},
"starkSigAuthenticator": {
"address": "0x213bb25044b189ccfda9882999dba32e011781dc11b2a6efa2b3d232824378e",
"classHash": "0x06cd9cbb9ec3d8b9b65bfe957ec5a8554baeadb931e9b73dfbd9cdecc7268c8e",
"params": {
"name": "sx-starknet",
"version": "0.1.0"
}
},
"starkTxAuthenticator": {
"address": "0x2b63a8a92b7c67484ab99c4307c7db41b15b9a3c33359cd2b2459fd7f543a9c",
"classHash": "0x0074bed8a722e660589c8caa9409aec16497ea270104c8b3b4763f173e4bdf23"
},
"vanillaAuthenticator": {
"address": "0x051a4a1eb5ce28fc95edf408a847efccfb030d27314d9fbe82d82cb998ec1a0b",
"classHash": "0x07b14f6390f7f386d28190ae21c4b30812fbc11f47d6786994879c39b16995ad"
},
"vanillaProposalValidationStrategy": {
"address": "0x4cf6363ce975ef50ed813113432d3118957db79881d0c2e822aa72067b3f1ff",
"classHash": "0x0156a0db2f92fe7d0850f7487c040a3bce3e1ce7bc6f630f5f6cd194956b4828"
},
"vanillaVotingStrategy": {
"address": "0x1b8abdeb07c4f96c5e44229626d4b2f3673c7a1364b7208329c983bfc9fd69f",
"classHash": "0x00995129dccbef6bf6d8ee3c6dbd0ce51ac6d9cda038da661b27a6b015c570f8"
}
}
2 changes: 2 additions & 0 deletions ethereum/foundry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
src = 'src'
out = 'out'
libs = ['lib']
optimizer = true
optimizer_runs = 10_000
solc = "0.8.19"

# See more config options https://github.com/foundry-rs/foundry/tree/master/config
28 changes: 28 additions & 0 deletions ethereum/script/deployer.s.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.19;

import "forge-std/Script.sol";
import "../src/StarknetCommit.sol";

address constant STARKNET_CORE_CONTRACT_MAINNET = address(0xc662c410C0ECf747543f5bA90660f6ABeBD9C8c4);
address constant STARKNET_COMMIT_CONTRACT_GOERLI = address(0xde29d060D45901Fb19ED6C6e959EB22d8626708e);
address constant STARKNET_COMMIT_CONTRACT_SEPOLIA = address(0xE2Bb56ee936fd6433DC0F6e7e3b8365C906AA057);

interface ICREATE3Factory {
function deploy(bytes32 salt, bytes memory bytecode) external returns (address deployedAddress);
}

contract Deployer is Script {
function run() external {
address deployer = vm.envAddress("DEPLOYER_ADDRESS");
vm.startBroadcast(deployer);
bytes32 salt = bytes32(uint256(2));

// Using the CREATE3 factory maintained by lififinance: https://github.com/lifinance/create3-factory
ICREATE3Factory(0x93FEC2C00BfE902F733B57c5a6CeeD7CD1384AE1).deploy(
salt, abi.encodePacked(type(StarknetCommit).creationCode, abi.encode(STARKNET_COMMIT_CONTRACT_SEPOLIA))
);

vm.stopBroadcast();
}
}
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,16 @@
"main": "index.js",
"scripts": {
"format:ts": "eslint . --ext .ts --fix",
"format:json": "json-format ./tests/data/*.json",
"format:json": "json-format ./deployments/*.json",
"test:sig-auths": "jest -c jest.config.ts --runInBand",
"chain:l1": "hardhat node",
"chain:l2": "bash './scripts/chain-l2.sh'",
"chain": "yarn chain:l1 & yarn chain:l2",
"test:stark-sig-auth": "bash './scripts/stark-sig-auth-test.sh'",
"test:eth-sig-auth": "bash './scripts/eth-sig-auth-test.sh'",
"test:eth-tx-auth": "bash './scripts/eth-tx-auth-test.sh'",
"test:l1-execution": "bash './scripts/l1-avatar-execution-test.sh'"
"test:l1-execution": "bash './scripts/l1-avatar-execution-test.sh'",
"deploy-protocol": "yarn ts-node ./scripts/deploy-protocol.ts"
},
"devDependencies": {
"@gnosis.pm/safe-contracts": "^1.3.0",
Expand Down Expand Up @@ -44,6 +45,7 @@
"eslint": "^8.46.0",
"eslint-plugin-prettier": "^5.0.0",
"ethereum-waffle": "^4.0.10",
"ethers": "^6.8.1",
"fs": "^0.0.1-security",
"hardhat": "^2.17.2",
"hardhat-gas-reporter": "^1.0.9",
Expand Down
Loading
Loading