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
Unmarshal received message failed: json: cannot unmarshal object into Go struct field response.error of type string
The reason for that is that ElectrumX, Fulcrum, and Electrs/Esplora are inconsistent when it comes to the error response format.
Please see the examples (for Bitcoin Testnet servers):
The client handles correctly only the response returned by the Electrs/Esplora server, as only this response format can be unmarshaled to the response struct that assumes a string as an error:
Responses unmarshaling don't work for errors returned by ElectrumX and Fulcrum servers.
I called the
GetBlockHeader
function with a block height that doesn't exist.go-electrum/electrum/block.go
Line 27 in b862ac4
I observed the following error being returned:
The reason for that is that ElectrumX, Fulcrum, and Electrs/Esplora are inconsistent when it comes to the error response format.
Please see the examples (for Bitcoin Testnet servers):
ElectrumX
Fulcrum
Electrs/Esplora
The client handles correctly only the response returned by the Electrs/Esplora server, as only this response format can be unmarshaled to the
response
struct that assumes astring
as anerror
:go-electrum/electrum/network.go
Lines 124 to 128 in b862ac4
The text was updated successfully, but these errors were encountered: