Skip to content

Commit

Permalink
feat: Delete FPACOPS scripts
Browse files Browse the repository at this point in the history
This also allows us to delete several deployX() functions from
Deploy.s.sol
  • Loading branch information
maurelian committed Oct 2, 2024
1 parent ae9d1d6 commit d23d2bd
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 616 deletions.
87 changes: 0 additions & 87 deletions packages/contracts-bedrock/scripts/deploy/Deploy.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -610,33 +610,6 @@ contract Deploy is Deployer {
ChainAssertions.checkOptimismPortal({ _contracts: contracts, _cfg: cfg, _isProxy: false });
}

/// @notice Deploy the OptimismPortal2 (used in FPACOPS)
function deployOptimismPortal2() public broadcast returns (address addr_) {
// Could also verify this inside DeployConfig but doing it here is a bit more reliable.
require(
uint32(cfg.respectedGameType()) == cfg.respectedGameType(), "Deploy: respectedGameType must fit into uint32"
);

addr_ = DeployUtils.create2AndSave({
_save: this,
_salt: _implSalt(),
_name: "OptimismPortal2",
_args: DeployUtils.encodeConstructor(
abi.encodeCall(
IOptimismPortal2.__constructor__,
(cfg.proofMaturityDelaySeconds(), cfg.disputeGameFinalityDelaySeconds())
)
)
});

// Override the `OptimismPortal2` contract to the deployed implementation. This is necessary
// to check the `OptimismPortal2` implementation alongside dependent contracts, which
// are always proxies.
Types.ContractSet memory contracts = _proxiesUnstrict();
contracts.OptimismPortal2 = addr_;
ChainAssertions.checkOptimismPortal2({ _contracts: contracts, _cfg: cfg, _isProxy: false });
}

/// @notice Deploy the L2OutputOracle
function deployL2OutputOracle() public broadcast returns (address addr_) {
IL2OutputOracle oracle = IL2OutputOracle(
Expand All @@ -663,66 +636,6 @@ contract Deploy is Deployer {
addr_ = address(oracle);
}

/// @notice Deploy the DelayedWETH. (Used in FPACOPS)
function deployDelayedWETH() public broadcast returns (address addr_) {
IDelayedWETH weth = IDelayedWETH(
DeployUtils.create2AndSave({
_save: this,
_salt: _implSalt(),
_name: "DelayedWETH",
_args: DeployUtils.encodeConstructor(
abi.encodeCall(IDelayedWETH.__constructor__, (cfg.faultGameWithdrawalDelay()))
)
})
);

// Override the `DelayedWETH` contract to the deployed implementation. This is necessary
// to check the `DelayedWETH` implementation alongside dependent contracts, which are
// always proxies.
Types.ContractSet memory contracts = _proxiesUnstrict();
contracts.DelayedWETH = address(weth);
ChainAssertions.checkDelayedWETH({
_contracts: contracts,
_cfg: cfg,
_isProxy: false,
_expectedOwner: address(0)
});

addr_ = address(weth);
}

/// @notice Deploy the PreimageOracle (Used in FPACOPS)
function deployPreimageOracle() public broadcast returns (address addr_) {
IPreimageOracle preimageOracle = IPreimageOracle(
DeployUtils.create2AndSave({
_save: this,
_salt: _implSalt(),
_name: "PreimageOracle",
_args: DeployUtils.encodeConstructor(
abi.encodeCall(
IPreimageOracle.__constructor__,
(cfg.preimageOracleMinProposalSize(), cfg.preimageOracleChallengePeriod())
)
)
})
);
addr_ = address(preimageOracle);
}

/// @notice Deploy Mips VM. Deploys either MIPS or MIPS2 depending on the environment
/// (Used in FPACOPS)
function deployMips() public broadcast returns (address addr_) {
addr_ = DeployUtils.create2AndSave({
_save: this,
_salt: _implSalt(),
_name: Config.useMultithreadedCannon() ? "MIPS2" : "MIPS",
_args: DeployUtils.encodeConstructor(
abi.encodeCall(IMIPS2.__constructor__, (IPreimageOracle(mustGetAddress("PreimageOracle"))))
)
});
save("Mips", address(addr_));
}

/// @notice Deploy the AnchorStateRegistry (Used in FPACOPS)
function deployAnchorStateRegistry() public broadcast returns (address addr_) {
IAnchorStateRegistry anchorStateRegistry = IAnchorStateRegistry(
Expand Down
242 changes: 0 additions & 242 deletions packages/contracts-bedrock/scripts/fpac/FPACOPS.s.sol

This file was deleted.

Loading

0 comments on commit d23d2bd

Please sign in to comment.