diff --git a/contracts/CHANGELOG.md b/contracts/CHANGELOG.md index 0a0250ade..9d4abf080 100644 --- a/contracts/CHANGELOG.md +++ b/contracts/CHANGELOG.md @@ -15,6 +15,10 @@ The format is based on [Common Changelog](https://common-changelog.org/). - Bump `hardhat` to v2.26.2 ([#2069](https://github.com/kleros/kleros-v2/issues/2069)) - Bump `@kleros/vea-contracts` to v0.7.0 ([#2073](https://github.com/kleros/kleros-v2/issues/2073)) +### Fixed + +- Do not pass to Voting period if all the commits are cast because it breaks the current Shutter auto-reveal process. ([#2085](https://github.com/kleros/kleros-v2/issues/2085)) + ## [0.12.0] - 2025-08-05 ### Changed diff --git a/contracts/src/arbitration/KlerosCoreBase.sol b/contracts/src/arbitration/KlerosCoreBase.sol index 2b9998bda..22d1d996a 100644 --- a/contracts/src/arbitration/KlerosCoreBase.sol +++ b/contracts/src/arbitration/KlerosCoreBase.sol @@ -566,10 +566,8 @@ abstract contract KlerosCoreBase is IArbitratorV2, Initializable, UUPSProxiable if (round.drawnJurors.length != round.nbVotes) revert DisputeStillDrawing(); dispute.period = court.hiddenVotes ? Period.commit : Period.vote; } else if (dispute.period == Period.commit) { - if ( - block.timestamp - dispute.lastPeriodChange < court.timesPerPeriod[uint256(dispute.period)] && - !disputeKits[round.disputeKitID].areCommitsAllCast(_disputeID) - ) { + // Note that we do not want to pass to Voting period if all the commits are cast because it breaks the Shutter auto-reveal currently. + if (block.timestamp - dispute.lastPeriodChange < court.timesPerPeriod[uint256(dispute.period)]) { revert CommitPeriodNotPassed(); } dispute.period = Period.vote; diff --git a/contracts/test/foundry/KlerosCore.t.sol b/contracts/test/foundry/KlerosCore.t.sol index 72a6a565c..3387ca187 100644 --- a/contracts/test/foundry/KlerosCore.t.sol +++ b/contracts/test/foundry/KlerosCore.t.sol @@ -1622,6 +1622,7 @@ contract KlerosCoreTest is Test { } // Check reveal in the next period + vm.warp(block.timestamp + timesPerPeriod[1]); core.passPeriod(disputeID); // Check the require with the wrong choice and then with the wrong salt