-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement Fee Recipient: CLI flags and Calling Beacon API #10312
Merged
Merged
Changes from all commits
Commits
Show all changes
68 commits
Select commit
Hold shift + click to select a range
38b4212
send proposer data to config
james-prysm 0e1cabe
Merge branch 'develop' into fee-recipient
james-prysm b81afaa
wip implementation with file and url based config import
james-prysm f0e6270
improving logic on get validator index
james-prysm f368ec6
Merge branch 'develop' into fee-recipient
james-prysm 3ce8ab4
fix function
james-prysm 5e9d583
optimizing function for map and address bug
james-prysm 3b1c9f5
fixing log
james-prysm 3566a8b
Merge branch 'develop' into fee-recipient
james-prysm 6fdc281
update cache if it doesn't exist
james-prysm b03c3a6
Merge branch 'develop' into fee-recipient
james-prysm 6ba2897
Merge branch 'develop' into fee-recipient
james-prysm c675514
updating flags
james-prysm 16098c5
initial unit test scaffold
james-prysm 8736e40
Merge branch 'develop' into fee-recipient
james-prysm 38864d2
fixing validator to call rpc call, removed temporary dependency
james-prysm ec87ea5
adding the API calls for the runner
james-prysm 089fc19
fixing broken build
james-prysm c3242c0
fixing deepsource
james-prysm f0b1db0
fixing interface
james-prysm a9ed460
fixing fatal
james-prysm 7a81615
fixing more deepsource issues
james-prysm 29826cd
adding test placeholders
james-prysm a880c64
updating proposer config to add validation
james-prysm 6d78340
Merge branch 'develop' into fee-recipient
james-prysm 38cf604
changing how if statement throws error
james-prysm bd62186
removing unneeded validation, validating in a different way
james-prysm 511cc8d
wip improving tests
james-prysm 6b88e7b
more unit test work
james-prysm 6acc746
fixing unit test
james-prysm a71622e
fixing unit tests and edge cases
james-prysm 7d97970
Merge branch 'develop' into fee-recipient
james-prysm fa1f0cd
Merge branch 'develop' into fee-recipient
james-prysm da65f45
adding unit tests and adjusting how the config is created
james-prysm a91df04
Merge branch 'develop' into fee-recipient
james-prysm 3c32213
fixing bazel builds
james-prysm 8310e55
fixing proto generation
james-prysm 460bea6
Merge branch 'develop' into fee-recipient
james-prysm ae88f51
fixing imports
james-prysm c5276d5
fixing unit tests
james-prysm a5fca40
Update cmd/validator/flags/flags.go
james-prysm 3cc4f17
updating flags based on comments, fixing unit tests
james-prysm 6c3445d
fixing bazel
james-prysm 1450190
removing unneeded function
james-prysm 35e4a41
fixing unit tests
james-prysm c549219
Merge branch 'develop' into fee-recipient
james-prysm 6d67832
refactors and unit test fixes based on comments
james-prysm b02cb93
fixing bazel build
james-prysm acf7ea1
refactor the cache out fo the fee recipient function
james-prysm 661cf01
adding usecase for multiple fee recipient
james-prysm 962ceeb
refactor burn name
james-prysm 96b5773
Update validator/client/validator.go
james-prysm 4a6340e
Update validator/client/validator.go
james-prysm b2b20b7
Update validator/client/validator.go
james-prysm 6a14d50
fixing bug with validator index based on code review
james-prysm b744e70
edited flag descriptions to better communicate usage
james-prysm 5a8861f
fixing manual reference to flag name
james-prysm 5e71149
Merge branch 'develop' into fee-recipient
james-prysm 9a1e20a
fixing code review comments
james-prysm 4463783
fixing linting
james-prysm 000f385
Update validator/client/validator.go
james-prysm b40ea0a
addressing comments and renaming functions
james-prysm d243449
fixing linting
james-prysm dd41a61
Update cmd/validator/flags/flags.go
rauljordan eed1068
Update cmd/validator/flags/flags.go
rauljordan 1cc55ca
Update cmd/validator/flags/flags.go
rauljordan 513b12e
Merge branch 'develop' into fee-recipient
rauljordan 3818f16
improving comments
james-prysm File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
load("@prysm//tools/go:def.bzl", "go_library") | ||
|
||
go_library( | ||
name = "go_default_library", | ||
srcs = ["fee-recipient-config.go"], | ||
importpath = "github.com/prysmaticlabs/prysm/config/validator/service", | ||
visibility = ["//visibility:public"], | ||
deps = [ | ||
"//config/fieldparams:go_default_library", | ||
"@com_github_ethereum_go_ethereum//common:go_default_library", | ||
], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
package validator_service_config | ||
|
||
import ( | ||
"github.com/ethereum/go-ethereum/common" | ||
field_params "github.com/prysmaticlabs/prysm/config/fieldparams" | ||
) | ||
|
||
// FeeRecipientFileConfig is the struct representation of the JSON config file set in the validator through the CLI. | ||
// ProposeConfig is the map of validator address to fee recipient options all in hex format. | ||
// DefaultConfig is the default fee recipient address for all validators unless otherwise specified in the propose config.required. | ||
type FeeRecipientFileConfig struct { | ||
ProposeConfig map[string]*FeeRecipientFileOptions `json:"proposer_config"` | ||
DefaultConfig *FeeRecipientFileOptions `json:"default_config"` | ||
} | ||
|
||
// FeeRecipientFileOptions is the struct representation of the JSON config file set in the validator through the CLI. | ||
// FeeRecipient is set to an eth address in hex string format with 0x prefix. | ||
type FeeRecipientFileOptions struct { | ||
FeeRecipient string `json:"fee_recipient"` | ||
} | ||
|
||
// FeeRecipientConfig is a Prysm internal representation of the fee recipient config on the validator client. | ||
// FeeRecipientFileConfig maps to FeeRecipientConfig on import through the CLI. | ||
type FeeRecipientConfig struct { | ||
ProposeConfig map[[field_params.BLSPubkeyLength]byte]*FeeRecipientOptions | ||
DefaultConfig *FeeRecipientOptions | ||
} | ||
|
||
// FeeRecipientOptions is a Prysm internal representation of the FeeRecipientFileOptions on the validator client in bytes format instead of hex. | ||
type FeeRecipientOptions struct { | ||
FeeRecipient common.Address | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add comments to these structs about how they are used