MCPcopy
hub / github.com/volcengine/OpenViking / exists

Method exists

openviking/session/session.py:468–474  ·  view source on GitHub ↗

Check whether this session already exists in storage.

(self)

Source from the content-addressed store, hash-verified

466 self._meta.pending_tokens = max(0, self._meta.pending_tokens)
467
468 async def exists(self) -> bool:
469 """Check whether this session already exists in storage."""
470 try:
471 await self._viking_fs.stat(self._session_uri, ctx=self.ctx)
472 return True
473 except Exception:
474 return False
475
476 async def ensure_exists(self) -> None:
477 """Materialize session root and messages file if missing."""

Callers 15

ensure_existsMethod · 0.95
_require_artifactMethod · 0.45
_build_web_studioFunction · 0.45
mainFunction · 0.45
check_embeddingFunction · 0.45
check_diskFunction · 0.45
_check_gguf_model_cachedFunction · 0.45

Calls 1

statMethod · 0.45

Tested by 3

iter_new_log_linesFunction · 0.36
mainFunction · 0.36
scan_expand_logFunction · 0.36