MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / checkMemory

Function checkMemory

packages/cli/src/commands/doctor.ts:88–102  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

86}
87
88function checkMemory(): CheckResult {
89 const sys = getSystemMeta();
90 const availMb = getAvailableMemoryMb();
91 const totalGb = (sys.memory_total_mb / 1024).toFixed(1);
92 const availGb = (availMb / 1024).toFixed(1);
93
94 if (availMb < 2048) {
95 return {
96 ok: false,
97 detail: `${totalGb} GB total \u00B7 ${availGb} GB available`,
98 hint: "Low memory — renders may fail. Close other apps or increase RAM.",
99 };
100 }
101 return { ok: true, detail: `${totalGb} GB total \u00B7 ${availGb} GB available` };
102}
103
104function checkShm(): CheckResult {
105 const shmMb = getShmSizeMb();

Callers

nothing calls this directly

Calls 2

getSystemMetaFunction · 0.85
getAvailableMemoryMbFunction · 0.85

Tested by

no test coverage detected