Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
167 commits
Select commit Hold shift + click to select a range
ee52a74
Added test sequencer inbox opt
yahgwai Oct 4, 2023
cb72410
Made state vars immutable
yahgwai Oct 4, 2023
2b17df0
Added commentson max time variation
yahgwai Oct 4, 2023
ad06124
Removed deprecated method
yahgwai Oct 4, 2023
a4c3800
Updated tests
yahgwai Oct 4, 2023
90de978
Updated comments
yahgwai Oct 4, 2023
b7414fb
Formatted files
yahgwai Oct 4, 2023
87aafcf
Test file lint
yahgwai Oct 4, 2023
5890bde
Merge from develop
yahgwai Oct 5, 2023
998fe16
Updated max time variation comments
yahgwai Oct 5, 2023
a60f7ff
Updated tests
yahgwai Oct 5, 2023
b7b2f49
Storage layout checks no longer required for sequencer inbox
yahgwai Oct 5, 2023
7bacbf0
Initial 4844 commit with tests
yahgwai Oct 17, 2023
36b0925
Merge branch 'develop' into 4844-int
yahgwai Oct 17, 2023
6092d89
Merge from develop
yahgwai Oct 17, 2023
233826f
Updated formatting
yahgwai Oct 18, 2023
557835e
Recommented yul compile
yahgwai Oct 18, 2023
a7286ef
Update unit tests
yahgwai Oct 18, 2023
190107b
Added ci for 4844 tests
yahgwai Oct 18, 2023
1e22c1c
test yes
yahgwai Oct 18, 2023
81308cf
Updated to use deneb integration branch
yahgwai Oct 18, 2023
5f4e912
Linting updates
yahgwai Oct 18, 2023
597bd26
Updated validator tests
yahgwai Oct 18, 2023
7073bc9
Seq inbox stub update
yahgwai Oct 18, 2023
8b379e9
Refactored sequencer inbox
yahgwai Oct 19, 2023
888d13e
Use args test branch
yahgwai Oct 19, 2023
a238e59
Updated storage dot
yahgwai Oct 19, 2023
48e3bfe
Formatting
yahgwai Oct 19, 2023
2acdc24
Test formatting
yahgwai Oct 19, 2023
4b061cb
Removed formatting
yahgwai Oct 19, 2023
24f4381
Added no-token-bridge arg
yahgwai Oct 19, 2023
a89fed5
Updated function name in ts
yahgwai Oct 19, 2023
8038022
lint tests
yahgwai Oct 19, 2023
4207de1
Added test get network
yahgwai Oct 19, 2023
4109298
Test change
yahgwai Oct 19, 2023
db6c1bb
Exec sync curl
yahgwai Oct 19, 2023
617a64a
Updated to main
yahgwai Oct 19, 2023
8add810
Test use blocking branch
yahgwai Oct 19, 2023
ea83596
Test exec on 8545
yahgwai Oct 19, 2023
0dffda5
Moved up the getnetwork command
yahgwai Oct 19, 2023
1a39b7a
Added additional wait
yahgwai Oct 19, 2023
381e7b0
Check buffer each round
yahgwai Oct 19, 2023
1aa9861
Also added nitro network startup
yahgwai Oct 19, 2023
a131c7e
Added chainid send command
yahgwai Oct 19, 2023
fcdf14e
try geth network name
yahgwai Oct 19, 2023
e2d019c
Cat hosts
yahgwai Oct 19, 2023
a1cdcdb
Formatting change
yahgwai Oct 19, 2023
d9a5907
Try with ip
yahgwai Oct 19, 2023
dae0397
Remove line break
yahgwai Oct 19, 2023
df2467a
Newline
yahgwai Oct 19, 2023
cb0dc4a
use ip instead of localhost
yahgwai Oct 19, 2023
6e86d91
Add more logging
yahgwai Oct 19, 2023
14a6af5
Try localhost
yahgwai Oct 19, 2023
e483221
Use ip instead of localhost
yahgwai Oct 19, 2023
1a513ce
Added data field to hash
yahgwai Oct 19, 2023
12a5c79
Remove console logging
yahgwai Oct 20, 2023
dcb32a3
Try localhost
yahgwai Oct 20, 2023
2307dbd
Remove cat hosts
yahgwai Oct 20, 2023
487ce12
Added base fee reader
yahgwai Oct 20, 2023
21757ed
Updated build yul flow
yahgwai Oct 23, 2023
8762fce
Moved yul files
yahgwai Oct 23, 2023
d98df6b
Refactoring and custom errors
yahgwai Oct 23, 2023
492e881
Some more comment tidying
yahgwai Oct 23, 2023
59eb0c6
Package updates and seq inbox todos
yahgwai Oct 23, 2023
a55d1c4
Include blobbasefeereader in init
yahgwai Oct 23, 2023
9045c0c
Added dummy blob reader addr
yahgwai Oct 23, 2023
fc8f3a1
Added forge to 4844 yml
yahgwai Oct 23, 2023
85230d3
Updated seq inbox dot
yahgwai Oct 23, 2023
dd549ab
Remove newline
yahgwai Oct 23, 2023
061ccad
Updated docker to specific version
yahgwai Oct 24, 2023
37d2918
Formatting
yahgwai Oct 24, 2023
0b9ba23
Merge from develop
yahgwai Oct 25, 2023
cd0d302
Build updates
yahgwai Oct 25, 2023
75215ba
Updated tests and added bridge.rollup() initialization tests
yahgwai Oct 25, 2023
a3111c4
Formatting
yahgwai Oct 25, 2023
90f2262
Updated arbrollup tests
yahgwai Oct 25, 2023
fe97273
Removed test events
yahgwai Oct 25, 2023
f75a8fc
Moved delayed messages read and batch delivered event into the bridge
yahgwai Oct 26, 2023
887cc47
Removed tests for now
yahgwai Oct 26, 2023
d06f2a0
Added encoder v2
yahgwai Oct 26, 2023
ce8fb88
Updated bridge storage dot
yahgwai Oct 26, 2023
cacb722
Merge from develop
yahgwai Oct 26, 2023
ff5da44
Merge from opt
yahgwai Oct 26, 2023
3609765
Merge branch 'develop' into seq-inbox-opt
gzeoneth Oct 27, 2023
275d75b
Merge remote-tracking branch 'origin/develop' into seq-inbox-opt
gzeoneth Oct 30, 2023
22c9c75
Merge remote-tracking branch 'origin/seq-inbox-opt' into seq-inbox-br…
gzeoneth Oct 31, 2023
a4337e1
Updates from CR
yahgwai Oct 31, 2023
f3b1ceb
Merge branch 'seq-inbox-bridge' of https://github.com/OffchainLabs/ni…
yahgwai Oct 31, 2023
285b6bf
Merge from remote
yahgwai Oct 31, 2023
085e0e9
Removed old dot files
yahgwai Oct 31, 2023
3646a78
Merge pull request #87 from OffchainLabs/seq-inbox-bridge
yahgwai Oct 31, 2023
db5076b
Merge from seq-inbox-opt
yahgwai Nov 3, 2023
a29d143
Added comment about missing revert
yahgwai Nov 3, 2023
1481510
Removed deploy script from tests
yahgwai Nov 13, 2023
2cebe85
Added console log
yahgwai Nov 13, 2023
94d9be0
Formatting
yahgwai Nov 13, 2023
38330be
Updated maxtimevariation logging
yahgwai Nov 13, 2023
9b6f9a6
Initialize accounts in arbrollup tests
yahgwai Nov 14, 2023
4cd2a67
Added test logging
yahgwai Nov 14, 2023
bed2234
Updated seq inbox storage dot
yahgwai Nov 14, 2023
73b13de
Added more logging
yahgwai Nov 14, 2023
1f087bf
Test linting
yahgwai Nov 14, 2023
f321447
Updated sequencer deploy
yahgwai Nov 14, 2023
925e87d
add hardcoded gas
yahgwai Nov 14, 2023
163df9e
Formatting
yahgwai Nov 14, 2023
7239ad4
Commented out constructtor checks
yahgwai Nov 14, 2023
f23072f
Removed logging
yahgwai Nov 14, 2023
3933cbb
Updated storage
yahgwai Nov 14, 2023
894da06
Removed TODO
yahgwai Nov 15, 2023
1227adc
Removed todos
yahgwai Nov 17, 2023
31fd3c6
Added internal max time variation func
yahgwai Nov 17, 2023
05e311d
Updated max time variation to be u64
yahgwai Nov 17, 2023
e281859
Formatting
yahgwai Dec 5, 2023
f50ec32
Updates from code review comments
yahgwai Dec 5, 2023
5187e5f
Allow zero length data
yahgwai Dec 5, 2023
5c0f0d1
Additional comments
yahgwai Dec 5, 2023
773e1ec
Merge branch 'develop' into seq-inbox-opt
Tristan-Wilson Dec 7, 2023
c84363d
Updated 4844 tests
yahgwai Dec 11, 2023
86b1e9b
Merge branch 'seq-inbox-opt' into 4844-int-opt
yahgwai Dec 11, 2023
5974096
Updated seq inbox batch normal test
yahgwai Dec 11, 2023
3b59719
refactor: remove sequencer immutable optimation
gzeoneth Jan 18, 2024
9bcde9e
Merge remote-tracking branch 'origin/develop' into 4844-only-2
gzeoneth Jan 18, 2024
a4e709c
chore: remove dot file
gzeoneth Jan 18, 2024
0e733fc
Added both block basefee and blob basefee to batch spending report
yahgwai Jan 18, 2024
0efe90c
Updated gas refunder for blob costs
yahgwai Jan 17, 2024
e6871c5
Moved gas refund enabled to separate file to for interface compatibil…
yahgwai Jan 17, 2024
798934b
Merge remote-tracking branch 'origin/develop' into 4844-only
gzeoneth Jan 18, 2024
e3cc721
fix: add DelegateCallAware
gzeoneth Jan 18, 2024
dcb688b
Include blob cost in extraGas field of batch posting reports
PlasmaPower Jan 19, 2024
b95ab08
Expect extraGas field in batch posting report
PlasmaPower Jan 19, 2024
5989fe0
chore: revert SequencerInboxStub changes
gzeoneth Jan 19, 2024
cb4fe67
Merge branch '4844-only' into blob-extra-gas
PlasmaPower Jan 19, 2024
77ce30e
Fix expected log in SequencerInboxTest
PlasmaPower Jan 19, 2024
ab7df1b
Moved 4844 readers into a single yul contract - reduces stack size in…
yahgwai Jan 19, 2024
fec2e1e
Merge from 4844-only
yahgwai Jan 19, 2024
229b43a
Formatting
yahgwai Jan 19, 2024
d07138c
Formatting
yahgwai Jan 19, 2024
4d91bc1
test: fix
gzeoneth Jan 19, 2024
7957bf7
test: fix 4844
gzeoneth Jan 19, 2024
477b16f
fix: solhint
gzeoneth Jan 19, 2024
b0c43dc
Merge pull request #114 from OffchainLabs/blob-extra-gas
gzeoneth Jan 19, 2024
62a06a5
Merge remote-tracking branch 'origin/4844-only' into 4844-gas-refunder
gzeoneth Jan 19, 2024
a8e7709
Merge pull request #111 from OffchainLabs/4844-gas-refunder
gzeoneth Jan 19, 2024
5f1d5f5
Add safety checks to Reader4844.yul
PlasmaPower Jan 19, 2024
ac03c0e
Use solc's formatting for Yul
PlasmaPower Jan 19, 2024
5bfc19a
Merge pull request #115 from OffchainLabs/reader-4844-safety
gzeoneth Jan 20, 2024
9ee895e
Added postupgradeinit for the challenge manafer
yahgwai Jan 22, 2024
dd3d8ba
Formatting
yahgwai Jan 22, 2024
86390e6
Added postupgradeinit tests
yahgwai Jan 22, 2024
142e758
Merge pull request #116 from OffchainLabs/4844-chalman-update
yahgwai Jan 22, 2024
00d4d62
Use 0x50 as the header byte for 4844 batches
PlasmaPower Jan 23, 2024
66aba4e
test: update DATA_BLOB_HEADER_FLAG
gzeoneth Jan 23, 2024
6822d51
Merge pull request #118 from OffchainLabs/4844-0x50
gzeoneth Jan 23, 2024
e253b8b
Support zero basefee for gas estimation
PlasmaPower Jan 24, 2024
cd5093d
Fix SequencerInboxStubCreator
PlasmaPower Jan 24, 2024
d5d576f
Merge pull request #119 from OffchainLabs/zero-basefee
gzeoneth Jan 24, 2024
e3a656e
Merge pull request #120 from OffchainLabs/fix-stub-creator
gzeoneth Jan 24, 2024
12d7a3f
Removed TODOs
yahgwai Jan 24, 2024
d63b064
Increased data size
yahgwai Jan 24, 2024
ecca913
fix: txorigin as spender
gzeoneth Jan 24, 2024
58c6008
chore: deprecate old method
gzeoneth Jan 24, 2024
0a6322f
fix: duplicated declaration
gzeoneth Jan 24, 2024
201890e
refactor: move blob gas logic
gzeoneth Jan 24, 2024
e5c5af2
format: fix
gzeoneth Jan 24, 2024
22dd3a7
docs: more comment
gzeoneth Jan 24, 2024
cc976ab
docs: comments
gzeoneth Jan 24, 2024
86b2b09
Merge pull request #121 from OffchainLabs/4844-blob-spend
gzeoneth Jan 24, 2024
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
45 changes: 43 additions & 2 deletions .github/workflows/contract-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
- name: Install packages
run: yarn

- name: Run unit tests
- name: Build
run: forge test
tests:
name: Contract tests
Expand All @@ -44,6 +44,13 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: recursive

- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly

- name: Setup nodejs
uses: actions/setup-node@v2
Expand All @@ -67,7 +74,7 @@ jobs:
run: yarn lint:test

- name: Build
run: yarn build
run: yarn build:all

- name: Run tests
run: yarn hardhat --network hardhat test test/contract/*.spec.ts
Expand All @@ -91,3 +98,37 @@ jobs:
files: ./contracts/coverage.json
verbose: false
token: ${{ secrets.CODECOV_TOKEN }}
test-4844:
name: 4844 tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: recursive

- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly

- uses: OffchainLabs/actions/run-nitro-test-node@test-node-args
with:
nitro-testnode-ref: deneb-integration
args: --pos
no-token-bridge: true

- name: Setup nodejs
uses: actions/setup-node@v2
with:
node-version: '18'
cache: 'yarn'
cache-dependency-path: '**/yarn.lock'

- name: Install dependencies
run: yarn install

- name: Build
run: yarn build:all

- name: Test 4844
run: yarn test:4844
2 changes: 1 addition & 1 deletion .prettierrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ module.exports = {
printWidth: 100,
singleQuote: false,
bracketSpacing: false,
compiler: '0.8.6',
compiler: '0.8.9',
},
},
],
Expand Down
3 changes: 3 additions & 0 deletions deploy/SequencerInbox.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ module.exports = async hre => {
const { deploy } = deployments
const { deployer } = await getNamedAccounts()

const blobBasefeeReader = await ethers.getContract('BlobBasefeeReader')
const dataHashReader = await ethers.getContract('DataHashReader')

await deploy('SequencerInbox', { from: deployer, args: [117964] })
}

