Skip to content
Merged
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
118 changes: 117 additions & 1 deletion .github/workflows/deploy-contracts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,10 @@ jobs:
echo "Resolved $SCRIPT_NAME to ${matches[0]}"

- name: Build scripts
run: forge build ./script --via-ir
run: forge build ./script --via-ir --build-info

- name: Run deployment script
id: deployment
shell: bash
env:
BROADCAST: ${{ inputs.broadcast }}
Expand All @@ -123,12 +124,17 @@ jobs:
SCRIPT_FILE: ${{ steps.script.outputs.file }}
run: |
set -euo pipefail
broadcast_marker=""
if [[ "$BROADCAST" == "true" ]]; then
broadcast_marker="$(mktemp)"
fi

forge_args=(
--target-contract "$SCRIPT_NAME"
--private-key "$DEPLOYER_PRIVATE_KEY"
--sender "$DEPLOYER_ADDRESS"
--non-interactive
--build-info
-vvv
)

Expand All @@ -142,6 +148,116 @@ jobs:

forge script "${forge_args[@]}" "$SCRIPT_FILE"

hook_build_id="$(jq -r '
.files["src/initializers/DopplerHookInitializer.sol"].artifacts.DopplerHookInitializer
| [.. | objects | .build_id? // empty]
| unique
| if length == 1 then .[0] else empty end
' cache/solidity-files-cache.json)"
if [[ -z "$hook_build_id" ]]; then
echo "::error::Could not identify the DopplerHookInitializer compiler build."
exit 1
fi
echo "doppler_hook_build_id=$hook_build_id" >> "$GITHUB_OUTPUT"

if [[ "$BROADCAST" == "true" ]]; then
script_file_name="${SCRIPT_FILE##*/}"
run_files=()
shopt -s nullglob
for run_file in "broadcast/$script_file_name"/*/run-latest.json; do
if [[ "$run_file" -nt "$broadcast_marker" ]]; then
run_files+=("$run_file")
fi
done
rm -f "$broadcast_marker"

if [[ "${#run_files[@]}" -ne 1 ]]; then
echo "::error::Expected one updated broadcast artifact for $script_file_name, found ${#run_files[@]}."
exit 1
fi

chain_id="$(jq -r '.chain // empty' "${run_files[0]}")"
if [[ ! "$chain_id" =~ ^[0-9]+$ ]]; then
echo "::error::Could not infer a numeric chain ID from ${run_files[0]}."
exit 1
fi
echo "chain_id=$chain_id" >> "$GITHUB_OUTPUT"

if jq -e 'any(.transactions[]?; .contractName == "DopplerHookInitializer" or any(.additionalContracts[]?; .contractName == "DopplerHookInitializer"))' "${run_files[0]}" > /dev/null; then
echo "doppler_hook_initializer_deployed=true" >> "$GITHUB_OUTPUT"
else
echo "doppler_hook_initializer_deployed=false" >> "$GITHUB_OUTPUT"
fi
fi

- name: Install Bun dependencies
if: ${{ inputs.broadcast && steps.deployment.outputs.doppler_hook_initializer_deployed == 'true' }}
run: bun install --frozen-lockfile

- name: Verify DopplerHookInitializer
if: ${{ inputs.broadcast && steps.deployment.outputs.doppler_hook_initializer_deployed == 'true' }}
shell: bash
env:
CHAIN_ID: ${{ steps.deployment.outputs.chain_id }}
ETHERSCAN_API_KEY: ${{ secrets.ETHERSCAN_API_KEY }}
DOPPLER_HOOK_BUILD_ID: ${{ steps.deployment.outputs.doppler_hook_build_id }}
run: |
set -euo pipefail

if [[ ! "$CHAIN_ID" =~ ^[0-9]+$ ]]; then
echo "::error::chain_id must be a numeric chain ID."
exit 1
fi

bun scripts/VerifyDopplerHookInitializer.ts "$CHAIN_ID"

- name: Verify deployment contracts
if: ${{ inputs.broadcast }}
shell: bash
env:
DEPLOYER_ADDRESS: ${{ steps.deployer.outputs.address }}
DEPLOYER_PRIVATE_KEY: ${{ secrets.DEPLOYER_PRIVATE_KEY }}
ETHERSCAN_API_KEY: ${{ secrets.ETHERSCAN_API_KEY }}
ETH_MAINNET_RPC_URL: ${{ secrets.ETH_MAINNET_RPC_URL }}
ETH_SEPOLIA_RPC_URL: ${{ secrets.ETH_SEPOLIA_RPC_URL }}
MONAD_MAINNET_RPC_URL: ${{ secrets.MONAD_MAINNET_RPC_URL }}
MONAD_TESTNET_RPC_URL: ${{ secrets.MONAD_TESTNET_RPC_URL }}
BASE_MAINNET_RPC_URL: ${{ secrets.BASE_MAINNET_RPC_URL }}
ARBITRUM_MAINNET_RPC_URL: ${{ secrets.ARBITRUM_MAINNET_RPC_URL }}
BASE_SEPOLIA_RPC_URL: ${{ secrets.BASE_SEPOLIA_RPC_URL }}
UNICHAIN_MAINNET_RPC_URL: ${{ secrets.UNICHAIN_MAINNET_RPC_URL }}
UNICHAIN_SEPOLIA_RPC_URL: ${{ secrets.UNICHAIN_SEPOLIA_RPC_URL }}
MEGAETH_MAINNET_RPC_URL: ${{ secrets.MEGAETH_MAINNET_RPC_URL }}
MEGAETH_TESTNET_RPC_URL: ${{ secrets.MEGAETH_TESTNET_RPC_URL }}
RPC_URL: ${{ inputs.rpc_url }}
SCRIPT_NAME: ${{ inputs.script_name }}
SCRIPT_FILE: ${{ steps.script.outputs.file }}
run: |
set -euo pipefail

forge_args=(
--target-contract "$SCRIPT_NAME"
--private-key "$DEPLOYER_PRIVATE_KEY"
--sender "$DEPLOYER_ADDRESS"
--non-interactive
--resume
--build-info
--verify
-vvv
)

if [[ -z "${ETHERSCAN_API_KEY:-}" ]]; then
echo "::error::ETHERSCAN_API_KEY secret is required for broadcast verification."
exit 1
fi
forge_args+=(--verifier etherscan --etherscan-api-key "$ETHERSCAN_API_KEY")

if [[ -n "$RPC_URL" ]]; then
forge_args+=(--rpc-url "$RPC_URL")
fi

forge script "${forge_args[@]}" "$SCRIPT_FILE"

- name: Generate deployment history
if: ${{ inputs.broadcast }}
run: |
Expand Down
26 changes: 25 additions & 1 deletion Deployments.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,31 @@
"UniswapV4Initializer": "0x53b4c21a6cb61d64f636abbfa6e8e90e6558e8ad"
},
"42161": {
"DopplerCreateXDeployer": "0x103004e50bed65dfba30dd9c264b6bdf5e529b83"
"Airlock": "0xeb7c034704ef8dcd2d32324c1545f62fb4ad0862",
"Bundler": "0xf45588e8e0b1df9db9ae7e20ece5726ae931357c",
"DN404Factory": "0x37a9fa204a4d3a429fded7e3469ab076c854bc9d",
"DopplerCreateXDeployer": "0x103004e50bed65dfba30dd9c264b6bdf5e529b83",
"DopplerDeployer": "0x4389ad34938b14f25cff7ed983c53f5a42a2573f",
"DopplerERC20V1": "0x3be8b97fd0e713b5abe0649fa830223b6b4bc599",
"DopplerERC20V1Factory": "0x1b37d3a72082029c44b35b604ea473617580b69a",
"DopplerHookInitializer": "0xaa7f809bb3752f715fa2e418230667c382a56544",
"DopplerHookMigrator": "0x7bf319d8e969f7596b1bc171da9ce322f67ae0c4",
"DopplerLensQuoter": "0xf4c22465532f64777ffcd7770831aeca38f35c04",
"GovernanceFactory": "0xdeb0447dae3eb177c4dba8bbccca25c8f273b7ef",
"LaunchpadGovernanceFactory": "0xdb036746d65dd52126b1915f1adf555e6c5237cf",
"LockableUniswapV3Initializer": "0xde8886a0019ea060b8378ee37b8a23b8117f29a3",
"NoOpGovernanceFactory": "0x85f37f74ef2478a770318bc810177a9835911ad7",
"NoOpMigrator": "0xba2f330edb16cd8056f5988d8ce19bbc63475a0e",
"Quoter": "0xc9be59b344ec66547a4c697aa374e959d59b0567",
"RehypeDopplerHookInitializer": "0x5f9eb5f6726fe88d5e39867967f5b833d2fa3215",
"RehypeDopplerHookMigrator": "0x660740d7d6fb2c8998fa3fff459cceb9ac12c84b",
"StreamableFeesLockerV2": "0xed822828b6109d16a9d362b8146a35789e0064f5",
"SwapRestrictorDopplerHook": "0xc16c826f75338a5ea626f94f8992191b4ce5aba2",
"TimelockFactory": "0x6076fddfcac0dd980e0350dff5239fec3f86c578",
"TopUpDistributor": "0x46adee7595d48b1ec53090e9bc78e1e69fa0ef06",
"UniswapV2Locker": "0x63f6efe03f25a8c6650b38d05c5a454051d642a5",
"UniswapV2MigratorSplit": "0xb05046cea797c993fb5b583098b1c4682e9da333",
"UniswapV4Initializer": "0x6cce158b6d1747617fc218592b4d60b239b957ea"
},
"84532": {
"Airlock": "0x3411306ce66c9469bff1535ba955503c4bde1c6e",
Expand Down
24 changes: 24 additions & 0 deletions Deployments.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,31 @@ If there are contracts not reflected here but claiming to be instances of Dopple
### Arbitrum One (42161)
| Contract | Address | Transaction | Commit |
|---|---|---|---|
| Airlock | [0xeb7c...0862](https://arbiscan.io/address/0xeb7c034704ef8dcd2d32324c1545f62fb4ad0862) | [0x5310...e4e8](https://arbiscan.io/tx/0x5310d839481c40bb4b0ee1ddf355d442b971d18d1c40d060a104ab180328e4e8) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| Bundler | [0xf455...357c](https://arbiscan.io/address/0xf45588e8e0b1df9db9ae7e20ece5726ae931357c) | [0x4fb7...cd5c](https://arbiscan.io/tx/0x4fb707960c109ca32039bb78a0489bb360cfa6b720d3e2bb426342a0a092cd5c) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| DN404Factory | [0x37a9...bc9d](https://arbiscan.io/address/0x37a9fa204a4d3a429fded7e3469ab076c854bc9d) | [0x2f3d...502f](https://arbiscan.io/tx/0x2f3d7fc73196c7458511cd9317594f1fd14bcd62846a1fa02d92f747f159502f) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| DopplerCreateXDeployer | [0x1030...9b83](https://arbiscan.io/address/0x103004e50bed65dfba30dd9c264b6bdf5e529b83) | [0x3cd3...4ef2](https://arbiscan.io/tx/0x3cd33b3df9036733fd32eb60182cd9afd8adcddcb581fb6ea097d632fff34ef2) | [d7e35957](https://github.com/whetstoneresearch/doppler/commit/d7e35957) |
| DopplerDeployer | [0x4389...573f](https://arbiscan.io/address/0x4389ad34938b14f25cff7ed983c53f5a42a2573f) | [0x986b...4aaf](https://arbiscan.io/tx/0x986b70205ce1bd063c3a22b0f64a3258a347c9f72370f5366f5bd2b5d0b74aaf) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| DopplerERC20V1 | [0x3be8...c599](https://arbiscan.io/address/0x3be8b97fd0e713b5abe0649fa830223b6b4bc599) | [0xd543...b5e5](https://arbiscan.io/tx/0xd54318a31703125c5d2b7c2bfe12cbbbb509b41ad13a875e31c9b14914a3b5e5) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| DopplerERC20V1Factory | [0x1b37...b69a](https://arbiscan.io/address/0x1b37d3a72082029c44b35b604ea473617580b69a) | [0xd543...b5e5](https://arbiscan.io/tx/0xd54318a31703125c5d2b7c2bfe12cbbbb509b41ad13a875e31c9b14914a3b5e5) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| DopplerHookInitializer | [0xaa7f...6544](https://arbiscan.io/address/0xaa7f809bb3752f715fa2e418230667c382a56544) | [0xef7e...f82f](https://arbiscan.io/tx/0xef7e94b99692faee0c2e45494e77c6ea4b177b98298e378402a0787259baf82f) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| DopplerHookMigrator | [0x7bf3...e0c4](https://arbiscan.io/address/0x7bf319d8e969f7596b1bc171da9ce322f67ae0c4) | [0xb6d5...4b3d](https://arbiscan.io/tx/0xb6d5ec95acf21522cedd1428089896da22f2192e3a37ddea09780b6b71ee4b3d) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| DopplerLensQuoter | [0xf4c2...5c04](https://arbiscan.io/address/0xf4c22465532f64777ffcd7770831aeca38f35c04) | [0xe9d7...0b99](https://arbiscan.io/tx/0xe9d741158c1466e911b512b89a116be6dc8addfc3ab099b72abd6649313c0b99) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| GovernanceFactory | [0xdeb0...b7ef](https://arbiscan.io/address/0xdeb0447dae3eb177c4dba8bbccca25c8f273b7ef) | [0x1986...56ff](https://arbiscan.io/tx/0x1986fdb47670fb30e4c5eaabf51db7efbfbf353daf61f6a79a9ba5091db256ff) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| LaunchpadGovernanceFactory | [0xdb03...37cf](https://arbiscan.io/address/0xdb036746d65dd52126b1915f1adf555e6c5237cf) | [0xeba6...958e](https://arbiscan.io/tx/0xeba6f7aeee36ab65f2fe85fd9d6b2847efb801c0d6a03667618a24186df1958e) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| LockableUniswapV3Initializer | [0xde88...29a3](https://arbiscan.io/address/0xde8886a0019ea060b8378ee37b8a23b8117f29a3) | [0xcc0e...0d7c](https://arbiscan.io/tx/0xcc0e82494b6d0aa65e7b360b8547b0224b44b800f85c3a2fc5bebb0c71ca0d7c) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| NoOpGovernanceFactory | [0x85f3...1ad7](https://arbiscan.io/address/0x85f37f74ef2478a770318bc810177a9835911ad7) | [0x4a84...5a21](https://arbiscan.io/tx/0x4a844936e30f18fe69acba8fabcecbdc0e1a9ba77a52039a17e11d3e42b75a21) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| NoOpMigrator | [0xba2f...5a0e](https://arbiscan.io/address/0xba2f330edb16cd8056f5988d8ce19bbc63475a0e) | [0xb2dd...ca70](https://arbiscan.io/tx/0xb2dde36b3fc885f1fdf9c1d7161bc3b98f85edfcc51df88c55ef2b29e44cca70) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| Quoter | [0xc9be...0567](https://arbiscan.io/address/0xc9be59b344ec66547a4c697aa374e959d59b0567) | [0x6bb6...7de1](https://arbiscan.io/tx/0x6bb6d2edc08cff62a25856cb60cb63c3a65e20812981b51cf9770cad25d97de1) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| RehypeDopplerHookInitializer | [0x5f9e...3215](https://arbiscan.io/address/0x5f9eb5f6726fe88d5e39867967f5b833d2fa3215) | [0xc17a...8201](https://arbiscan.io/tx/0xc17af5adf9ea4ee8dd9871435d358b251f5eb0e82298eccd9c646759cc628201) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| RehypeDopplerHookMigrator | [0x6607...c84b](https://arbiscan.io/address/0x660740d7d6fb2c8998fa3fff459cceb9ac12c84b) | [0x6bb6...7de1](https://arbiscan.io/tx/0x6bb6d2edc08cff62a25856cb60cb63c3a65e20812981b51cf9770cad25d97de1) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| StreamableFeesLockerV2 | [0xed82...64f5](https://arbiscan.io/address/0xed822828b6109d16a9d362b8146a35789e0064f5) | [0xd299...b90e](https://arbiscan.io/tx/0xd299c101a8e2b4c8fbe3f6dd880ab11a4cf98337cc806f22d979630e72c7b90e) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| SwapRestrictorDopplerHook | [0xc16c...aba2](https://arbiscan.io/address/0xc16c826f75338a5ea626f94f8992191b4ce5aba2) | [0x6dfe...9c91](https://arbiscan.io/tx/0x6dfe8643fc244e8f5f75563d201b71ab0dcec87047c86c8ebc46fafdcb669c91) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| TimelockFactory | [0x6076...c578](https://arbiscan.io/address/0x6076fddfcac0dd980e0350dff5239fec3f86c578) | [0x1986...56ff](https://arbiscan.io/tx/0x1986fdb47670fb30e4c5eaabf51db7efbfbf353daf61f6a79a9ba5091db256ff) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| TopUpDistributor | [0x46ad...ef06](https://arbiscan.io/address/0x46adee7595d48b1ec53090e9bc78e1e69fa0ef06) | [0x283e...1409](https://arbiscan.io/tx/0x283e6e57f825edb9eafbee8e3aaeed4a39b4824be1c8c04390bc03867bc11409) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| UniswapV2Locker | [0x63f6...42a5](https://arbiscan.io/address/0x63f6efe03f25a8c6650b38d05c5a454051d642a5) | [0xb072...2b89](https://arbiscan.io/tx/0xb07266bb98ee8b0a5d3910d734a1eb973561cd0159b8a82fbd8b676157a82b89) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| UniswapV2MigratorSplit | [0xb050...a333](https://arbiscan.io/address/0xb05046cea797c993fb5b583098b1c4682e9da333) | [0xb072...2b89](https://arbiscan.io/tx/0xb07266bb98ee8b0a5d3910d734a1eb973561cd0159b8a82fbd8b676157a82b89) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |
| UniswapV4Initializer | [0x6cce...57ea](https://arbiscan.io/address/0x6cce158b6d1747617fc218592b4d60b239b957ea) | [0x4d7f...91d8](https://arbiscan.io/tx/0x4d7f9bcff4624e9558f1ae65baa30d4022c34ec3305b6d74e18da4ff8ab291d8) | [8b1fe7b1](https://github.com/whetstoneresearch/doppler/commit/8b1fe7b1) |

## Testnet Deployments
### Base Sepolia (84532)
Expand Down
Loading