Skip to content

docs: add ports to RPCs #1585

Closed as not planned
Closed as not planned
@jcstein

Description

@jcstein

Problem

There is a split between docs (specifically, the ports used on RPCs), the way you specify a node with celestia-appd, and the way RPC providers host their nodes.

Querying RPC endpoints listed in documentation leads to inconsistent results on celestia-app releases v1.9, v1.10, and v2.0.0rc1:

$ celestia-appd query block --node https://celestia-rpc.brightlystake.com:26657

Error: post failed: Post "https://celestia-rpc.brightlystake.com:26657": dial tcp 65.108.238.167:26657: connect: operation timed out

More examples

With port:

$ celestia-appd query block --node http://rpc.celestia.nodestake.top:26657

Error: post failed: Post "http://rpc.celestia.nodestake.top:26657": dial tcp 44.212.8.160:26657: connect: connection refused

Without port:

$ celestia-appd query block --node http://rpc.celestia.nodestake.top

Error: post failed: Post "http://rpc.celestia.nodestake.top": dial tcp: address rpc.celestia.nodestake.top: missing port in address

another RPC:

$ celestia-appd query block --node http://celestia-rpc.chainode.tech:33373

Error: error in json rpc client, with http response metadata: (Status: 400 Bad Request, Protocol HTTP/1.1). error unmarshalling: invalid character '<' looking for beginning of value
$ celestia-appd query block --node http://rpc-celestia-full.avril14th.org:26657 | jq .

Error: post failed: Post "http://rpc-celestia-full.avril14th.org:26657": dial tcp 62.141.42.208:26657: connect: connection refused
$ celestia-appd query block --node http://rpc-celestia-full.avril14th.org:80 | jq .

Error: post failed: Post "https://rpc-celestia-full.avril14th.org/": http: server gave HTTP response to HTTPS client

Examples that do work

celestia-appd query block --node http://rpc-celestia.mzonder.com:26657

This works because 443 is the default https endpoint:

celestia-appd query block --node https://rpc-celestia-full.avril14th.org:443 | jq .
celestia-appd query block --node https://celestia-rpc.mesa.newmetric.xyz:443 | jq .block.header

Works on v1.10.1 but breaks on v1.9.x

$ celestia-appd query block --node --node http://rpc.celestia.pops.one:26657 | jq .block.header

on v1.9:

$ celestia-appd query block --node --node http://rpc.celestia.pops.one:26657 | jq .block.header

Error: strconv.Atoi: parsing "http://rpc.celestia.pops.one:26657": invalid syntax

Solution

  • Add ports as suffix to documentation (note: these will not all be the same)
  • add https as prefix to documentation
  • Require future RPCs added to docs to include this in their PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High PrioritydocumentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions