@mastra/lance 1.0.0-beta.5 → 1.0.0-beta.7

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/index.js CHANGED
@@ -1643,6 +1643,23 @@ var StoreWorkflowsLance = class extends WorkflowsStorage {
1643
1643
  );
1644
1644
  }
1645
1645
  }
1646
+ async deleteWorkflowRunById({ runId, workflowName }) {
1647
+ try {
1648
+ const table = await this.client.openTable(TABLE_WORKFLOW_SNAPSHOT);
1649
+ const whereClause = `run_id = '${runId.replace(/'/g, "''")}' AND workflow_name = '${workflowName.replace(/'/g, "''")}'`;
1650
+ await table.delete(whereClause);
1651
+ } catch (error) {
1652
+ throw new MastraError(
1653
+ {
1654
+ id: createStorageErrorId("LANCE", "DELETE_WORKFLOW_RUN_BY_ID", "FAILED"),
1655
+ domain: ErrorDomain.STORAGE,
1656
+ category: ErrorCategory.THIRD_PARTY,
1657
+ details: { runId, workflowName }
1658
+ },
1659
+ error
1660
+ );
1661
+ }
1662
+ }
1646
1663
  async listWorkflowRuns(args) {
1647
1664
  try {
1648
1665
  const table = await this.client.openTable(TABLE_WORKFLOW_SNAPSHOT);
@@ -1915,6 +1932,9 @@ var LanceStorage = class _LanceStorage extends MastraStorage {
1915
1932
  async getWorkflowRunById(args) {
1916
1933
  return this.stores.workflows.getWorkflowRunById(args);
1917
1934
  }
1935
+ async deleteWorkflowRunById({ runId, workflowName }) {
1936
+ return this.stores.workflows.deleteWorkflowRunById({ runId, workflowName });
1937
+ }
1918
1938
  async updateWorkflowResults({
1919
1939
  workflowName,
1920
1940
  runId,