@mastra/libsql 1.0.0-beta.4 → 1.0.0-beta.5
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/CHANGELOG.md +16 -0
- package/dist/index.cjs +10 -10
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +10 -10
- package/dist/index.js.map +1 -1
- package/dist/storage/domains/scores/index.d.ts +2 -2
- package/dist/storage/domains/scores/index.d.ts.map +1 -1
- package/dist/storage/index.d.ts +2 -2
- package/dist/storage/index.d.ts.map +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -2753,11 +2753,11 @@ var ScoresLibSQL = class extends ScoresStorage {
|
|
|
2753
2753
|
domain: ErrorDomain.STORAGE,
|
|
2754
2754
|
category: ErrorCategory.USER,
|
|
2755
2755
|
details: {
|
|
2756
|
-
scorer: score.scorer
|
|
2757
|
-
entityId: score.entityId,
|
|
2758
|
-
entityType: score.entityType,
|
|
2759
|
-
traceId: score.traceId
|
|
2760
|
-
spanId: score.spanId
|
|
2756
|
+
scorer: score.scorer?.id ?? "unknown",
|
|
2757
|
+
entityId: score.entityId ?? "unknown",
|
|
2758
|
+
entityType: score.entityType ?? "unknown",
|
|
2759
|
+
traceId: score.traceId ?? "",
|
|
2760
|
+
spanId: score.spanId ?? ""
|
|
2761
2761
|
}
|
|
2762
2762
|
},
|
|
2763
2763
|
error
|
|
@@ -2765,17 +2765,17 @@ var ScoresLibSQL = class extends ScoresStorage {
|
|
|
2765
2765
|
}
|
|
2766
2766
|
try {
|
|
2767
2767
|
const id = crypto.randomUUID();
|
|
2768
|
+
const now = /* @__PURE__ */ new Date();
|
|
2768
2769
|
await this.operations.insert({
|
|
2769
2770
|
tableName: TABLE_SCORERS,
|
|
2770
2771
|
record: {
|
|
2772
|
+
...parsedScore,
|
|
2771
2773
|
id,
|
|
2772
|
-
createdAt:
|
|
2773
|
-
updatedAt:
|
|
2774
|
-
...parsedScore
|
|
2774
|
+
createdAt: now.toISOString(),
|
|
2775
|
+
updatedAt: now.toISOString()
|
|
2775
2776
|
}
|
|
2776
2777
|
});
|
|
2777
|
-
|
|
2778
|
-
return { score: scoreFromDb };
|
|
2778
|
+
return { score: { ...parsedScore, id, createdAt: now, updatedAt: now } };
|
|
2779
2779
|
} catch (error) {
|
|
2780
2780
|
throw new MastraError(
|
|
2781
2781
|
{
|