MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / parse_graph_stats_response

Function parse_graph_stats_response

nodedb-client/src/remote/client/graph.rs:238–243  ·  view source on GitHub ↗

Parse a multi-row response from `SHOW GRAPH STATS` into a vec of `GraphStats`. Empty rows produce an empty vec. Column-shape mismatches are surfaced as errors — no silent fallbacks.

(
    columns: &[String],
    rows: &[Vec<nodedb_types::value::Value>],
)

Source from the content-addressed store, hash-verified

236/// `GraphStats`. Empty rows produce an empty vec. Column-shape mismatches
237/// are surfaced as errors — no silent fallbacks.
238pub(crate) fn parse_graph_stats_response(
239 columns: &[String],
240 rows: &[Vec<nodedb_types::value::Value>],
241) -> NodeDbResult<Vec<GraphStats>> {
242 GraphStats::parse_show_stats_response(columns, rows)
243}
244
245#[cfg(test)]
246mod tests {

Calls

no outgoing calls