MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / snapshot_fence

Function snapshot_fence

libatomic/src/daemon/sandbox_wire.rs:85–87  ·  view source on GitHub ↗

The effective state a snapshot fences on, base32 (what `Repository::insert_submitted_change` compares).

(snapshot: &pb::ViewSnapshot)

Source from the content-addressed store, hash-verified

83/// The effective state a snapshot fences on, base32 (what
84/// `Repository::insert_submitted_change` compares).
85pub fn snapshot_fence(snapshot: &pb::ViewSnapshot) -> Result<String, String> {
86 Ok(hash_from_proto(snapshot.effective_state.as_ref())?.to_base32())
87}
88
89/// A rendered entry as a [`pb::TreeEntry`]: the content rides inline.
90pub fn tree_entry_proto(entry: ViewEntry) -> pb::TreeEntry {

Callers 4

submitMethod · 0.85
fenceFunction · 0.85
submit_changeMethod · 0.85
submitMethod · 0.85

Calls 3

hash_from_protoFunction · 0.85
as_refMethod · 0.80
to_base32Method · 0.45

Tested by 1

submitMethod · 0.68