@xyo-network/diviner-temporal-indexing-memory 5.1.3 → 5.1.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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xyo-network/diviner-temporal-indexing-memory",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.5",
|
|
4
4
|
"description": "Primary SDK for using XYO Protocol 2.0",
|
|
5
5
|
"homepage": "https://xyo.network",
|
|
6
6
|
"bugs": {
|
|
@@ -36,41 +36,41 @@
|
|
|
36
36
|
"@xylabs/array": "~5.0.11",
|
|
37
37
|
"@xylabs/assert": "~5.0.11",
|
|
38
38
|
"@xylabs/exists": "~5.0.11",
|
|
39
|
-
"@xyo-network/archivist-model": "~5.1.
|
|
40
|
-
"@xyo-network/archivist-wrapper": "~5.1.
|
|
41
|
-
"@xyo-network/boundwitness-model": "~5.1.
|
|
42
|
-
"@xyo-network/boundwitness-validator": "~5.1.
|
|
43
|
-
"@xyo-network/diviner-abstract": "~5.1.
|
|
44
|
-
"@xyo-network/diviner-boundwitness-abstract": "~5.1.
|
|
45
|
-
"@xyo-network/diviner-boundwitness-model": "~5.1.
|
|
46
|
-
"@xyo-network/diviner-indexing-memory": "~5.1.
|
|
47
|
-
"@xyo-network/diviner-indexing-model": "~5.1.
|
|
48
|
-
"@xyo-network/diviner-jsonpath-aggregate-memory": "~5.1.
|
|
49
|
-
"@xyo-network/diviner-jsonpath-model": "~5.1.
|
|
50
|
-
"@xyo-network/diviner-model": "~5.1.
|
|
51
|
-
"@xyo-network/diviner-payload-model": "~5.1.
|
|
52
|
-
"@xyo-network/diviner-temporal-indexing-model": "~5.1.
|
|
53
|
-
"@xyo-network/diviner-wrapper": "~5.1.
|
|
54
|
-
"@xyo-network/module-model": "~5.1.
|
|
55
|
-
"@xyo-network/payload-builder": "~5.1.
|
|
56
|
-
"@xyo-network/payload-model": "~5.1.
|
|
57
|
-
"@xyo-network/payload-utils": "~5.1.
|
|
58
|
-
"@xyo-network/witness-timestamp": "~5.1.
|
|
39
|
+
"@xyo-network/archivist-model": "~5.1.5",
|
|
40
|
+
"@xyo-network/archivist-wrapper": "~5.1.5",
|
|
41
|
+
"@xyo-network/boundwitness-model": "~5.1.5",
|
|
42
|
+
"@xyo-network/boundwitness-validator": "~5.1.5",
|
|
43
|
+
"@xyo-network/diviner-abstract": "~5.1.5",
|
|
44
|
+
"@xyo-network/diviner-boundwitness-abstract": "~5.1.5",
|
|
45
|
+
"@xyo-network/diviner-boundwitness-model": "~5.1.5",
|
|
46
|
+
"@xyo-network/diviner-indexing-memory": "~5.1.5",
|
|
47
|
+
"@xyo-network/diviner-indexing-model": "~5.1.5",
|
|
48
|
+
"@xyo-network/diviner-jsonpath-aggregate-memory": "~5.1.5",
|
|
49
|
+
"@xyo-network/diviner-jsonpath-model": "~5.1.5",
|
|
50
|
+
"@xyo-network/diviner-model": "~5.1.5",
|
|
51
|
+
"@xyo-network/diviner-payload-model": "~5.1.5",
|
|
52
|
+
"@xyo-network/diviner-temporal-indexing-model": "~5.1.5",
|
|
53
|
+
"@xyo-network/diviner-wrapper": "~5.1.5",
|
|
54
|
+
"@xyo-network/module-model": "~5.1.5",
|
|
55
|
+
"@xyo-network/payload-builder": "~5.1.5",
|
|
56
|
+
"@xyo-network/payload-model": "~5.1.5",
|
|
57
|
+
"@xyo-network/payload-utils": "~5.1.5",
|
|
58
|
+
"@xyo-network/witness-timestamp": "~5.1.5"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
61
|
"@xylabs/delay": "~5.0.11",
|
|
62
62
|
"@xylabs/hex": "~5.0.11",
|
|
63
63
|
"@xylabs/object": "~5.0.11",
|
|
64
64
|
"@xylabs/promise": "~5.0.11",
|
|
65
|
-
"@xylabs/ts-scripts-yarn3": "~7.1.
|
|
66
|
-
"@xylabs/tsconfig": "~7.1.
|
|
65
|
+
"@xylabs/ts-scripts-yarn3": "~7.1.8",
|
|
66
|
+
"@xylabs/tsconfig": "~7.1.8",
|
|
67
67
|
"@xylabs/vitest-extended": "~5.0.11",
|
|
68
|
-
"@xyo-network/archivist-memory": "~5.1.
|
|
69
|
-
"@xyo-network/boundwitness-builder": "~5.1.
|
|
70
|
-
"@xyo-network/manifest": "~5.1.
|
|
71
|
-
"@xyo-network/module-factory-locator": "~5.1.
|
|
72
|
-
"@xyo-network/node-memory": "~5.1.
|
|
73
|
-
"@xyo-network/wallet": "~5.1.
|
|
68
|
+
"@xyo-network/archivist-memory": "~5.1.5",
|
|
69
|
+
"@xyo-network/boundwitness-builder": "~5.1.5",
|
|
70
|
+
"@xyo-network/manifest": "~5.1.5",
|
|
71
|
+
"@xyo-network/module-factory-locator": "~5.1.5",
|
|
72
|
+
"@xyo-network/node-memory": "~5.1.5",
|
|
73
|
+
"@xyo-network/wallet": "~5.1.5",
|
|
74
74
|
"typescript": "~5.9.2",
|
|
75
75
|
"vitest": "~3.2.4"
|
|
76
76
|
},
|
|
@@ -61,7 +61,7 @@ describe('TemporalIndexCandidateToImageThumbnailIndexDiviner', () => {
|
|
|
61
61
|
expect(result.filter(isTemporalIndexingDivinerResultIndex)).toBeArrayOfSize(1)
|
|
62
62
|
const index = result.find(isTemporalIndexingDivinerResultIndex)
|
|
63
63
|
// eslint-disable-next-line sonarjs/no-alphabetical-sort
|
|
64
|
-
expect(index?.$sources.
|
|
64
|
+
expect(index?.$sources.toSorted()).toEqual(Object.keys(payloadDictionary).toSorted())
|
|
65
65
|
expect(index?.timestamp).toBe(timestamp.timestamp)
|
|
66
66
|
expect((index as { url?: string })?.url).toBe(thumbnail.sourceUrl)
|
|
67
67
|
expect((index as { status?: number })?.status).toBe(thumbnail.http?.status)
|
|
@@ -161,7 +161,7 @@ describe('TemporalIndexCandidateToImageThumbnailIndexDiviner', () => {
|
|
|
161
161
|
expect(result.filter(isTemporalIndexingDivinerResultIndex)).toBeArrayOfSize(1)
|
|
162
162
|
const index = result.find(isTemporalIndexingDivinerResultIndex)
|
|
163
163
|
// eslint-disable-next-line sonarjs/no-alphabetical-sort
|
|
164
|
-
expect(index?.$sources.
|
|
164
|
+
expect(index?.$sources.toSorted()).toEqual(Object.keys(payloadDictionary).toSorted())
|
|
165
165
|
expect(index?.timestamp).toBe(timestamp.timestamp)
|
|
166
166
|
expect((index as { url?: string })?.url).toBe((payload as { sourceUrl?: string }).sourceUrl)
|
|
167
167
|
expect((index as { status?: number })?.status).toBe(thumbnail.http?.status)
|
|
@@ -129,7 +129,7 @@ describe('TemporalStateToIndexCandidateDiviner', () => {
|
|
|
129
129
|
expect(state).toBeDefined()
|
|
130
130
|
const last = filterAs(results, asOptionalStorageMeta)
|
|
131
131
|
.map(p => p as WithStorageMeta<Payload>)
|
|
132
|
-
.
|
|
132
|
+
.toSorted(PayloadBuilder.compareStorageMeta)
|
|
133
133
|
.at(-1)
|
|
134
134
|
expect(last).toBeDefined()
|
|
135
135
|
expect(state?.state.cursor).toBe(last?._sequence)
|
|
@@ -137,7 +137,7 @@ describe('TemporalStateToIndexCandidateDiviner', () => {
|
|
|
137
137
|
})
|
|
138
138
|
describe('with previous state', () => {
|
|
139
139
|
it.each([1, 2, 3])('returns next state and batch results', async (batch) => {
|
|
140
|
-
const all = (await archivist.all()).
|
|
140
|
+
const all = (await archivist.all()).toSorted(PayloadBuilder.compareStorageMeta)
|
|
141
141
|
const batchOffset = all.at((3 * batch) - 1)
|
|
142
142
|
expect(batchOffset).toBeDefined()
|
|
143
143
|
// Test across all offsets
|