Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

BinaryMerkleTreeErrors

Git Source

Errors

InvalidNodeIndex

The provided node index is invalid.

The node index should be less than 2^{height}.

error InvalidNodeIndex(uint256 nodeIndex, uint256 height);

Parameters

NameTypeDescription
nodeIndexuint256The node index in its level
heightuint256The binary Merkle tree height

DriveTooLarge

A drive size too large was provided.

error DriveTooLarge(uint256 log2DriveSize, uint256 maxLog2DriveSize);

Parameters

NameTypeDescription
log2DriveSizeuint256The log2 size of the drive
maxLog2DriveSizeuint256The maximum log2 size of a drive

DataBlockTooLarge

A data block size too large was provided.

error DataBlockTooLarge(uint256 log2DataBlockSize, uint256 maxLog2DataBlockSize);

Parameters

NameTypeDescription
log2DataBlockSizeuint256The log2 size of the data block
maxLog2DataBlockSizeuint256The maximum log2 size of a data block

DriveSmallerThanDataBlock

A drive size smaller than the data block size was provided.

error DriveSmallerThanDataBlock(uint256 log2DriveSize, uint256 log2DataBlockSize);

Parameters

NameTypeDescription
log2DriveSizeuint256The log2 size of the drive
log2DataBlockSizeuint256The log2 size of the data block

DriveSmallerThanData

A drive too small to fit the data was provided.

error DriveSmallerThanData(uint256 driveSize, uint256 dataSize);

Parameters

NameTypeDescription
driveSizeuint256The size of the drive
dataSizeuint256The size of the data

UnexpectedFinalStackDepth

An unexpected stack error occurred.

Expected final stack depth to be 1.

error UnexpectedFinalStackDepth(uint256 stackDepth);

Parameters

NameTypeDescription
stackDepthuint256The final stack depth