Skip to content

Add RPIP-79 proofless megapool staking - #1343

Draft
0xfornax wants to merge 8 commits into
masterfrom
rpip-79
Draft

0xfornax wants to merge 8 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

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

Impacted Packages Coverage Δ 🤖
github.com/rocket-pool/smartnode/bindings/megapool 0.09% (-0.01%) 👎
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/pdao 0.14% (+0.02%) 👍
github.com/rocket-pool/smartnode/rocketpool-cli/security 0.00% (ø)
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.48% (+0.02%) 👍
github.com/rocket-pool/smartnode/shared/services 0.96% (-0.04%) 👎
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/megapool-contract.go 0.00% (ø) 6034 (+721) 0 6034 (+721)
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.43% (-0.29%) 4235 (+1734) 18 4217 (+1734) 👎
github.com/rocket-pool/smartnode/bindings/megapool/proof-bundle.go 0.00% (ø) 514 (+22) 0 514 (+22)
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/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/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/node.go 0.00% (ø) 11779 (+869) 0 11779 (+869)
github.com/rocket-pool/smartnode/rocketpool/node/stake-megapool-validator.go 0.38% (+0.38%) 7696 (+3993) 29 (+29) 7667 (+3964) 👍
github.com/rocket-pool/smartnode/rocketpool/node/validate-prestaked-validators.go 0.86% (+0.86%) 7659 (+7659) 66 (+66) 7593 (+7593) 👍
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/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

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