@xyo-network/chain-api 1.7.19 → 1.7.20
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/chain-api",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.20",
|
|
4
4
|
"description": "XYO Layer One API",
|
|
5
5
|
"homepage": "https://xylabs.com",
|
|
6
6
|
"bugs": {
|
|
@@ -46,70 +46,70 @@
|
|
|
46
46
|
"types": "tsc --noEmit -p tsconfig.test.json"
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
|
-
"@opentelemetry/instrumentation": "
|
|
50
|
-
"@opentelemetry/instrumentation-express": "
|
|
51
|
-
"@opentelemetry/instrumentation-http": "
|
|
52
|
-
"@xylabs/assert": "
|
|
53
|
-
"@xylabs/creatable": "
|
|
54
|
-
"@xylabs/express": "
|
|
55
|
-
"@xylabs/hex": "
|
|
56
|
-
"@xylabs/logger": "
|
|
57
|
-
"@xylabs/mongo": "
|
|
58
|
-
"@xylabs/typeof": "
|
|
59
|
-
"@xyo-network/archivist-memory": "
|
|
60
|
-
"@xyo-network/archivist-model": "
|
|
61
|
-
"@xyo-network/archivist-mongodb": "
|
|
62
|
-
"@xyo-network/archivist-view": "
|
|
63
|
-
"@xyo-network/bios": "
|
|
64
|
-
"@xyo-network/boundwitness-model": "
|
|
65
|
-
"@xyo-network/chain-modules": "
|
|
66
|
-
"@xyo-network/chain-protocol": "
|
|
67
|
-
"@xyo-network/chain-rpc": "
|
|
68
|
-
"@xyo-network/chain-telemetry": "
|
|
69
|
-
"@xyo-network/manifest-model": "
|
|
70
|
-
"@xyo-network/manifest-wrapper": "
|
|
71
|
-
"@xyo-network/module-abstract": "
|
|
72
|
-
"@xyo-network/module-factory-locator": "
|
|
73
|
-
"@xyo-network/module-model": "
|
|
74
|
-
"@xyo-network/node-model": "
|
|
75
|
-
"@xyo-network/payload-builder": "
|
|
76
|
-
"@xyo-network/payload-model": "
|
|
77
|
-
"@xyo-network/sentinel-memory": "
|
|
78
|
-
"@xyo-network/wallet": "
|
|
79
|
-
"@xyo-network/wallet-model": "
|
|
80
|
-
"@xyo-network/xl1-protocol-sdk": "
|
|
81
|
-
"@xyo-network/xl1-rpc": "
|
|
82
|
-
"compression": "
|
|
83
|
-
"cors": "
|
|
84
|
-
"express": "
|
|
85
|
-
"http-status-codes": "
|
|
86
|
-
"mongodb": "
|
|
49
|
+
"@opentelemetry/instrumentation": "^0.203.0",
|
|
50
|
+
"@opentelemetry/instrumentation-express": "^0.52.0",
|
|
51
|
+
"@opentelemetry/instrumentation-http": "^0.203.0",
|
|
52
|
+
"@xylabs/assert": "^4.15.0",
|
|
53
|
+
"@xylabs/creatable": "^4.15.0",
|
|
54
|
+
"@xylabs/express": "^4.15.0",
|
|
55
|
+
"@xylabs/hex": "^4.15.0",
|
|
56
|
+
"@xylabs/logger": "^4.15.0",
|
|
57
|
+
"@xylabs/mongo": "^4.15.0",
|
|
58
|
+
"@xylabs/typeof": "^4.15.0",
|
|
59
|
+
"@xyo-network/archivist-memory": "^4.3.0",
|
|
60
|
+
"@xyo-network/archivist-model": "^4.3.0",
|
|
61
|
+
"@xyo-network/archivist-mongodb": "^4.3.0",
|
|
62
|
+
"@xyo-network/archivist-view": "^4.3.0",
|
|
63
|
+
"@xyo-network/bios": "^6.0.5",
|
|
64
|
+
"@xyo-network/boundwitness-model": "^4.3.0",
|
|
65
|
+
"@xyo-network/chain-modules": "^1.7.20",
|
|
66
|
+
"@xyo-network/chain-protocol": "^1.7.20",
|
|
67
|
+
"@xyo-network/chain-rpc": "^1.7.20",
|
|
68
|
+
"@xyo-network/chain-telemetry": "^1.7.20",
|
|
69
|
+
"@xyo-network/manifest-model": "^4.3.0",
|
|
70
|
+
"@xyo-network/manifest-wrapper": "^4.3.0",
|
|
71
|
+
"@xyo-network/module-abstract": "^4.3.0",
|
|
72
|
+
"@xyo-network/module-factory-locator": "^4.3.0",
|
|
73
|
+
"@xyo-network/module-model": "^4.3.0",
|
|
74
|
+
"@xyo-network/node-model": "^4.3.0",
|
|
75
|
+
"@xyo-network/payload-builder": "^4.3.0",
|
|
76
|
+
"@xyo-network/payload-model": "^4.3.0",
|
|
77
|
+
"@xyo-network/sentinel-memory": "^4.3.0",
|
|
78
|
+
"@xyo-network/wallet": "^4.3.0",
|
|
79
|
+
"@xyo-network/wallet-model": "^4.3.0",
|
|
80
|
+
"@xyo-network/xl1-protocol-sdk": "^1.7.20",
|
|
81
|
+
"@xyo-network/xl1-rpc": "^1.7.20",
|
|
82
|
+
"compression": "^1.8.1",
|
|
83
|
+
"cors": "^2.8.5",
|
|
84
|
+
"express": "^5.1.0",
|
|
85
|
+
"http-status-codes": "^2.3.0",
|
|
86
|
+
"mongodb": "^6.18.0"
|
|
87
87
|
},
|
|
88
88
|
"devDependencies": {
|
|
89
|
-
"@types/compression": "
|
|
90
|
-
"@types/cors": "
|
|
89
|
+
"@types/compression": "^1.8.1",
|
|
90
|
+
"@types/cors": "^2.8.19",
|
|
91
91
|
"@types/express": "5.0.3",
|
|
92
|
-
"@types/express-serve-static-core": "
|
|
93
|
-
"@types/node": "
|
|
94
|
-
"@xylabs/base": "
|
|
95
|
-
"@xylabs/object": "
|
|
96
|
-
"@xylabs/ts-scripts-yarn3": "
|
|
97
|
-
"@xylabs/tsconfig": "
|
|
98
|
-
"@xyo-network/account": "
|
|
99
|
-
"@xyo-network/account-model": "
|
|
100
|
-
"@xyo-network/archivist-abstract": "
|
|
101
|
-
"@xyo-network/bios-model": "
|
|
102
|
-
"@xyo-network/boundwitness-builder": "
|
|
103
|
-
"@xyo-network/module-abstract-mongodb": "
|
|
104
|
-
"@xyo-network/module-model-mongodb": "
|
|
105
|
-
"@xyo-network/node-memory": "
|
|
106
|
-
"@xyo-network/xl1-protocol-sdk": "
|
|
107
|
-
"dotenv": "
|
|
108
|
-
"knip": "
|
|
109
|
-
"nodemon": "
|
|
110
|
-
"typescript": "
|
|
111
|
-
"vitest": "
|
|
112
|
-
"vitest-mock-extended": "
|
|
92
|
+
"@types/express-serve-static-core": "^5.0.7",
|
|
93
|
+
"@types/node": "^24.1.0",
|
|
94
|
+
"@xylabs/base": "^4.15.0",
|
|
95
|
+
"@xylabs/object": "^4.15.0",
|
|
96
|
+
"@xylabs/ts-scripts-yarn3": "^7.0.1",
|
|
97
|
+
"@xylabs/tsconfig": "^7.0.1",
|
|
98
|
+
"@xyo-network/account": "^4.3.0",
|
|
99
|
+
"@xyo-network/account-model": "^4.3.0",
|
|
100
|
+
"@xyo-network/archivist-abstract": "^4.3.0",
|
|
101
|
+
"@xyo-network/bios-model": "^6.0.5",
|
|
102
|
+
"@xyo-network/boundwitness-builder": "^4.3.0",
|
|
103
|
+
"@xyo-network/module-abstract-mongodb": "^4.3.0",
|
|
104
|
+
"@xyo-network/module-model-mongodb": "^4.3.0",
|
|
105
|
+
"@xyo-network/node-memory": "^4.3.0",
|
|
106
|
+
"@xyo-network/xl1-protocol-sdk": "^1.7.20",
|
|
107
|
+
"dotenv": "^17.2.1",
|
|
108
|
+
"knip": "^5.62.0",
|
|
109
|
+
"nodemon": "^3.1.10",
|
|
110
|
+
"typescript": "^5.8.3",
|
|
111
|
+
"vitest": "^3.2.4",
|
|
112
|
+
"vitest-mock-extended": "^3.1.0"
|
|
113
113
|
},
|
|
114
114
|
"engines": {
|
|
115
115
|
"node": ">=22.3 <23"
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import { MongoClient } from 'mongodb'
|
|
1
|
+
import { BaseMongoSdk } from '@xylabs/mongo'
|
|
2
|
+
import { getBaseMongoSdkPrivateConfig, hasMongoDBConfig } from '@xyo-network/module-abstract-mongodb'
|
|
4
3
|
import {
|
|
5
|
-
|
|
4
|
+
beforeAll, beforeEach, describe, expect, it,
|
|
6
5
|
} from 'vitest'
|
|
7
6
|
|
|
8
7
|
import { MongoMap } from '../MongoMap.ts'
|
|
@@ -12,24 +11,16 @@ describe.runIf(hasMongoDBConfig())('MongoMap', () => {
|
|
|
12
11
|
name: string
|
|
13
12
|
value: number
|
|
14
13
|
}
|
|
15
|
-
|
|
16
|
-
const TEST_COLLECTION = 'test_mongo_map'
|
|
17
|
-
let client: MongoClient
|
|
14
|
+
const collection = 'test_mongo_map'
|
|
18
15
|
let sdk: BaseMongoSdk<TestDoc>
|
|
19
16
|
let map: MongoMap<string, TestDoc>
|
|
20
17
|
beforeAll(async () => {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
sdk = getBaseMongoSdk<TestDoc>(TEST_COLLECTION)
|
|
18
|
+
const payloadSdkConfig = getBaseMongoSdkPrivateConfig()
|
|
19
|
+
sdk = new BaseMongoSdk<TestDoc>({ ...payloadSdkConfig, collection })
|
|
25
20
|
map = await MongoMap.create<MongoMap<string, TestDoc>>({ sdk })
|
|
26
21
|
await map.start()
|
|
27
22
|
})
|
|
28
23
|
|
|
29
|
-
afterAll(async () => {
|
|
30
|
-
await client.close()
|
|
31
|
-
})
|
|
32
|
-
|
|
33
24
|
beforeEach(async () => {
|
|
34
25
|
await map.clear()
|
|
35
26
|
})
|