-
Notifications
You must be signed in to change notification settings - Fork 107
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
Contracts V2 #1300
Open
vgeddes
wants to merge
38
commits into
v2
Choose a base branch
from
vincent/v2
base: v2
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Contracts V2 #1300
Changes from all commits
Commits
Show all changes
38 commits
Select commit
Hold shift + click to select a range
e0b2371
v2 initial commit
vgeddes a7ad609
latest changes
vgeddes 1be9e5c
Flesh out dispatch logic for inbound messages
vgeddes e7fecaf
Add reward address
vgeddes 08715b0
make code compile
vgeddes 111f738
Split initializer impl into a library to reduce contract size
vgeddes b0867e8
Major refactor
vgeddes ee37e3c
Update tests
vgeddes 6829f38
add scripts back
vgeddes 8c878ce
Update scripts
vgeddes 0b25864
Merge branch 'v2' into vincent/v2
vgeddes c35743d
Finish outbound messaging
vgeddes 149c3e4
Implement token registration for V2
vgeddes 02ac263
Make functions payable
vgeddes c7332c3
improve docs
vgeddes c0bab8a
comments
vgeddes eae219e
review feedback
vgeddes 318b7dc
cleanups
vgeddes e73125d
Add initial tests for V2
vgeddes fa9b8a7
Make `rewardAddress` an indexed event parameter
vgeddes 00016a7
Clean up interfaces
vgeddes 5817542
Make WETH address configurable
vgeddes 4c3b2af
Autowrap ether
vgeddes 98b7d51
auto-unwrap ether
vgeddes 553b0b9
Add view keyword
yrong 3a7f56c
improve
vgeddes dabecbf
improve
vgeddes 8a1e688
allow unlocking native ether
vgeddes 75ad3f5
improve token registration flows
vgeddes 6bac207
improve docs
vgeddes 7b28a11
improve
vgeddes 7378735
improve
vgeddes 4e17456
nit
vgeddes fc48f45
Update contracts/src/v1/Calls.sol
vgeddes e35cd91
Apply suggestions from code review
vgeddes 55e6cab
Fix unlock WETH
yrong 005da17
Suppress Error (6243): The "tload" instruction
yrong d77abee
Merge recent changes
yrong File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,7 +12,7 @@ coverage/ | |
out/ | ||
cache/ | ||
broadcast/ | ||
types/ | ||
/types/ | ||
tsconfig.tsbuildinfo | ||
lcov.info | ||
tenderly.yaml | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-FileCopyrightText: 2023 Snowfork <[email protected]> | ||
pragma solidity 0.8.25; | ||
pragma solidity 0.8.28; | ||
|
||
import {Script} from "forge-std/Script.sol"; | ||
import {GatewayProxy} from "../src/GatewayProxy.sol"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-FileCopyrightText: 2023 Snowfork <[email protected]> | ||
pragma solidity 0.8.25; | ||
pragma solidity 0.8.28; | ||
|
||
import {Script} from "forge-std/Script.sol"; | ||
import {BeefyClient} from "../src/BeefyClient.sol"; | ||
|
@@ -18,7 +18,7 @@ contract DeployBeefyClient is Script { | |
function readConfig() internal pure returns (Config memory config) { | ||
// Checkpoint generated using the script `./beefy-checkpoint.js` script in Polkadot-JS. | ||
config = Config({ | ||
startBlock: 21087413, | ||
startBlock: 21_087_413, | ||
current: BeefyClient.ValidatorSet({ | ||
id: 644, | ||
length: 297, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,20 @@ | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-FileCopyrightText: 2023 Snowfork <[email protected]> | ||
pragma solidity 0.8.25; | ||
pragma solidity 0.8.28; | ||
|
||
import {WETH9} from "canonical-weth/WETH9.sol"; | ||
import {Script} from "forge-std/Script.sol"; | ||
import {BeefyClient} from "../src/BeefyClient.sol"; | ||
|
||
import {IGateway} from "../src/interfaces/IGateway.sol"; | ||
import {IGatewayV2} from "../src/v2/IGateway.sol"; | ||
import {GatewayProxy} from "../src/GatewayProxy.sol"; | ||
import {Gateway} from "../src/Gateway.sol"; | ||
import {MockGatewayV2} from "../test/mocks/MockGatewayV2.sol"; | ||
import {Agent} from "../src/Agent.sol"; | ||
import {AgentExecutor} from "../src/AgentExecutor.sol"; | ||
import {Constants} from "../src/Constants.sol"; | ||
import {ChannelID, ParaID, OperatingMode} from "../src/Types.sol"; | ||
import {Initializer} from "../src/Initializer.sol"; | ||
import {SafeNativeTransfer} from "../src/utils/SafeTransfer.sol"; | ||
import {stdJson} from "forge-std/StdJson.sol"; | ||
import {UD60x18, ud60x18} from "prb/math/src/UD60x18.sol"; | ||
|
@@ -49,26 +51,15 @@ contract DeployLocal is Script { | |
uint256 randaoCommitDelay = vm.envUint("RANDAO_COMMIT_DELAY"); | ||
uint256 randaoCommitExpiration = vm.envUint("RANDAO_COMMIT_EXP"); | ||
uint256 minimumSignatures = vm.envUint("MINIMUM_REQUIRED_SIGNATURES"); | ||
BeefyClient beefyClient = | ||
new BeefyClient(randaoCommitDelay, randaoCommitExpiration, minimumSignatures, startBlock, current, next); | ||
|
||
ParaID bridgeHubParaID = ParaID.wrap(uint32(vm.envUint("BRIDGE_HUB_PARAID"))); | ||
bytes32 bridgeHubAgentID = vm.envBytes32("BRIDGE_HUB_AGENT_ID"); | ||
ParaID assetHubParaID = ParaID.wrap(uint32(vm.envUint("ASSET_HUB_PARAID"))); | ||
bytes32 assetHubAgentID = vm.envBytes32("ASSET_HUB_AGENT_ID"); | ||
BeefyClient beefyClient = new BeefyClient( | ||
randaoCommitDelay, randaoCommitExpiration, minimumSignatures, startBlock, current, next | ||
); | ||
|
||
uint8 foreignTokenDecimals = uint8(vm.envUint("FOREIGN_TOKEN_DECIMALS")); | ||
uint128 maxDestinationFee = uint128(vm.envUint("RESERVE_TRANSFER_MAX_DESTINATION_FEE")); | ||
|
||
AgentExecutor executor = new AgentExecutor(); | ||
Gateway gatewayLogic = new Gateway( | ||
address(beefyClient), | ||
address(executor), | ||
bridgeHubParaID, | ||
bridgeHubAgentID, | ||
foreignTokenDecimals, | ||
maxDestinationFee | ||
); | ||
Gateway gatewayLogic = new Gateway(address(beefyClient), address(executor)); | ||
|
||
bool rejectOutboundMessages = vm.envBool("REJECT_OUTBOUND_MESSAGES"); | ||
OperatingMode defaultOperatingMode; | ||
|
@@ -78,30 +69,32 @@ contract DeployLocal is Script { | |
defaultOperatingMode = OperatingMode.Normal; | ||
} | ||
|
||
Gateway.Config memory config = Gateway.Config({ | ||
// Deploy WETH for testing | ||
address weth = address(new WETH9()); | ||
|
||
Initializer.Config memory config = Initializer.Config({ | ||
mode: defaultOperatingMode, | ||
deliveryCost: uint128(vm.envUint("DELIVERY_COST")), | ||
registerTokenFee: uint128(vm.envUint("REGISTER_TOKEN_FEE")), | ||
assetHubParaID: assetHubParaID, | ||
assetHubAgentID: assetHubAgentID, | ||
assetHubCreateAssetFee: uint128(vm.envUint("CREATE_ASSET_FEE")), | ||
assetHubReserveTransferFee: uint128(vm.envUint("RESERVE_TRANSFER_FEE")), | ||
exchangeRate: ud60x18(vm.envUint("EXCHANGE_RATE")), | ||
multiplier: ud60x18(vm.envUint("FEE_MULTIPLIER")), | ||
rescueOperator: address(0) | ||
rescueOperator: address(0), | ||
foreignTokenDecimals: foreignTokenDecimals, | ||
maxDestinationFee: maxDestinationFee, | ||
weth: weth | ||
}); | ||
|
||
GatewayProxy gateway = new GatewayProxy(address(gatewayLogic), abi.encode(config)); | ||
|
||
// Deploy WETH for testing | ||
new WETH9(); | ||
|
||
// Fund the sovereign account for the BridgeHub parachain. Used to reward relayers | ||
// of messages originating from BridgeHub | ||
uint256 initialDeposit = vm.envUint("BRIDGE_HUB_INITIAL_DEPOSIT"); | ||
|
||
address bridgeHubAgent = IGateway(address(gateway)).agentOf(bridgeHubAgentID); | ||
address assetHubAgent = IGateway(address(gateway)).agentOf(assetHubAgentID); | ||
address bridgeHubAgent = | ||
IGatewayV2(address(gateway)).agentOf(Constants.BRIDGE_HUB_AGENT_ID); | ||
address assetHubAgent = IGatewayV2(address(gateway)).agentOf(Constants.ASSET_HUB_AGENT_ID); | ||
|
||
payable(bridgeHubAgent).safeNativeTransfer(initialDeposit); | ||
payable(assetHubAgent).safeNativeTransfer(initialDeposit); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-FileCopyrightText: 2023 Snowfork <[email protected]> | ||
pragma solidity 0.8.25; | ||
pragma solidity 0.8.28; | ||
|
||
import {AgentExecutor} from "../src/AgentExecutor.sol"; | ||
import {Gateway} from "../src//Gateway.sol"; | ||
|
@@ -20,22 +20,9 @@ contract DeployLocalGatewayLogic is Script { | |
|
||
address beefyClient = vm.envAddress("BEEFY_CLIENT_CONTRACT_ADDRESS"); | ||
|
||
ParaID bridgeHubParaID = ParaID.wrap(uint32(vm.envUint("BRIDGE_HUB_PARAID"))); | ||
bytes32 bridgeHubAgentID = vm.envBytes32("BRIDGE_HUB_AGENT_ID"); | ||
|
||
uint8 foreignTokenDecimals = uint8(vm.envUint("FOREIGN_TOKEN_DECIMALS")); | ||
uint128 maxDestinationFee = uint128(vm.envUint("RESERVE_TRANSFER_MAX_DESTINATION_FEE")); | ||
|
||
AgentExecutor executor = new AgentExecutor(); | ||
|
||
new Gateway( | ||
address(beefyClient), | ||
address(executor), | ||
bridgeHubParaID, | ||
bridgeHubAgentID, | ||
foreignTokenDecimals, | ||
maxDestinationFee | ||
); | ||
new Gateway(address(beefyClient), address(executor)); | ||
|
||
vm.stopBroadcast(); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,11 @@ | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-FileCopyrightText: 2023 Snowfork <[email protected]> | ||
pragma solidity 0.8.25; | ||
pragma solidity 0.8.28; | ||
|
||
import {WETH9} from "canonical-weth/WETH9.sol"; | ||
import {Script} from "forge-std/Script.sol"; | ||
import {BeefyClient} from "../src/BeefyClient.sol"; | ||
|
||
import {IGateway} from "../src/interfaces/IGateway.sol"; | ||
import {IGatewayV2} from "../src/v2/IGateway.sol"; | ||
import {GatewayProxy} from "../src/GatewayProxy.sol"; | ||
import {Gateway} from "../src/Gateway.sol"; | ||
import {Agent} from "../src/Agent.sol"; | ||
|
@@ -32,8 +31,8 @@ contract FundAgent is Script { | |
bytes32 bridgeHubAgentID = vm.envBytes32("BRIDGE_HUB_AGENT_ID"); | ||
bytes32 assetHubAgentID = vm.envBytes32("ASSET_HUB_AGENT_ID"); | ||
|
||
address bridgeHubAgent = IGateway(gatewayAddress).agentOf(bridgeHubAgentID); | ||
address assetHubAgent = IGateway(gatewayAddress).agentOf(assetHubAgentID); | ||
address bridgeHubAgent = IGatewayV2(gatewayAddress).agentOf(bridgeHubAgentID); | ||
address assetHubAgent = IGatewayV2(gatewayAddress).agentOf(assetHubAgentID); | ||
|
||
payable(bridgeHubAgent).safeNativeTransfer(initialDeposit); | ||
payable(assetHubAgent).safeNativeTransfer(initialDeposit); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-FileCopyrightText: 2023 Snowfork <[email protected]> | ||
pragma solidity 0.8.25; | ||
pragma solidity 0.8.28; | ||
|
||
import {WETH9} from "canonical-weth/WETH9.sol"; | ||
import {Script} from "forge-std/Script.sol"; | ||
import {BeefyClient} from "../src/BeefyClient.sol"; | ||
|
||
import {IGateway} from "../src/interfaces/IGateway.sol"; | ||
import {IShell} from "../src/interfaces/IShell.sol"; | ||
import {GatewayProxy} from "../src/GatewayProxy.sol"; | ||
import {Gateway} from "../src/Gateway.sol"; | ||
import {MockGatewayV2} from "../test/mocks/MockGatewayV2.sol"; | ||
import {Initializer} from "../src/Initializer.sol"; | ||
import {Agent} from "../src/Agent.sol"; | ||
import {AgentExecutor} from "../src/AgentExecutor.sol"; | ||
import {ChannelID, ParaID, OperatingMode} from "../src/Types.sol"; | ||
|
@@ -36,9 +36,7 @@ contract UpgradeShell is Script { | |
address beefyClient; | ||
ParaID bridgeHubParaID; | ||
bytes32 bridgeHubAgentID; | ||
uint8 foreignTokenDecimals; | ||
uint128 maxDestinationFee; | ||
Gateway.Config initializerParams; | ||
Initializer.Config initializerParams; | ||
} | ||
|
||
function readConfig() internal pure returns (Config memory config) { | ||
|
@@ -47,19 +45,18 @@ contract UpgradeShell is Script { | |
beefyClient: 0x6eD05bAa904df3DE117EcFa638d4CB84e1B8A00C, | ||
bridgeHubParaID: ParaID.wrap(1002), | ||
bridgeHubAgentID: 0x03170a2e7597b7b7e3d84c05391d139a62b157e78786d8c082f29dcf4c111314, | ||
foreignTokenDecimals: 10, | ||
maxDestinationFee: dot(2), | ||
initializerParams: Gateway.Config({ | ||
initializerParams: Initializer.Config({ | ||
mode: OperatingMode.Normal, | ||
deliveryCost: mDot(100), // 0.1 DOT | ||
registerTokenFee: 0.002 ether, | ||
assetHubParaID: ParaID.wrap(1000), | ||
assetHubAgentID: 0x81c5ab2571199e3188135178f3c2c8e2d268be1313d029b30f534fa579b69b79, | ||
assetHubCreateAssetFee: mDot(100), // 0.1 DOT | ||
assetHubReserveTransferFee: mDot(100), // 0.1 DOT | ||
exchangeRate: ud60x18(0.0024e18), | ||
multiplier: ud60x18(1.33e18), | ||
rescueOperator: 0x4B8a782D4F03ffcB7CE1e95C5cfe5BFCb2C8e967 | ||
rescueOperator: 0x4B8a782D4F03ffcB7CE1e95C5cfe5BFCb2C8e967, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Probably don't need this anymore, since we have already dropped the operator on mainnet? |
||
foreignTokenDecimals: 10, | ||
maxDestinationFee: dot(2), | ||
weth: 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2 | ||
}) | ||
}); | ||
} | ||
|
@@ -73,18 +70,15 @@ contract UpgradeShell is Script { | |
AgentExecutor executor = new AgentExecutor(); | ||
|
||
// Gateway implementation | ||
Gateway gatewayLogic = new Gateway( | ||
config.beefyClient, | ||
address(executor), | ||
config.bridgeHubParaID, | ||
config.bridgeHubAgentID, | ||
config.foreignTokenDecimals, | ||
config.maxDestinationFee | ||
); | ||
Gateway gatewayLogic = new Gateway(config.beefyClient, address(executor)); | ||
|
||
IShell shell = IShell(config.gatewayProxy); | ||
|
||
shell.upgrade(address(gatewayLogic), address(gatewayLogic).codehash, abi.encode(config.initializerParams)); | ||
shell.upgrade( | ||
address(gatewayLogic), | ||
address(gatewayLogic).codehash, | ||
abi.encode(config.initializerParams) | ||
); | ||
|
||
vm.stopBroadcast(); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-FileCopyrightText: 2023 Snowfork <[email protected]> | ||
pragma solidity 0.8.25; | ||
pragma solidity 0.8.28; | ||
|
||
import {WETH9} from "canonical-weth/WETH9.sol"; | ||
import {Script} from "forge-std/Script.sol"; | ||
import {stdJson} from "forge-std/StdJson.sol"; | ||
import {UD60x18, ud60x18} from "prb/math/src/UD60x18.sol"; | ||
|
||
import {BeefyClient} from "../../src/BeefyClient.sol"; | ||
import {IGateway} from "../../src/interfaces/IGateway.sol"; | ||
import {IShell} from "../../src/interfaces/IShell.sol"; | ||
import {GatewayProxy} from "../../src/GatewayProxy.sol"; | ||
import {Gateway} from "../../src/Gateway.sol"; | ||
import {MockGatewayV2} from "../../test/mocks/MockGatewayV2.sol"; | ||
import {Initializer} from "../../src/Initializer.sol"; | ||
import {Agent} from "../../src/Agent.sol"; | ||
import {AgentExecutor} from "../../src/AgentExecutor.sol"; | ||
import {ChannelID, ParaID, OperatingMode} from "../../src/Types.sol"; | ||
|
@@ -25,32 +25,25 @@ contract UpgradeShell is Script { | |
struct Config { | ||
address gatewayProxy; | ||
address beefyClient; | ||
ParaID bridgeHubParaID; | ||
bytes32 bridgeHubAgentID; | ||
uint8 foreignTokenDecimals; | ||
uint128 maxDestinationFee; | ||
Gateway.Config initializerParams; | ||
Initializer.Config initializerParams; | ||
} | ||
|
||
function readConfig() internal pure returns (Config memory config) { | ||
config = Config({ | ||
gatewayProxy: 0x9Ed8b47Bc3417e3BD0507ADC06E56e2Fa360A4E9, | ||
beefyClient: 0x6DFaD3D73A28c48E4F4c616ECda80885b415283a, | ||
bridgeHubParaID: ParaID.wrap(1002), | ||
bridgeHubAgentID: 0x03170a2e7597b7b7e3d84c05391d139a62b157e78786d8c082f29dcf4c111314, | ||
foreignTokenDecimals: 12, | ||
maxDestinationFee: 2000000000000, | ||
initializerParams: Gateway.Config({ | ||
initializerParams: Initializer.Config({ | ||
mode: OperatingMode.Normal, | ||
deliveryCost: 200000000000, // 0.2 Wnd | ||
deliveryCost: 200_000_000_000, // 0.2 Wnd | ||
registerTokenFee: 0.002 ether, | ||
assetHubParaID: ParaID.wrap(1000), | ||
assetHubAgentID: 0x81c5ab2571199e3188135178f3c2c8e2d268be1313d029b30f534fa579b69b79, | ||
assetHubCreateAssetFee: 200000000000, // 0.2 Wnd | ||
assetHubReserveTransferFee: 200000000000, // 0.2 Wnd | ||
exchangeRate: ud60x18(2400000000000000), | ||
multiplier: ud60x18(1330000000000000000), | ||
rescueOperator: 0x302F0B71B8aD3CF6dD90aDb668E49b2168d652fd | ||
assetHubCreateAssetFee: 200_000_000_000, // 0.2 Wnd | ||
assetHubReserveTransferFee: 200_000_000_000, // 0.2 Wnd | ||
exchangeRate: ud60x18(2_400_000_000_000_000), | ||
multiplier: ud60x18(1_330_000_000_000_000_000), | ||
rescueOperator: 0x302F0B71B8aD3CF6dD90aDb668E49b2168d652fd, | ||
foreignTokenDecimals: 12, | ||
maxDestinationFee: 2_000_000_000_000, | ||
weth: 0x7b79995e5f793A07Bc00c21412e50Ecae098E7f9 | ||
}) | ||
}); | ||
} | ||
|
@@ -64,18 +57,15 @@ contract UpgradeShell is Script { | |
AgentExecutor executor = new AgentExecutor(); | ||
|
||
// Gateway implementation | ||
Gateway gatewayLogic = new Gateway( | ||
config.beefyClient, | ||
address(executor), | ||
config.bridgeHubParaID, | ||
config.bridgeHubAgentID, | ||
config.foreignTokenDecimals, | ||
config.maxDestinationFee | ||
); | ||
Gateway gatewayLogic = new Gateway(config.beefyClient, address(executor)); | ||
|
||
IShell shell = IShell(config.gatewayProxy); | ||
|
||
shell.upgrade(address(gatewayLogic), address(gatewayLogic).codehash, abi.encode(config.initializerParams)); | ||
shell.upgrade( | ||
address(gatewayLogic), | ||
address(gatewayLogic).codehash, | ||
abi.encode(config.initializerParams) | ||
); | ||
|
||
vm.stopBroadcast(); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-FileCopyrightText: 2023 Snowfork <[email protected]> | ||
pragma solidity 0.8.25; | ||
pragma solidity 0.8.28; | ||
|
||
/// @title An agent contract that acts on behalf of a consensus system on Polkadot | ||
/// @dev Instances of this contract act as an agents for arbitrary consensus systems on Polkadot. These consensus systems | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make weth first item.
Commit:
e1a8578