Skip to content

Commit 7cb4449

Browse files
committed
refactor: natspec + interfaces
refactor: natspec + interfaces docs: `RegistryCoordinator` natspec chore: forge fmt refactor: named mapping params docs: natspec `BLSApkRegistry` docs: natspec `BLSApkRegistry` docs: natspec `BLSApkRegistry` refactor: interface structure refactor: separate `BLSSignatureChecker` storage refactor: rename -> `IECDSAStakeRegistry` docs: natspec docs: natspec `ECDSAStakeRegistry` docs: natspec `EjectionManager` + separate storage docs: natspec docs: natspec `IndexRegistry` refactor: remove `IRegistry` chore: forge fmt chore: make storage-report docs: natspec refactor: remove `ISocketUpdater`
1 parent d2bfd57 commit 7cb4449

File tree

64 files changed

+2789
-2286
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+2789
-2286
lines changed

Diff for: .github/bin/storage-report.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ for file in $(find src/ -name "*.sol" ! -path "*/interfaces/*" ! -path "*/librar
3737
log "Processing contract: $contract_name"
3838

3939
# Run forge inspect and capture errors
40-
if ! forge inspect "$contract_name" storage --pretty > "$OUTPUT_DIR/$contract_name.md"; then
40+
if ! forge inspect "$contract_name" storage > "$OUTPUT_DIR/$contract_name.md"; then
4141
error "Failed to generate storage report for contract: $contract_name"
4242
else
4343
log "Storage report generated for contract: $contract_name"

Diff for: bin/storage-report.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ for file in $(find src/ -name "*.sol" ! -path "*/interfaces/*" ! -path "*/librar
3737
log "Processing contract: $contract_name"
3838

3939
# Run forge inspect and capture errors
40-
if ! forge inspect "$contract_name" storage --pretty > "$OUTPUT_DIR/$contract_name.md"; then
40+
if ! forge inspect "$contract_name" storage > "$OUTPUT_DIR/$contract_name.md"; then
4141
error "Failed to generate storage report for contract: $contract_name"
4242
else
4343
log "Storage report generated for contract: $contract_name"

Diff for: docs/RegistryCoordinator.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ These methods allow operators to register for/deregister from one or more quorum
4242
function registerOperator(
4343
bytes calldata quorumNumbers,
4444
string calldata socket,
45-
IBLSApkRegistry.PubkeyRegistrationParams calldata params,
45+
IBLSApkRegistryTypes.PubkeyRegistrationParams calldata params,
4646
SignatureWithSaltAndExpiry memory operatorSignature
4747
)
4848
external
@@ -88,7 +88,7 @@ If the Operator was not currently registered for any quorums, this method will r
8888
function registerOperatorWithChurn(
8989
bytes calldata quorumNumbers,
9090
string calldata socket,
91-
IBLSApkRegistry.PubkeyRegistrationParams calldata params,
91+
IBLSApkRegistryTypes.PubkeyRegistrationParams calldata params,
9292
OperatorKickParam[] calldata operatorKickParams,
9393
SignatureWithSaltAndExpiry memory churnApproverSignature,
9494
SignatureWithSaltAndExpiry memory operatorSignature
@@ -256,7 +256,7 @@ These methods are used by the Owner to configure the `RegistryCoordinator`:
256256
function createQuorum(
257257
OperatorSetParam memory operatorSetParams,
258258
uint96 minimumStake,
259-
IStakeRegistry.StrategyParams[] memory strategyParams
259+
IStakeRegistryTypes.StrategyParams[] memory strategyParams
260260
)
261261
external
262262
virtual

Diff for: docs/storage-report/BLSApkRegistry.md

+19-19
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11

2-
╭----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------╮
3-
| Name | Type | Slot | Offset | Bytes | Contract |
4-
+=============================================================================================================================================+
5-
| _initialized | uint8 | 0 | 0 | 1 | src/BLSApkRegistry.sol:BLSApkRegistry |
6-
|----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------|
7-
| _initializing | bool | 0 | 1 | 1 | src/BLSApkRegistry.sol:BLSApkRegistry |
8-
|----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------|
9-
| operatorToPubkeyHash | mapping(address => bytes32) | 1 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
10-
|----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------|
11-
| pubkeyHashToOperator | mapping(bytes32 => address) | 2 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
12-
|----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------|
13-
| operatorToPubkey | mapping(address => struct BN254.G1Point) | 3 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
14-
|----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------|
15-
| apkHistory | mapping(uint8 => struct IBLSApkRegistry.ApkUpdate[]) | 4 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
16-
|----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------|
17-
| currentApk | mapping(uint8 => struct BN254.G1Point) | 5 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
18-
|----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------|
19-
| __GAP | uint256[45] | 6 | 0 | 1440 | src/BLSApkRegistry.sol:BLSApkRegistry |
20-
╰----------------------+------------------------------------------------------+------+--------+-------+---------------------------------------╯
2+
╭----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------╮
3+
| Name | Type | Slot | Offset | Bytes | Contract |
4+
+==================================================================================================================================================+
5+
| _initialized | uint8 | 0 | 0 | 1 | src/BLSApkRegistry.sol:BLSApkRegistry |
6+
|----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------|
7+
| _initializing | bool | 0 | 1 | 1 | src/BLSApkRegistry.sol:BLSApkRegistry |
8+
|----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------|
9+
| operatorToPubkeyHash | mapping(address => bytes32) | 1 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
10+
|----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------|
11+
| pubkeyHashToOperator | mapping(bytes32 => address) | 2 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
12+
|----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------|
13+
| operatorToPubkey | mapping(address => struct BN254.G1Point) | 3 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
14+
|----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------|
15+
| apkHistory | mapping(uint8 => struct IBLSApkRegistryTypes.ApkUpdate[]) | 4 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
16+
|----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------|
17+
| currentApk | mapping(uint8 => struct BN254.G1Point) | 5 | 0 | 32 | src/BLSApkRegistry.sol:BLSApkRegistry |
18+
|----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------|
19+
| __GAP | uint256[45] | 6 | 0 | 1440 | src/BLSApkRegistry.sol:BLSApkRegistry |
20+
╰----------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------╯
2121

Diff for: docs/storage-report/BLSApkRegistryStorage.md

+19-19
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11

2-
╭----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------╮
3-
| Name | Type | Slot | Offset | Bytes | Contract |
4-
+===========================================================================================================================================================+
5-
| _initialized | uint8 | 0 | 0 | 1 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
6-
|----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
7-
| _initializing | bool | 0 | 1 | 1 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
8-
|----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
9-
| operatorToPubkeyHash | mapping(address => bytes32) | 1 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
10-
|----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
11-
| pubkeyHashToOperator | mapping(bytes32 => address) | 2 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
12-
|----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
13-
| operatorToPubkey | mapping(address => struct BN254.G1Point) | 3 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
14-
|----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
15-
| apkHistory | mapping(uint8 => struct IBLSApkRegistry.ApkUpdate[]) | 4 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
16-
|----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
17-
| currentApk | mapping(uint8 => struct BN254.G1Point) | 5 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
18-
|----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
19-
| __GAP | uint256[45] | 6 | 0 | 1440 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
20-
╰----------------------+------------------------------------------------------+------+--------+-------+-----------------------------------------------------╯
2+
╭----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------╮
3+
| Name | Type | Slot | Offset | Bytes | Contract |
4+
+================================================================================================================================================================+
5+
| _initialized | uint8 | 0 | 0 | 1 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
6+
|----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
7+
| _initializing | bool | 0 | 1 | 1 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
8+
|----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
9+
| operatorToPubkeyHash | mapping(address => bytes32) | 1 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
10+
|----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
11+
| pubkeyHashToOperator | mapping(bytes32 => address) | 2 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
12+
|----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
13+
| operatorToPubkey | mapping(address => struct BN254.G1Point) | 3 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
14+
|----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
15+
| apkHistory | mapping(uint8 => struct IBLSApkRegistryTypes.ApkUpdate[]) | 4 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
16+
|----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
17+
| currentApk | mapping(uint8 => struct BN254.G1Point) | 5 | 0 | 32 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
18+
|----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------|
19+
| __GAP | uint256[45] | 6 | 0 | 1440 | src/BLSApkRegistryStorage.sol:BLSApkRegistryStorage |
20+
╰----------------------+-----------------------------------------------------------+------+--------+-------+-----------------------------------------------------╯
2121

Diff for: docs/storage-report/BLSSignatureCheckerStorage.md

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
2+
╭----------------------+-------------+------+--------+-------+---------------------------------------------------------------╮
3+
| Name | Type | Slot | Offset | Bytes | Contract |
4+
+============================================================================================================================+
5+
| staleStakesForbidden | bool | 0 | 0 | 1 | src/BLSSignatureCheckerStorage.sol:BLSSignatureCheckerStorage |
6+
|----------------------+-------------+------+--------+-------+---------------------------------------------------------------|
7+
| __GAP | uint256[49] | 1 | 0 | 1568 | src/BLSSignatureCheckerStorage.sol:BLSSignatureCheckerStorage |
8+
╰----------------------+-------------+------+--------+-------+---------------------------------------------------------------╯
9+

Diff for: docs/storage-report/ECDSAStakeRegistry.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
|----------------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------------------------|
1515
| _totalOperators | uint256 | 101 | 0 | 32 | src/unaudited/ECDSAStakeRegistry.sol:ECDSAStakeRegistry |
1616
|----------------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------------------------|
17-
| _quorum | struct Quorum | 102 | 0 | 32 | src/unaudited/ECDSAStakeRegistry.sol:ECDSAStakeRegistry |
17+
| _quorum | struct IECDSAStakeRegistryTypes.Quorum | 102 | 0 | 32 | src/unaudited/ECDSAStakeRegistry.sol:ECDSAStakeRegistry |
1818
|----------------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------------------------|
1919
| _minimumWeight | uint256 | 103 | 0 | 32 | src/unaudited/ECDSAStakeRegistry.sol:ECDSAStakeRegistry |
2020
|----------------------------+-----------------------------------------------------------+------+--------+-------+---------------------------------------------------------|

Diff for: docs/storage-report/ECDSAStakeRegistryEqualWeight.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
|----------------------------+-----------------------------------------------------------+------+--------+-------+----------------------------------------------------------------------------------------|
1515
| _totalOperators | uint256 | 101 | 0 | 32 | src/unaudited/examples/ECDSAStakeRegistryEqualWeight.sol:ECDSAStakeRegistryEqualWeight |
1616
|----------------------------+-----------------------------------------------------------+------+--------+-------+----------------------------------------------------------------------------------------|
17-
| _quorum | struct Quorum | 102 | 0 | 32 | src/unaudited/examples/ECDSAStakeRegistryEqualWeight.sol:ECDSAStakeRegistryEqualWeight |
17+
| _quorum | struct IECDSAStakeRegistryTypes.Quorum | 102 | 0 | 32 | src/unaudited/examples/ECDSAStakeRegistryEqualWeight.sol:ECDSAStakeRegistryEqualWeight |
1818
|----------------------------+-----------------------------------------------------------+------+--------+-------+----------------------------------------------------------------------------------------|
1919
| _minimumWeight | uint256 | 103 | 0 | 32 | src/unaudited/examples/ECDSAStakeRegistryEqualWeight.sol:ECDSAStakeRegistryEqualWeight |
2020
|----------------------------+-----------------------------------------------------------+------+--------+-------+----------------------------------------------------------------------------------------|

Diff for: docs/storage-report/ECDSAStakeRegistryPermissioned.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
|----------------------------+-----------------------------------------------------------+------+--------+-------+------------------------------------------------------------------------------------------|
1515
| _totalOperators | uint256 | 101 | 0 | 32 | src/unaudited/examples/ECDSAStakeRegistryPermissioned.sol:ECDSAStakeRegistryPermissioned |
1616
|----------------------------+-----------------------------------------------------------+------+--------+-------+------------------------------------------------------------------------------------------|
17-
| _quorum | struct Quorum | 102 | 0 | 32 | src/unaudited/examples/ECDSAStakeRegistryPermissioned.sol:ECDSAStakeRegistryPermissioned |
17+
| _quorum | struct IECDSAStakeRegistryTypes.Quorum | 102 | 0 | 32 | src/unaudited/examples/ECDSAStakeRegistryPermissioned.sol:ECDSAStakeRegistryPermissioned |
1818
|----------------------------+-----------------------------------------------------------+------+--------+-------+------------------------------------------------------------------------------------------|
1919
| _minimumWeight | uint256 | 103 | 0 | 32 | src/unaudited/examples/ECDSAStakeRegistryPermissioned.sol:ECDSAStakeRegistryPermissioned |
2020
|----------------------------+-----------------------------------------------------------+------+--------+-------+------------------------------------------------------------------------------------------|

0 commit comments

Comments
 (0)