Skip to content
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

Add (lack of) REST implementation for GetFeeRecipientByPubKey #11991

Merged
merged 6 commits into from
Feb 24, 2023
Merged

Add (lack of) REST implementation for GetFeeRecipientByPubKey #11991

merged 6 commits into from
Feb 24, 2023

Conversation

nalepae
Copy link
Contributor

@nalepae nalepae commented Feb 14, 2023

What type of PR is this?

Feature

Related gitHub issue:

#11580

How other validator clients implementation deals with this issue: ethereum/keymanager-APIs#55

What does this PR do? Why is it needed?

This PR deals with the (lack of) implementation for the GetFeeRecipientByPubKey method in beacon API.

With gRPC implementation, if, for a given {pubkey}:

  • no {pubkey} specific fee recipient is set in validator client, AND
  • no default fee recipient is set in validator client, AND
  • the GetFeeRecipientByPubKey gRPC beacon API call responds on error, then:

Before this PR, the call to GET /eth/v1/validator/{pubkey}/feerecipient returns the burn address 0x0000....
After this PR the call to GET /eth/v1/validator/{pubkey}/feerecipient returns:

{
    "message": "Failed to retrieve default fee recipient from beacon node",
    "code": 500
}

With gRPC implementation, if, for a given {pubkey}:

  • no {pubkey} specific fee recipient is set in validator client, AND
  • no default fee recipient is set in validator client, AND
  • the GetFeeRecipientByPubKey gRPC beacon API call responds with a nil value or with an empty value, then:

Before this PR, the call to GET /eth/v1/validator/{pubkey}/feerecipient returns the burn address 0x0000....
After this PR the call to GET /eth/v1/validator/{pubkey}/feerecipient returns:

{
    "message": "No fee recipient set",
    "code": 400
}

With beacon API implementation, if, for a given {pubkey}:

  • no {pubkey} specific fee recipient is set in validator client, AND
  • no default fee recipient is set in validator client, then:

the call to GET /eth/v1/validator/{pubkey}/feerecipient returns:

{
    "message": "No fee recipient set",
    "code": 400
}

Warning:
The 400 and 500 code listed above will cause, in Prysm validator WebUI, the following error:

image

Edit:
After prysmaticlabs/prysm-web-ui#242:

image

@nalepae nalepae requested a review from a team as a code owner February 14, 2023 23:56
@nalepae nalepae changed the title Add (lack of) REST implementation for GetFeeRecipientByPubKey Add (lack of) REST implementation for GetFeeRecipientByPubKey Feb 14, 2023
@james-prysm james-prysm added the Blocked Blocked by research or external factors label Feb 16, 2023
@james-prysm
Copy link
Contributor

james-prysm commented Feb 16, 2023

Depends on web UI changes, will track those first and tie back to this PR

@james-prysm james-prysm removed the Blocked Blocked by research or external factors label Feb 23, 2023
@nalepae
Copy link
Contributor Author

nalepae commented Feb 24, 2023

After prysmaticlabs/prysm-web-ui#242:

image

@james-prysm james-prysm added OK to merge API Api related tasks and removed OK to merge labels Feb 24, 2023
@prylabs-bulldozer prylabs-bulldozer bot merged commit 08ebc99 into prysmaticlabs:develop Feb 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Api related tasks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants