You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sorry if I am missing some page on issue guidelines or something. I looked around a bit but couldn't find one. Here is the TL;DR
Description
When running Ethereumex.HttpClient.web3_client_version() against an Anvil node, Anvil will respond with missing Content-Type header. It seems that somewhere along the way the library drops that header from this request at least. I know this because you can make this call Ethereumex.HttpClient.web3_client_version(http_headers: [{"Content-Type", "application/json"}]) and Anvil accepts the request. Since this request is a POST, and you are POSTing JSON, it seems appropriate to add the Content-Type header to the HTTP Request. Other RPCs like Alchemy happen to be a bit more lenient.
Sorry if I am missing some page on issue guidelines or something. I looked around a bit but couldn't find one. Here is the TL;DR
Description
When running
Ethereumex.HttpClient.web3_client_version()
against an Anvil node, Anvil will respond with missing Content-Type header. It seems that somewhere along the way the library drops that header from this request at least. I know this because you can make this callEthereumex.HttpClient.web3_client_version(http_headers: [{"Content-Type", "application/json"}])
and Anvil accepts the request. Since this request is a POST, and you are POSTing JSON, it seems appropriate to add the Content-Type header to the HTTP Request. Other RPCs like Alchemy happen to be a bit more lenient.Reference:
The text was updated successfully, but these errors were encountered: