node-info, WebSocket-start, and WebSocket-stop endpoints diverge from the documented example output, parameter typing, and success semantics
Author: BenWhite713Created Aug 16, 2026Updated Sep 11, 2026
Labelstype:bug
1. admin_nodeInfo: admin_nodeInfo no longer populates protocols.eth.difficulty, leaving the documented fixed difficulty example unproducible
- Statement:
admin_nodeInfono longer populatesprotocols.eth.difficulty, leaving the documented fixed difficulty example unproducible. - URL: https://geth.ethereum.org/docs/interacting-with-geth/rpc/ns-admin
- Code location:
- Description: Root cause —
adminAPI.NodeInfosimply forwards toServer.NodeInfo(), which buildsinfo.Protocolsgenerically by calling each registered protocol'sNodeInfo()callback (proto.NodeInfo()) and storing whatever value that callback returns, or the literal string"unknown"if the protocol registered no callback. Whether anethprotocol handler still reports adifficultyfield is entirely up to that handler's ownNodeInfoimplementation; post-merge chains have no meaningful proof-of-work difficulty to report, so the field is no longer populated, making the documentation's fixed example value (17179869184) unreproducible on current networks. - Method:
admin_nodeInfo
2. admin_startWS: admin_startWS uses a *int port decoded from a JSON number, not the documented *rpc.HexNumber quantity
- Statement:
admin_startWSuses a*intport decoded from a JSON number, not the documented*rpc.HexNumberquantity. - URL: https://geth.ethereum.org/docs/interacting-with-geth/rpc/ns-admin
- Code location:
- Description: Root cause —
adminAPI.StartWS(host *string, port *int, allowedOrigins *string, apis *string)declaresportas a plain*int, which the standard JSON-RPC codec decodes from an ordinary JSON number (and defaults toapi.node.config.WSPortwhen omitted); no*rpc.HexNumbertype — a hex-string-decoding wrapper used elsewhere in the legacy RPC layer — appears anywhere in this handler's signature or in thewsServerForPortlookup that consumes the resolved port. The documented hex-quantity type therefore describes a decoding rule this parameter does not follow. - Method:
admin_startWS
3. admin_stopWS: admin_stopWS returns true after invoking stop routines even when no WebSocket endpoint was actually closed
- Statement:
admin_stopWSreturnstrueafter invoking stop routines even when no WebSocket endpoint was actually closed. - URL: https://geth.ethereum.org/docs/interacting-with-geth/rpc/ns-admin
- Code location:
- Description: Root cause —
adminAPI.StopWSunconditionally callsapi.node.http.stopWS()andapi.node.ws.stop()and thenreturn true, nil, without inspecting either call's return value or otherwise checking whether a WebSocket listener was actually running and got closed; the underlyingstop()implementations themselves treat "not running" as a no-op success (if is.listener == nil { return nil }), so there is no signal anywhere in the chain that would makeStopWSreport anything other than unconditional success, even when there was nothing to stop. - Method:
admin_stopWS
Source: ethereum/go-ethereum