Skip to content

Add RPIP-79 proofless megapool staking - #1343

Open
0xfornax wants to merge 20 commits into
masterfrom
rpip-79
Open

0xfornax wants to merge 20 commits into
masterfrom
rpip-79

Conversation

@0xfornax

Copy link
Copy Markdown
Member

After Saturn 2, nodes can stake a prestaked megapool validator without a beacon-state proof once megapool.stake.without.proof.enabled is set and the challenge period has elapsed.
A new node task was created to challenge a prestaked validator whose withdrawal credentials are invalid using pending-deposit proofs. It will also challenge a validator with an invalid signature.

@github-actions

Copy link
Copy Markdown

Coverage Report

@github-actions

Copy link
Copy Markdown

Coverage Report

@github-actions

Copy link
Copy Markdown

Coverage Report

@github-actions

Copy link
Copy Markdown

Coverage Report

@github-actions

Copy link
Copy Markdown

Coverage Report

@github-actions

Copy link
Copy Markdown

Coverage Report

@github-actions

Copy link
Copy Markdown

Coverage Report

@github-actions

Copy link
Copy Markdown

Merging this branch changes the coverage (11 decrease, 3 increase)

Impacted Packages Coverage Δ 🤖
github.com/rocket-pool/smartnode/bindings/megapool 0.09% (-0.01%) 👎
github.com/rocket-pool/smartnode/bindings/node 0.00% (ø)
github.com/rocket-pool/smartnode/bindings/settings/protocol 0.18% (-0.00%) 👎
github.com/rocket-pool/smartnode/bindings/settings/security 0.00% (ø)
github.com/rocket-pool/smartnode/rocketpool-cli/cli 0.71% (+0.07%) 👍
github.com/rocket-pool/smartnode/rocketpool-cli/megapool 0.05% (-0.00%) 👎
github.com/rocket-pool/smartnode/rocketpool-cli/pdao 0.14% (+0.02%) 👍
github.com/rocket-pool/smartnode/rocketpool-cli/security 0.00% (ø)
github.com/rocket-pool/smartnode/rocketpool/api/megapool 0.34% (-0.02%) 👎
github.com/rocket-pool/smartnode/rocketpool/api/pdao 0.08% (-0.00%) 👎
github.com/rocket-pool/smartnode/rocketpool/api/security 0.12% (-0.01%) 👎
github.com/rocket-pool/smartnode/rocketpool/node 0.49% (+0.02%) 👍
github.com/rocket-pool/smartnode/shared/services 0.96% (-0.04%) 👎
github.com/rocket-pool/smartnode/shared/services/rocketpool 0.49% (-0.03%) 👎
github.com/rocket-pool/smartnode/shared/types/api 2.63% (-0.22%) 👎
github.com/rocket-pool/smartnode/shared/types/eth2 1.43% (-0.08%) 👎
github.com/rocket-pool/smartnode/shared/types/eth2/fork/electra 0.00% (+0.00%) 👍
github.com/rocket-pool/smartnode/shared/types/eth2/fork/fulu 0.99% (-0.02%) 👎
github.com/rocket-pool/smartnode/shared/types/eth2/fork/gloas 1.34% (-0.05%) 👎
github.com/rocket-pool/smartnode/shared/types/eth2/generic 1.58% (-0.05%) 👎

Coverage by file

Changed files (no unit tests)

Changed File Coverage Δ Total Covered Missed 🤖
github.com/rocket-pool/smartnode/bindings/megapool/factory.go 0.00% (ø) 544 0 544
github.com/rocket-pool/smartnode/bindings/megapool/megapool-contract-v2.go 0.00% (ø) 216 0 216
github.com/rocket-pool/smartnode/bindings/megapool/megapool-contract.go 0.00% (ø) 5615 (+302) 0 5615 (+302)
github.com/rocket-pool/smartnode/bindings/megapool/megapool-interface.go 0.00% (ø) 0 0 0
github.com/rocket-pool/smartnode/bindings/megapool/megapool-manager.go 0.49% (-0.23%) 3687 (+1186) 18 3669 (+1186) 👎
github.com/rocket-pool/smartnode/bindings/megapool/proof-bundle.go 0.00% (ø) 514 (+22) 0 514 (+22)
github.com/rocket-pool/smartnode/bindings/node/node.go 0.00% (ø) 9542 (+256) 0 9542 (+256)
github.com/rocket-pool/smartnode/bindings/settings/protocol/megapool.go 0.00% (ø) 1924 (+346) 0 1924 (+346)
github.com/rocket-pool/smartnode/bindings/settings/protocol/setting-types.go 8.98% (ø) 401 36 365
github.com/rocket-pool/smartnode/bindings/settings/security/megapool.go 0.00% (ø) 4 (+4) 0 4 (+4)
github.com/rocket-pool/smartnode/rocketpool-cli/cli/saturn2-check.go 0.00% (ø) 587 (+104) 0 587 (+104)
github.com/rocket-pool/smartnode/rocketpool-cli/megapool/commands.go 0.00% (ø) 4432 (+340) 0 4432 (+340)
github.com/rocket-pool/smartnode/rocketpool-cli/megapool/deploy.go 0.00% (ø) 1056 (+1056) 0 1056 (+1056)
github.com/rocket-pool/smartnode/rocketpool-cli/megapool/status.go 0.00% (ø) 6298 (+473) 0 6298 (+473)
github.com/rocket-pool/smartnode/rocketpool-cli/pdao/commands.go 0.11% (+0.06%) 23733 (+1678) 25 (+16) 23708 (+1662) 👍
github.com/rocket-pool/smartnode/rocketpool-cli/pdao/get-settings.go 0.00% (ø) 4872 (+326) 0 4872 (+326)
github.com/rocket-pool/smartnode/rocketpool-cli/pdao/propose-settings.go 0.20% (+0.09%) 8155 (+574) 16 (+8) 8139 (+566) 👍
github.com/rocket-pool/smartnode/rocketpool-cli/security/commands.go 0.00% (ø) 5595 (+509) 0 5595 (+509)
github.com/rocket-pool/smartnode/rocketpool-cli/security/propose-settings.go 0.00% (ø) 2254 (+190) 0 2254 (+190)
github.com/rocket-pool/smartnode/rocketpool/api/megapool/deploy.go 0.00% (ø) 1881 (+1881) 0 1881 (+1881)
github.com/rocket-pool/smartnode/rocketpool/api/megapool/routes.go 4.77% (-0.26%) 1845 (+174) 88 (+4) 1757 (+170) 👎
github.com/rocket-pool/smartnode/rocketpool/api/pdao/get-settings.go 0.00% (ø) 15121 (+1078) 0 15121 (+1078)
github.com/rocket-pool/smartnode/rocketpool/api/pdao/propose-settings.go 0.00% (ø) 45772 (+3286) 0 45772 (+3286)
github.com/rocket-pool/smartnode/rocketpool/api/security/propose-settings.go 0.00% (ø) 9630 (+1010) 0 9630 (+1010)
github.com/rocket-pool/smartnode/rocketpool/node/check-megapool-exit-requests.go 0.00% (ø) 7251 (+415) 0 7251 (+415)
github.com/rocket-pool/smartnode/rocketpool/node/check-minipool-exit-requests.go 0.00% (ø) 7281 (+417) 0 7281 (+417)
github.com/rocket-pool/smartnode/rocketpool/node/node.go 0.00% (ø) 11779 (+869) 0 11779 (+869)
github.com/rocket-pool/smartnode/rocketpool/node/stake-megapool-validator.go 0.44% (+0.44%) 9035 (+5332) 40 (+40) 8995 (+5292) 👍
github.com/rocket-pool/smartnode/rocketpool/node/validate-prestaked-validators.go 0.76% (+0.76%) 10536 (+10536) 80 (+80) 10456 (+10456) 👍
github.com/rocket-pool/smartnode/shared/services/megapools.go 1.05% (-0.03%) 33685 (+2498) 353 (+16) 33332 (+2482) 👎
github.com/rocket-pool/smartnode/shared/services/rocketpool/megapool.go 0.00% (ø) 2897 (+224) 0 2897 (+224)
github.com/rocket-pool/smartnode/shared/types/api/megapool.go 0.00% (ø) 0 0 0
github.com/rocket-pool/smartnode/shared/types/api/pdao.go 0.00% (ø) 0 0 0
github.com/rocket-pool/smartnode/shared/types/eth2/fork/electra/state_electra.go 0.04% (+0.04%) 5440 (+216) 2 (+2) 5438 (+214) 👍
github.com/rocket-pool/smartnode/shared/types/eth2/fork/fulu/state_fulu.go 3.68% (-0.11%) 6362 (+240) 234 (+2) 6128 (+238) 👎
github.com/rocket-pool/smartnode/shared/types/eth2/fork/gloas/state_gloas.go 3.19% (-0.03%) 9002 (+2031) 287 (+63) 8715 (+1968) 👎
github.com/rocket-pool/smartnode/shared/types/eth2/generic/state.go 7.89% (-0.44%) 38 (+2) 3 35 (+2) 👎
github.com/rocket-pool/smartnode/shared/types/eth2/types.go 1.43% (-0.08%) 1955 (+102) 28 1927 (+102) 👎

Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code.

Changed unit test files

  • github.com/rocket-pool/smartnode/bindings/megapool/megapool-manager_test.go
  • github.com/rocket-pool/smartnode/bindings/megapool/proof-bundle_test.go
  • github.com/rocket-pool/smartnode/bindings/megapool/proofless_stake_abi_test.go
  • github.com/rocket-pool/smartnode/rocketpool-cli/pdao/propose-settings-json_test.go
  • github.com/rocket-pool/smartnode/rocketpool/node/stake-megapool-validator_test.go
  • github.com/rocket-pool/smartnode/rocketpool/node/validate-prestaked-validators_test.go
  • github.com/rocket-pool/smartnode/shared/types/eth2/fork/electra/pending_deposit_proof_test.go
  • github.com/rocket-pool/smartnode/shared/types/eth2/fork/fulu/pending_deposit_proof_test.go
  • github.com/rocket-pool/smartnode/shared/types/eth2/fork/gloas/gloas_proofs_test.go

@0xfornax
0xfornax marked this pull request as ready for review November 19, 2026 16:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant