Skip to content

web3signer doesn't set appropriate headers to indicate that json is an acceptable response #5691

@lrusak

Description

@lrusak

Description

The web3signer doesn't set the applicable Accept header to indicate that application/json is an acceptable response.

the web3signer api indicates that both application/json and text/plain are acceptable response types for signing requests.

The web3signer handler in lighthouse requires a json response. Setting the header "Accept: application/json" indicates to the web3signer that json is an acceptable response.

The default header uses Accept: */* which means any response is acceptable.

Version

stable (v5.1.3)

Present Behaviour

Fail to deserialize response as json if the respnse return type is plain/text.

Expected Behaviour

Properly deserialize the json response

Steps to resolve

Set the correct header for the request.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions