MCPcopy Create free account
hub / github.com/ByBrawe/opencode-loop / staleActiveRun

Function staleActiveRun

src/index.js:801–808  ·  view source on GitHub ↗
(sessionID)

Source from the content-addressed store, hash-verified

799 }
800}
801function orderedSessionMessages(messages) {
802 return (messages || []).map((message, index) => {
803 const info = message?.info || message || {};
804 const created = Number(info?.time?.created || 0);
805 return { message, index, created: Number.isFinite(created) ? created : 0 };
806 }).sort((a, b) => a.created - b.created || a.index - b.index).map((entry) => entry.message);
807}
808function assistantMessageHasMeaningfulActivity(message) {
809 const parts = Array.isArray(message?.parts) ? message.parts : [];
810 for (const part of parts) {
811 if (!part || typeof part !== "object")

Callers 1

sessionStatusTypeFunction · 0.85

Calls 1

nowFunction · 0.85

Tested by

no test coverage detected