Commit 3fbb4425 authored by clabby's avatar clabby Committed by GitHub

fix(ctb): Flaky test fix (#10163)

parent ba6d7f56
This diff is collapsed.
...@@ -112,8 +112,8 @@ ...@@ -112,8 +112,8 @@
"sourceCodeHash": "0x08f34cec56d58ea6ee7a47b5adcbeca6a68a5dd1daa949330b4bde86c2e605f5" "sourceCodeHash": "0x08f34cec56d58ea6ee7a47b5adcbeca6a68a5dd1daa949330b4bde86c2e605f5"
}, },
"src/dispute/FaultDisputeGame.sol": { "src/dispute/FaultDisputeGame.sol": {
"initCodeHash": "0x840cead3853807f27b3fd995d2f0c0ffc2a4a804d9dbd105cceba04e92109e47", "initCodeHash": "0x42c04ec50860cf8f1f772bc77dcbd20e7e06554a0962d16eaad2ee5fd748cfe0",
"sourceCodeHash": "0x15ec89d7c8751e51e1986d1111c74462adfbd33240bffb273f2f7894a731e5dd" "sourceCodeHash": "0x8ea9b68ddfc6fce606065a789b7323d8b119aadb162c139f1878a9322b1e892b"
}, },
"src/dispute/weth/DelayedWETH.sol": { "src/dispute/weth/DelayedWETH.sol": {
"initCodeHash": "0x7b6ec89eaec09e369426e73161a9c6932223bb1f974377190c3f6f552995da35", "initCodeHash": "0x7b6ec89eaec09e369426e73161a9c6932223bb1f974377190c3f6f552995da35",
......
...@@ -88,8 +88,8 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver { ...@@ -88,8 +88,8 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver {
OutputRoot public startingOutputRoot; OutputRoot public startingOutputRoot;
/// @notice Semantic version. /// @notice Semantic version.
/// @custom:semver 0.14.0 /// @custom:semver 0.15.0
string public constant version = "0.14.0"; string public constant version = "0.15.0";
/// @param _gameType The type ID of the game. /// @param _gameType The type ID of the game.
/// @param _absolutePrestate The absolute prestate of the instruction trace. /// @param _absolutePrestate The absolute prestate of the instruction trace.
...@@ -514,10 +514,6 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver { ...@@ -514,10 +514,6 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver {
// Set the starting output root. // Set the starting output root.
startingOutputRoot = OutputRoot({ l2BlockNumber: rootBlockNumber, root: root }); startingOutputRoot = OutputRoot({ l2BlockNumber: rootBlockNumber, root: root });
// Do not allow the game to be initialized if the root claim corresponds to a block at or before the
// configured starting block number.
if (l2BlockNumber() <= rootBlockNumber) revert UnexpectedRootClaim(rootClaim());
// Revert if the calldata size is not the expected length. // Revert if the calldata size is not the expected length.
// //
// This is to prevent adding extra or omitting bytes from to `extraData` that result in a different game UUID // This is to prevent adding extra or omitting bytes from to `extraData` that result in a different game UUID
...@@ -539,6 +535,10 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver { ...@@ -539,6 +535,10 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver {
} }
} }
// Do not allow the game to be initialized if the root claim corresponds to a block at or before the
// configured starting block number.
if (l2BlockNumber() <= rootBlockNumber) revert UnexpectedRootClaim(rootClaim());
// Set the root claim // Set the root claim
claimData.push( claimData.push(
ClaimData({ ClaimData({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment