MCPcopy Create free account
hub / github.com/ScriptedAlchemy/tracedecay / parse

Function parse

src/branch_meta.rs:125–127  ·  view source on GitHub ↗

Parses `branch-meta.json` content into [`BranchMeta`]. This is the canonical definition of "corrupt branch metadata": anything this rejects — invalid JSON *or* valid JSON with the wrong schema — makes the runtime fall back to single-DB mode. Every consumer (loading at runtime, quarantining in the post-update health pass) must go through this one predicate so they agree on what corrupt means.

(content: &str)

Source from the content-addressed store, hash-verified

123/// runtime, quarantining in the post-update health pass) must go through this
124/// one predicate so they agree on what corrupt means.
125pub fn parse(content: &str) -> serde_json::Result<BranchMeta> {
126 serde_json::from_str(content)
127}
128
129/// Loads branch metadata from `branch-meta.json` in the project data dir.
130///

Callers 15

parse_headerFunction · 0.70
parse_optional_numberFunction · 0.70
load_branch_metaFunction · 0.70
parse_optionalMethod · 0.50
extract_quintMethod · 0.50
extract_markdownMethod · 0.50
extract_leanMethod · 0.50
extract_tomlMethod · 0.50
parse_urlFunction · 0.50
parse_line_range_pairFunction · 0.50

Calls

no outgoing calls