Skip to content

Return the decode error from the remote web3signer client's response unmarshalling - #17321

Open
syjn99 wants to merge 1 commit into
developfrom
fix/unmarshalResponse-web3signer
Open

Return the decode error from the remote web3signer client's response unmarshalling#17321
syjn99 wants to merge 1 commit into
developfrom
fix/unmarshalResponse-web3signer

Conversation

@syjn99

@syjn99 syjn99 commented Aug 7, 2026

Copy link
Copy Markdown
Member

What type of PR is this?

Bug fix

What does this PR do? Why is it needed?

In unmarshalResponse, err is shadowed so errors.Wrap(err, ...) at line 199 returns nil, nil. It's interesting that this bug also surfaces what TestKeymanager_Sign test configuration, as PublicKeysURL (example2.com) actually responds with malformed JSON. See the additional comment.

Which issue(s) does this PR fix?

N/A

Other notes for review

Regression test is included.

Acknowledgements

  • I have read CONTRIBUTING.md.
  • I have included a uniquely named changelog fragment file.
  • I have added a description with sufficient context for reviewers to understand this PR.
  • I have tested that my changes work as expected and I added a testing plan to the PR description (if applicable).

config := &SetupConfig{
BaseEndpoint: "http://example.com",
GenesisValidatorsRoot: root,
PublicKeysURL: "http://example2.com/api/v1/eth2/publicKeys",

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No PublicKeysURL: Sign only needs the mocked client, and a real URL would hit the network.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant