MCPcopy Create free account
hub / github.com/AI45Lab/Code / load_artifacts

Method load_artifacts

core/src/store/file_store.rs:266–280  ·  view source on GitHub ↗
(&self, id: &str)

Source from the content-addressed store, hash-verified

264 }
265
266 async fn load_artifacts(&self, id: &str) -> Result<Option<ArtifactStore>> {
267 let artifact_dir = self.artifact_dir(id);
268 if !artifact_dir.exists() {
269 return Ok(None);
270 }
271
272 let artifacts = ArtifactStore::load_from_dir(&artifact_dir).with_context(|| {
273 format!(
274 "Failed to load artifacts for session {} from {}",
275 id,
276 artifact_dir.display()
277 )
278 })?;
279 Ok(Some(artifacts))
280 }
281
282 async fn save_trace_events(&self, id: &str, events: &[TraceEvent]) -> Result<()> {
283 let path = self.trace_path(id);

Callers 2

load_artifactsFunction · 0.45

Calls 3

artifact_dirMethod · 0.80
with_contextMethod · 0.80
existsMethod · 0.45

Tested by 1