Closed pquentin closed 7 months ago
The documented way to call perform_request on a node is to expect a tuple in response, Tuple[ApiResponseMeta, bytes]. But the actual underlying type is TransportApiResponse:
perform_request
Tuple[ApiResponseMeta, bytes]
TransportApiResponse
class TransportApiResponse(NamedTuple): meta: ApiResponseMeta body: Any
As pointed out by @ywangd, It would make sense to expose it alongside other responses types and change the Nodes docs page to use it.
Opened a PR here. I have some linting issues it seems. Should I be using Black for formatting?
I figured out the formatting issues!
The documented way to call
perform_request
on a node is to expect a tuple in response,Tuple[ApiResponseMeta, bytes]
. But the actual underlying type isTransportApiResponse
:As pointed out by @ywangd, It would make sense to expose it alongside other responses types and change the Nodes docs page to use it.