@mastra/libsql 1.23.1-alpha.1 → 1.23.1-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/docs/references/docs-memory-message-history.md +37 -0
- package/dist/docs/references/integrations-channels-github.md +6 -2
- package/dist/docs/references/reference-memory-memory-class.md +1 -1
- package/dist/index.cjs +5 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -1
- package/dist/index.js.map +1 -1
- package/dist/storage/domains/workflows/index.d.ts +1 -1
- package/dist/storage/domains/workflows/index.d.ts.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -13502,7 +13502,7 @@ var WorkflowsLibSQL = class WorkflowsLibSQL extends WorkflowsStorage {
|
|
|
13502
13502
|
}
|
|
13503
13503
|
}, "deleteWorkflowRunById");
|
|
13504
13504
|
}
|
|
13505
|
-
async listWorkflowRuns({ workflowName, fromDate, toDate, page, perPage, resourceId, status } = {}) {
|
|
13505
|
+
async listWorkflowRuns({ workflowName, fromDate, toDate, page, perPage, resourceId, threadId, status } = {}) {
|
|
13506
13506
|
try {
|
|
13507
13507
|
const conditions = [];
|
|
13508
13508
|
const args = [];
|
|
@@ -13526,6 +13526,10 @@ var WorkflowsLibSQL = class WorkflowsLibSQL extends WorkflowsStorage {
|
|
|
13526
13526
|
conditions.push("resourceId = ?");
|
|
13527
13527
|
args.push(resourceId);
|
|
13528
13528
|
} else this.logger.warn(`[${TABLE_WORKFLOW_SNAPSHOT}] resourceId column not found. Skipping resourceId filter.`);
|
|
13529
|
+
if (threadId) {
|
|
13530
|
+
conditions.push(`(EXISTS (SELECT 1 FROM json_each(snapshot, '$.context') AS je WHERE json_extract(je.value, '$.status') = 'suspended' AND json_extract(je.value, '$.suspendPayload.__streamState.messageList.memoryInfo.threadId') = ?) OR json_extract(snapshot, '$.context.input.messageListState.memoryInfo.threadId') = ?)`);
|
|
13531
|
+
args.push(threadId, threadId);
|
|
13532
|
+
}
|
|
13529
13533
|
const whereClause = conditions.length > 0 ? `WHERE ${conditions.join(" AND ")}` : "";
|
|
13530
13534
|
let total = 0;
|
|
13531
13535
|
const usePagination = typeof perPage === "number" && typeof page === "number";
|