Skip to content
Closed
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
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,9 @@ contract ExecutorFacet is ZKChainBase, IExecutor {
if (_newBatch.lastBlockTimestamp > block.timestamp + COMMIT_TIMESTAMP_APPROXIMATION_DELTA) {
revert L2TimestampTooBig();
}
if (_newBatch.firstBlockTimestamp >= _newBatch.lastBlockTimestamp) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if we are going to merge this, but if we are - we need to use > here

revert NonIncreasingTimestamp();
Comment on lines +193 to +194

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Rejects single‑block batches via strict timestamp inequality

The new NonIncreasingTimestamp guard now reverts when firstBlockTimestamp equals lastBlockTimestamp. A batch containing a single L2 block has identical first/last timestamps (the shared executor fixture initializes both to the batch timestamp in _Executor_Shared.t.sol), which previously committed successfully. With this change such batches will revert during commitBatchesSharedBridge, blocking valid one-block batches unless callers artificially bump the last timestamp.

Useful? React with 👍 / 👎.

}
if (_newBatch.chainId != s.chainId) {
revert IncorrectBatchChainId(_newBatch.chainId, s.chainId);
}
Expand Down
Loading