Expand Down
9 changes: 7 additions & 2 deletions deploy/SequencerInboxStubCreator.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
import { Toolkit4844 } from '../test/contract/toolkit4844'

module.exports = async hre => {
const { deployments, getNamedAccounts, ethers } = hre
const { deployments, getSigners, getNamedAccounts, ethers } = hre
const { deploy } = deployments
const { deployer } = await getNamedAccounts()

const bridge = await ethers.getContract('BridgeStub')
const reader4844 = await Toolkit4844.deployReader4844(
await ethers.getSigner(deployer)
)
const maxTime = {
delayBlocks: 10000,
futureBlocks: 10000,
Expand All @@ -12,7 +17,7 @@ module.exports = async hre => {
}
await deploy('SequencerInboxStub', {
from: deployer,
args: [bridge.address, deployer, maxTime, 117964],
args: [bridge.address, deployer, maxTime, 117964, reader4844.address],
})
}

Expand Down
10 changes: 8 additions & 2 deletions foundry.toml
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
[profile.default]
src = 'src'
src = 'src/'
out = 'out'
libs = ['node_modules', 'lib']
test = 'test/foundry'
cache_path = 'forge-cache'
cache_path = 'forge-cache/sol'
optimizer = true
optimizer_runs = 20000
via_ir = false
solc_version = '0.8.9'

[profile.yul]
src = 'yul'
out = 'out/yul'
libs = ['node_modules', 'lib']
cache_path = 'forge-cache/yul'

[fmt]
number_underscore = 'thousands'
line_length = 100
Expand Down
1 change: 1 addition & 0 deletions hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import '@typechain/hardhat'
import 'solidity-coverage'
import 'hardhat-gas-reporter'
import 'hardhat-ignore-warnings'
// import '@tovarishfin/hardhat-yul';
import dotenv from 'dotenv'

dotenv.config()
Expand Down
7 changes: 7 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,19 @@
},
"scripts": {
"prepublishOnly": "hardhat clean && hardhat compile",
"build:all": "yarn build && yarn build:forge",
"build": "hardhat compile",
"build:forge:sol": "forge build --skip *.yul",
"build:forge:yul": "FOUNDRY_PROFILE=yul forge build --skip *.sol",
"build:forge": "yarn build:forge:sol && yarn build:forge:yul",
"lint:test": "eslint ./test",
"solhint": "solhint -f table src/**/*.sol",
"prettier:solidity": "prettier --write src/**/*.sol",
"format": "prettier './**/*.{js,json,md,ts,yml,sol}' --write && yarn run lint:test --fix",
"build:0.6": "INTERFACE_TESTER_SOLC_VERSION=0.6.9 yarn run build",
"build:0.7": "INTERFACE_TESTER_SOLC_VERSION=0.7.0 yarn run build",
"test": "DISABLE_GAS_REPORTER=true hardhat --network hardhat test test/contract/*.spec.ts",
"test:4844": "DISABLE_GAS_REPORTER=true hardhat --network hardhat test test/contract/*.spec.4844.ts",
"test:compatibility": "yarn run build:0.6 && yarn run build:0.7",
"test:storage": "./test/storage/test.bash",
"test:e2e": "hardhat test test/e2e/*.ts",
Expand All @@ -46,6 +52,7 @@
"@nomiclabs/hardhat-ethers": "npm:hardhat-deploy-ethers@^0.3.0-beta.13",
"@nomiclabs/hardhat-etherscan": "^3.1.0",
"@nomiclabs/hardhat-waffle": "^2.0.1",
"@tovarishfin/hardhat-yul": "^3.0.5",
"@typechain/ethers-v5": "^10.0.0",
"@typechain/hardhat": "^6.0.0",
"@types/chai": "^4.3.0",
Expand Down
12 changes: 4 additions & 8 deletions scripts/rollupCreation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,15 +85,11 @@ export async function createRollup(feeToken?: string) {
maxDataSize: maxDataSize,
nativeToken: feeToken,
deployFactoriesToL2: true,
maxFeePerGasForRetryables: MAX_FER_PER_GAS
maxFeePerGasForRetryables: MAX_FER_PER_GAS,
}
const createRollupTx = await rollupCreator.createRollup(
deployParams,
{
value: feeCost,
}

)
const createRollupTx = await rollupCreator.createRollup(deployParams, {
value: feeCost,
})
const createRollupReceipt = await createRollupTx.wait()

const rollupCreatedEvent = createRollupReceipt.events?.find(
Expand Down
22 changes: 22 additions & 0 deletions src/bridge/IBridge.sol
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,28 @@ pragma solidity >=0.6.9 <0.9.0;
import "./IOwnable.sol";

interface IBridge {
/// @dev This is an instruction to offchain readers to inform them where to look
/// for sequencer inbox batch data. This is not the type of data (eg. das, brotli encoded, or blob versioned hash)
/// and this enum is not used in the state transition function, rather it informs an offchain
/// reader where to find the data so that they can supply it to the replay binary
enum BatchDataLocation {
/// @notice The data can be found in the transaction call data
TxInput,
/// @notice The data can be found in an event emitted during the transaction
SeparateBatchEvent,
/// @notice This batch contains no data
NoData,
/// @notice The data can be found in the 4844 data blobs on this transaction
Blob
}

struct TimeBounds {
uint64 minTimestamp;
uint64 maxTimestamp;
uint64 minBlockNumber;
uint64 maxBlockNumber;
}

event MessageDelivered(
uint256 indexed messageIndex,
bytes32 indexed beforeInboxAcc,
Expand Down
84 changes: 60 additions & 24 deletions src/bridge/ISequencerInbox.sol
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,10 @@ import "./IBridge.sol";

interface ISequencerInbox is IDelayedMessageProvider {
struct MaxTimeVariation {
uint256 delayBlocks;
uint256 futureBlocks;
uint256 delaySeconds;
uint256 futureSeconds;
}

struct TimeBounds {
uint64 minTimestamp;
uint64 maxTimestamp;
uint64 minBlockNumber;
uint64 maxBlockNumber;
}

enum BatchDataLocation {
TxInput,
SeparateBatchEvent,
NoData
uint64 delayBlocks;
uint64 futureBlocks;
uint64 delaySeconds;
uint64 futureSeconds;
}

event SequencerBatchDelivered(
Expand All @@ -37,8 +24,8 @@ interface ISequencerInbox is IDelayedMessageProvider {
bytes32 indexed afterAcc,
bytes32 delayedAcc,
uint256 afterDelayedMessagesRead,
TimeBounds timeBounds,
BatchDataLocation dataLocation
IBridge.TimeBounds timeBounds,
IBridge.BatchDataLocation dataLocation
);

event OwnerFunctionCalled(uint256 indexed id);
Expand All @@ -61,10 +48,41 @@ interface ISequencerInbox is IDelayedMessageProvider {
function HEADER_LENGTH() external view returns (uint256);

/// @dev If the first batch data byte after the header has this bit set,
/// the sequencer inbox has authenticated the data. Currently not used.
/// the sequencer inbox has authenticated the data. Currently only used for 4844 blob support.
/// See: https://github.com/OffchainLabs/nitro/blob/69de0603abf6f900a4128cab7933df60cad54ded/arbstate/das_reader.go
// solhint-disable-next-line func-name-mixedcase
function DATA_AUTHENTICATED_FLAG() external view returns (bytes1);

/// @dev If the first data byte after the header has this bit set,
/// then the batch data is to be found in 4844 data blobs
/// See: https://github.com/OffchainLabs/nitro/blob/69de0603abf6f900a4128cab7933df60cad54ded/arbstate/das_reader.go
// solhint-disable-next-line func-name-mixedcase
function DATA_BLOB_HEADER_FLAG() external view returns (bytes1);

/// @dev If the first data byte after the header has this bit set,
/// then the batch data is a das message
/// See: https://github.com/OffchainLabs/nitro/blob/69de0603abf6f900a4128cab7933df60cad54ded/arbstate/das_reader.go
// solhint-disable-next-line func-name-mixedcase
function DAS_MESSAGE_HEADER_FLAG() external view returns (bytes1);

/// @dev If the first data byte after the header has this bit set,
/// then the batch data is a das message that employs a merklesization strategy
/// See: https://github.com/OffchainLabs/nitro/blob/69de0603abf6f900a4128cab7933df60cad54ded/arbstate/das_reader.go
// solhint-disable-next-line func-name-mixedcase
function TREE_DAS_MESSAGE_HEADER_FLAG() external view returns (bytes1);

/// @dev If the first data byte after the header has this bit set,
/// then the batch data has been brotli compressed
/// See: https://github.com/OffchainLabs/nitro/blob/69de0603abf6f900a4128cab7933df60cad54ded/arbstate/das_reader.go
// solhint-disable-next-line func-name-mixedcase
function BROTLI_MESSAGE_HEADER_FLAG() external view returns (bytes1);

/// @dev If the first data byte after the header has this bit set,
/// then the batch data uses a zero heavy encoding
/// See: https://github.com/OffchainLabs/nitro/blob/69de0603abf6f900a4128cab7933df60cad54ded/arbstate/das_reader.go
// solhint-disable-next-line func-name-mixedcase
function ZERO_HEAVY_MESSAGE_HEADER_FLAG() external view returns (bytes1);

function rollup() external view returns (IOwnable);

function isBatchPoster(address) external view returns (bool);
Expand All @@ -78,14 +96,15 @@ interface ISequencerInbox is IDelayedMessageProvider {
uint64 creationBlock;
}

/// @dev returns 4 uint256 to be compatible with older version
function maxTimeVariation()
external
view
returns (
uint256,
uint256,
uint256,
uint256
uint256 delayBlocks,
uint256 futureBlocks,
uint256 delaySeconds,
uint256 futureSeconds
);

function dasKeySetInfo(bytes32) external view returns (bool, uint64);
Expand Down Expand Up @@ -130,6 +149,15 @@ interface ISequencerInbox is IDelayedMessageProvider {
IGasRefunder gasRefunder
) external;

function addSequencerL2BatchFromOrigin(
uint256 sequenceNumber,
bytes calldata data,
uint256 afterDelayedMessagesRead,
IGasRefunder gasRefunder,
uint256 prevMessageCount,
uint256 newMessageCount
) external;

function addSequencerL2Batch(
uint256 sequenceNumber,
bytes calldata data,
Expand All @@ -139,6 +167,14 @@ interface ISequencerInbox is IDelayedMessageProvider {
uint256 newMessageCount
) external;

function addSequencerL2BatchFromBlobs(
uint256 sequenceNumber,
uint256 afterDelayedMessagesRead,
IGasRefunder gasRefunder,
uint256 prevMessageCount,
uint256 newMessageCount
) external;

// ---------- onlyRollupOrOwner functions ----------

/**
Expand Down
Loading