How to query based on Block-Height and listen to new Block/Transaction events | Also Sockets-API

The issue seems to me relating to the some wrong Unicode encoding in hte explorer.

I debugged a bit and the result from explorer is

	�0{"pingInterval":25000,"pingTimeout":60000,"upgrades":["websocket"],"sid":"PR0kCDESAAQwORQULxk0"}"

instead of

97:0{"pingInterval":25000,"pingTimeout":60000,"upgrades":["websocket"],"sid":"PR0kCDESAAQwORQULxk0"}.  

The first few bytes are 00 09 07 ef bf bd instead of “97:”, the EFBFBD is the UTF8 for the Unicode’s invalid character FFFD , means that the explorer somewhy could not build the proper string. The 00 09 07 is CBOR representation of 0 9 7, the length of the payload, the string w/ the curly brackets. The 0 before the “{” means type is connet.

2 Likes