@qqbrowser/openclaw-qbot 0.0.147 → 0.0.148
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/build-info.json +3 -3
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/node_modules/@aws-sdk/client-bedrock-runtime/package.json +2 -2
- package/node_modules/@aws-sdk/token-providers/package.json +1 -1
- package/node_modules/@mariozechner/clipboard/index.js +31 -312
- package/node_modules/@mariozechner/clipboard/package.json +12 -52
- package/node_modules/@snazzah/davey/index.js +39 -511
- package/node_modules/@snazzah/davey/package.json +11 -134
- package/node_modules/dotenv/package.json +1 -1
- package/node_modules/dotenv/skills/dotenv/SKILL.md +107 -665
- package/node_modules/dotenv/skills/dotenvx/SKILL.md +67 -76
- package/node_modules/follow-redirects/index.js +24 -1
- package/node_modules/follow-redirects/package.json +1 -1
- package/node_modules/koffi/package.json +9 -5
- package/node_modules/lru-cache/dist/esm/browser/diagnostics-channel-browser.d.mts.map +1 -0
- package/node_modules/lru-cache/dist/esm/browser/diagnostics-channel.js +4 -0
- package/node_modules/lru-cache/dist/esm/browser/index.js +1688 -0
- package/node_modules/lru-cache/dist/esm/browser/index.min.js +2 -0
- package/node_modules/lru-cache/dist/esm/diagnostics-channel-esm.d.mts.map +1 -1
- package/node_modules/lru-cache/dist/esm/diagnostics-channel.js +1 -1
- package/node_modules/lru-cache/package.json +15 -2
- package/node_modules/undici/lib/web/fetch/index.js +15 -2
- package/node_modules/undici/lib/web/fetch/util.js +4 -2
- package/node_modules/undici/package.json +1 -1
- package/noop-pkg/clipboard-noop/index.js +36 -0
- package/noop-pkg/clipboard-noop/package.json +16 -0
- package/noop-pkg/davey-noop/index.js +51 -0
- package/noop-pkg/davey-noop/package.json +17 -0
- package/noop-pkg/koffi-noop/index.js +1 -0
- package/noop-pkg/koffi-noop/package.json +16 -0
- package/package.json +11 -3
- package/node_modules/@mariozechner/clipboard/.yarnrc.yml +0 -1
- package/node_modules/@mariozechner/clipboard/Cargo.toml +0 -26
- package/node_modules/@mariozechner/clipboard/build.rs +0 -5
- package/node_modules/@mariozechner/clipboard/src/lib.rs +0 -191
- package/node_modules/@mariozechner/clipboard-darwin-arm64/clipboard.darwin-arm64.node +0 -0
- package/node_modules/@mariozechner/clipboard-darwin-arm64/package.json +0 -22
- package/node_modules/@mariozechner/clipboard-darwin-universal/clipboard.darwin-universal.node +0 -0
- package/node_modules/@mariozechner/clipboard-darwin-universal/package.json +0 -19
- package/node_modules/@mariozechner/clipboard-darwin-x64/clipboard.darwin-x64.node +0 -0
- package/node_modules/@mariozechner/clipboard-darwin-x64/package.json +0 -22
- package/node_modules/@mariozechner/clipboard-linux-x64-gnu/clipboard.linux-x64-gnu.node +0 -0
- package/node_modules/@mariozechner/clipboard-linux-x64-gnu/package.json +0 -25
- package/node_modules/@mariozechner/clipboard-linux-x64-musl/clipboard.linux-x64-musl.node +0 -0
- package/node_modules/@mariozechner/clipboard-linux-x64-musl/package.json +0 -25
- package/node_modules/@snazzah/davey/browser.js +0 -1
- package/node_modules/@snazzah/davey-darwin-arm64/davey.darwin-arm64.node +0 -0
- package/node_modules/@snazzah/davey-darwin-arm64/package.json +0 -40
- package/node_modules/@snazzah/davey-darwin-x64/davey.darwin-x64.node +0 -0
- package/node_modules/@snazzah/davey-darwin-x64/package.json +0 -40
- package/node_modules/@snazzah/davey-linux-x64-gnu/davey.linux-x64-gnu.node +0 -0
- package/node_modules/@snazzah/davey-linux-x64-gnu/package.json +0 -43
- package/node_modules/@snazzah/davey-linux-x64-musl/davey.linux-x64-musl.node +0 -0
- package/node_modules/@snazzah/davey-linux-x64-musl/package.json +0 -43
|
@@ -1,523 +1,51 @@
|
|
|
1
|
-
//
|
|
2
|
-
|
|
3
|
-
// @
|
|
4
|
-
/* auto-generated by NAPI-RS */
|
|
1
|
+
// noop 替代 @snazzah/davey — DAVE 协议原生绑定的空实现
|
|
2
|
+
// 当 daveEncryption 被禁用时,@discordjs/voice 不会实际创建 DAVESession,
|
|
3
|
+
// 但它仍然会在顶层 require("@snazzah/davey"),所以需要导出兼容的接口。
|
|
5
4
|
|
|
6
|
-
const
|
|
7
|
-
|
|
5
|
+
const Codec = Object.freeze({});
|
|
6
|
+
const MediaType = Object.freeze({});
|
|
7
|
+
const SessionStatus = Object.freeze({});
|
|
8
|
+
const ProposalsOperationType = Object.freeze({});
|
|
8
9
|
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
const
|
|
10
|
+
const DAVE_PROTOCOL_VERSION = 0;
|
|
11
|
+
const VERSION = "0.0.0-noop";
|
|
12
|
+
const DEBUG_BUILD = false;
|
|
12
13
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
if (process.platform === 'linux') {
|
|
16
|
-
musl = isMuslFromFilesystem()
|
|
17
|
-
if (musl === null) {
|
|
18
|
-
musl = isMuslFromReport()
|
|
19
|
-
}
|
|
20
|
-
if (musl === null) {
|
|
21
|
-
musl = isMuslFromChildProcess()
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
return musl
|
|
14
|
+
function generateKeyFingerprint() {
|
|
15
|
+
return "";
|
|
25
16
|
}
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
const isMuslFromFilesystem = () => {
|
|
30
|
-
try {
|
|
31
|
-
return readFileSync('/usr/bin/ldd', 'utf-8').includes('musl')
|
|
32
|
-
} catch {
|
|
33
|
-
return null
|
|
34
|
-
}
|
|
17
|
+
function generatePairwiseFingerprint() {
|
|
18
|
+
return "";
|
|
35
19
|
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
let report = null
|
|
39
|
-
if (typeof process.report?.getReport === 'function') {
|
|
40
|
-
process.report.excludeNetwork = true
|
|
41
|
-
report = process.report.getReport()
|
|
42
|
-
}
|
|
43
|
-
if (!report) {
|
|
44
|
-
return null
|
|
45
|
-
}
|
|
46
|
-
if (report.header && report.header.glibcVersionRuntime) {
|
|
47
|
-
return false
|
|
48
|
-
}
|
|
49
|
-
if (Array.isArray(report.sharedObjects)) {
|
|
50
|
-
if (report.sharedObjects.some(isFileMusl)) {
|
|
51
|
-
return true
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
return false
|
|
20
|
+
function generateDisplayableCode() {
|
|
21
|
+
return "";
|
|
55
22
|
}
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
try {
|
|
59
|
-
return require('child_process').execSync('ldd --version', { encoding: 'utf8' }).includes('musl')
|
|
60
|
-
} catch (e) {
|
|
61
|
-
// If we reach this case, we don't know if the system is musl or not, so is better to just fallback to false
|
|
62
|
-
return false
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
function requireNative() {
|
|
67
|
-
if (process.env.NAPI_RS_NATIVE_LIBRARY_PATH) {
|
|
68
|
-
try {
|
|
69
|
-
nativeBinding = require(process.env.NAPI_RS_NATIVE_LIBRARY_PATH);
|
|
70
|
-
} catch (err) {
|
|
71
|
-
loadErrors.push(err)
|
|
72
|
-
}
|
|
73
|
-
} else if (process.platform === 'android') {
|
|
74
|
-
if (process.arch === 'arm64') {
|
|
75
|
-
try {
|
|
76
|
-
return require('./davey.android-arm64.node')
|
|
77
|
-
} catch (e) {
|
|
78
|
-
loadErrors.push(e)
|
|
79
|
-
}
|
|
80
|
-
try {
|
|
81
|
-
const binding = require('@snazzah/davey-android-arm64')
|
|
82
|
-
const bindingPackageVersion = require('@snazzah/davey-android-arm64/package.json').version
|
|
83
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
84
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
85
|
-
}
|
|
86
|
-
return binding
|
|
87
|
-
} catch (e) {
|
|
88
|
-
loadErrors.push(e)
|
|
89
|
-
}
|
|
90
|
-
} else if (process.arch === 'arm') {
|
|
91
|
-
try {
|
|
92
|
-
return require('./davey.android-arm-eabi.node')
|
|
93
|
-
} catch (e) {
|
|
94
|
-
loadErrors.push(e)
|
|
95
|
-
}
|
|
96
|
-
try {
|
|
97
|
-
const binding = require('@snazzah/davey-android-arm-eabi')
|
|
98
|
-
const bindingPackageVersion = require('@snazzah/davey-android-arm-eabi/package.json').version
|
|
99
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
100
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
101
|
-
}
|
|
102
|
-
return binding
|
|
103
|
-
} catch (e) {
|
|
104
|
-
loadErrors.push(e)
|
|
105
|
-
}
|
|
106
|
-
} else {
|
|
107
|
-
loadErrors.push(new Error(`Unsupported architecture on Android ${process.arch}`))
|
|
108
|
-
}
|
|
109
|
-
} else if (process.platform === 'win32') {
|
|
110
|
-
if (process.arch === 'x64') {
|
|
111
|
-
try {
|
|
112
|
-
return require('./davey.win32-x64-msvc.node')
|
|
113
|
-
} catch (e) {
|
|
114
|
-
loadErrors.push(e)
|
|
115
|
-
}
|
|
116
|
-
try {
|
|
117
|
-
const binding = require('@snazzah/davey-win32-x64-msvc')
|
|
118
|
-
const bindingPackageVersion = require('@snazzah/davey-win32-x64-msvc/package.json').version
|
|
119
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
120
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
121
|
-
}
|
|
122
|
-
return binding
|
|
123
|
-
} catch (e) {
|
|
124
|
-
loadErrors.push(e)
|
|
125
|
-
}
|
|
126
|
-
} else if (process.arch === 'ia32') {
|
|
127
|
-
try {
|
|
128
|
-
return require('./davey.win32-ia32-msvc.node')
|
|
129
|
-
} catch (e) {
|
|
130
|
-
loadErrors.push(e)
|
|
131
|
-
}
|
|
132
|
-
try {
|
|
133
|
-
const binding = require('@snazzah/davey-win32-ia32-msvc')
|
|
134
|
-
const bindingPackageVersion = require('@snazzah/davey-win32-ia32-msvc/package.json').version
|
|
135
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
136
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
137
|
-
}
|
|
138
|
-
return binding
|
|
139
|
-
} catch (e) {
|
|
140
|
-
loadErrors.push(e)
|
|
141
|
-
}
|
|
142
|
-
} else if (process.arch === 'arm64') {
|
|
143
|
-
try {
|
|
144
|
-
return require('./davey.win32-arm64-msvc.node')
|
|
145
|
-
} catch (e) {
|
|
146
|
-
loadErrors.push(e)
|
|
147
|
-
}
|
|
148
|
-
try {
|
|
149
|
-
const binding = require('@snazzah/davey-win32-arm64-msvc')
|
|
150
|
-
const bindingPackageVersion = require('@snazzah/davey-win32-arm64-msvc/package.json').version
|
|
151
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
152
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
153
|
-
}
|
|
154
|
-
return binding
|
|
155
|
-
} catch (e) {
|
|
156
|
-
loadErrors.push(e)
|
|
157
|
-
}
|
|
158
|
-
} else {
|
|
159
|
-
loadErrors.push(new Error(`Unsupported architecture on Windows: ${process.arch}`))
|
|
160
|
-
}
|
|
161
|
-
} else if (process.platform === 'darwin') {
|
|
162
|
-
try {
|
|
163
|
-
return require('./davey.darwin-universal.node')
|
|
164
|
-
} catch (e) {
|
|
165
|
-
loadErrors.push(e)
|
|
166
|
-
}
|
|
167
|
-
try {
|
|
168
|
-
const binding = require('@snazzah/davey-darwin-universal')
|
|
169
|
-
const bindingPackageVersion = require('@snazzah/davey-darwin-universal/package.json').version
|
|
170
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
171
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
172
|
-
}
|
|
173
|
-
return binding
|
|
174
|
-
} catch (e) {
|
|
175
|
-
loadErrors.push(e)
|
|
176
|
-
}
|
|
177
|
-
if (process.arch === 'x64') {
|
|
178
|
-
try {
|
|
179
|
-
return require('./davey.darwin-x64.node')
|
|
180
|
-
} catch (e) {
|
|
181
|
-
loadErrors.push(e)
|
|
182
|
-
}
|
|
183
|
-
try {
|
|
184
|
-
const binding = require('@snazzah/davey-darwin-x64')
|
|
185
|
-
const bindingPackageVersion = require('@snazzah/davey-darwin-x64/package.json').version
|
|
186
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
187
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
188
|
-
}
|
|
189
|
-
return binding
|
|
190
|
-
} catch (e) {
|
|
191
|
-
loadErrors.push(e)
|
|
192
|
-
}
|
|
193
|
-
} else if (process.arch === 'arm64') {
|
|
194
|
-
try {
|
|
195
|
-
return require('./davey.darwin-arm64.node')
|
|
196
|
-
} catch (e) {
|
|
197
|
-
loadErrors.push(e)
|
|
198
|
-
}
|
|
199
|
-
try {
|
|
200
|
-
const binding = require('@snazzah/davey-darwin-arm64')
|
|
201
|
-
const bindingPackageVersion = require('@snazzah/davey-darwin-arm64/package.json').version
|
|
202
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
203
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
204
|
-
}
|
|
205
|
-
return binding
|
|
206
|
-
} catch (e) {
|
|
207
|
-
loadErrors.push(e)
|
|
208
|
-
}
|
|
209
|
-
} else {
|
|
210
|
-
loadErrors.push(new Error(`Unsupported architecture on macOS: ${process.arch}`))
|
|
211
|
-
}
|
|
212
|
-
} else if (process.platform === 'freebsd') {
|
|
213
|
-
if (process.arch === 'x64') {
|
|
214
|
-
try {
|
|
215
|
-
return require('./davey.freebsd-x64.node')
|
|
216
|
-
} catch (e) {
|
|
217
|
-
loadErrors.push(e)
|
|
218
|
-
}
|
|
219
|
-
try {
|
|
220
|
-
const binding = require('@snazzah/davey-freebsd-x64')
|
|
221
|
-
const bindingPackageVersion = require('@snazzah/davey-freebsd-x64/package.json').version
|
|
222
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
223
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
224
|
-
}
|
|
225
|
-
return binding
|
|
226
|
-
} catch (e) {
|
|
227
|
-
loadErrors.push(e)
|
|
228
|
-
}
|
|
229
|
-
} else if (process.arch === 'arm64') {
|
|
230
|
-
try {
|
|
231
|
-
return require('./davey.freebsd-arm64.node')
|
|
232
|
-
} catch (e) {
|
|
233
|
-
loadErrors.push(e)
|
|
234
|
-
}
|
|
235
|
-
try {
|
|
236
|
-
const binding = require('@snazzah/davey-freebsd-arm64')
|
|
237
|
-
const bindingPackageVersion = require('@snazzah/davey-freebsd-arm64/package.json').version
|
|
238
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
239
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
240
|
-
}
|
|
241
|
-
return binding
|
|
242
|
-
} catch (e) {
|
|
243
|
-
loadErrors.push(e)
|
|
244
|
-
}
|
|
245
|
-
} else {
|
|
246
|
-
loadErrors.push(new Error(`Unsupported architecture on FreeBSD: ${process.arch}`))
|
|
247
|
-
}
|
|
248
|
-
} else if (process.platform === 'linux') {
|
|
249
|
-
if (process.arch === 'x64') {
|
|
250
|
-
if (isMusl()) {
|
|
251
|
-
try {
|
|
252
|
-
return require('./davey.linux-x64-musl.node')
|
|
253
|
-
} catch (e) {
|
|
254
|
-
loadErrors.push(e)
|
|
255
|
-
}
|
|
256
|
-
try {
|
|
257
|
-
const binding = require('@snazzah/davey-linux-x64-musl')
|
|
258
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-x64-musl/package.json').version
|
|
259
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
260
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
261
|
-
}
|
|
262
|
-
return binding
|
|
263
|
-
} catch (e) {
|
|
264
|
-
loadErrors.push(e)
|
|
265
|
-
}
|
|
266
|
-
} else {
|
|
267
|
-
try {
|
|
268
|
-
return require('./davey.linux-x64-gnu.node')
|
|
269
|
-
} catch (e) {
|
|
270
|
-
loadErrors.push(e)
|
|
271
|
-
}
|
|
272
|
-
try {
|
|
273
|
-
const binding = require('@snazzah/davey-linux-x64-gnu')
|
|
274
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-x64-gnu/package.json').version
|
|
275
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
276
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
277
|
-
}
|
|
278
|
-
return binding
|
|
279
|
-
} catch (e) {
|
|
280
|
-
loadErrors.push(e)
|
|
281
|
-
}
|
|
282
|
-
}
|
|
283
|
-
} else if (process.arch === 'arm64') {
|
|
284
|
-
if (isMusl()) {
|
|
285
|
-
try {
|
|
286
|
-
return require('./davey.linux-arm64-musl.node')
|
|
287
|
-
} catch (e) {
|
|
288
|
-
loadErrors.push(e)
|
|
289
|
-
}
|
|
290
|
-
try {
|
|
291
|
-
const binding = require('@snazzah/davey-linux-arm64-musl')
|
|
292
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-arm64-musl/package.json').version
|
|
293
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
294
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
295
|
-
}
|
|
296
|
-
return binding
|
|
297
|
-
} catch (e) {
|
|
298
|
-
loadErrors.push(e)
|
|
299
|
-
}
|
|
300
|
-
} else {
|
|
301
|
-
try {
|
|
302
|
-
return require('./davey.linux-arm64-gnu.node')
|
|
303
|
-
} catch (e) {
|
|
304
|
-
loadErrors.push(e)
|
|
305
|
-
}
|
|
306
|
-
try {
|
|
307
|
-
const binding = require('@snazzah/davey-linux-arm64-gnu')
|
|
308
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-arm64-gnu/package.json').version
|
|
309
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
310
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
311
|
-
}
|
|
312
|
-
return binding
|
|
313
|
-
} catch (e) {
|
|
314
|
-
loadErrors.push(e)
|
|
315
|
-
}
|
|
316
|
-
}
|
|
317
|
-
} else if (process.arch === 'arm') {
|
|
318
|
-
if (isMusl()) {
|
|
319
|
-
try {
|
|
320
|
-
return require('./davey.linux-arm-musleabihf.node')
|
|
321
|
-
} catch (e) {
|
|
322
|
-
loadErrors.push(e)
|
|
323
|
-
}
|
|
324
|
-
try {
|
|
325
|
-
const binding = require('@snazzah/davey-linux-arm-musleabihf')
|
|
326
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-arm-musleabihf/package.json').version
|
|
327
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
328
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
329
|
-
}
|
|
330
|
-
return binding
|
|
331
|
-
} catch (e) {
|
|
332
|
-
loadErrors.push(e)
|
|
333
|
-
}
|
|
334
|
-
} else {
|
|
335
|
-
try {
|
|
336
|
-
return require('./davey.linux-arm-gnueabihf.node')
|
|
337
|
-
} catch (e) {
|
|
338
|
-
loadErrors.push(e)
|
|
339
|
-
}
|
|
340
|
-
try {
|
|
341
|
-
const binding = require('@snazzah/davey-linux-arm-gnueabihf')
|
|
342
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-arm-gnueabihf/package.json').version
|
|
343
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
344
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
345
|
-
}
|
|
346
|
-
return binding
|
|
347
|
-
} catch (e) {
|
|
348
|
-
loadErrors.push(e)
|
|
349
|
-
}
|
|
350
|
-
}
|
|
351
|
-
} else if (process.arch === 'riscv64') {
|
|
352
|
-
if (isMusl()) {
|
|
353
|
-
try {
|
|
354
|
-
return require('./davey.linux-riscv64-musl.node')
|
|
355
|
-
} catch (e) {
|
|
356
|
-
loadErrors.push(e)
|
|
357
|
-
}
|
|
358
|
-
try {
|
|
359
|
-
const binding = require('@snazzah/davey-linux-riscv64-musl')
|
|
360
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-riscv64-musl/package.json').version
|
|
361
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
362
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
363
|
-
}
|
|
364
|
-
return binding
|
|
365
|
-
} catch (e) {
|
|
366
|
-
loadErrors.push(e)
|
|
367
|
-
}
|
|
368
|
-
} else {
|
|
369
|
-
try {
|
|
370
|
-
return require('./davey.linux-riscv64-gnu.node')
|
|
371
|
-
} catch (e) {
|
|
372
|
-
loadErrors.push(e)
|
|
373
|
-
}
|
|
374
|
-
try {
|
|
375
|
-
const binding = require('@snazzah/davey-linux-riscv64-gnu')
|
|
376
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-riscv64-gnu/package.json').version
|
|
377
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
378
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
379
|
-
}
|
|
380
|
-
return binding
|
|
381
|
-
} catch (e) {
|
|
382
|
-
loadErrors.push(e)
|
|
383
|
-
}
|
|
384
|
-
}
|
|
385
|
-
} else if (process.arch === 'ppc64') {
|
|
386
|
-
try {
|
|
387
|
-
return require('./davey.linux-ppc64-gnu.node')
|
|
388
|
-
} catch (e) {
|
|
389
|
-
loadErrors.push(e)
|
|
390
|
-
}
|
|
391
|
-
try {
|
|
392
|
-
const binding = require('@snazzah/davey-linux-ppc64-gnu')
|
|
393
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-ppc64-gnu/package.json').version
|
|
394
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
395
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
396
|
-
}
|
|
397
|
-
return binding
|
|
398
|
-
} catch (e) {
|
|
399
|
-
loadErrors.push(e)
|
|
400
|
-
}
|
|
401
|
-
} else if (process.arch === 's390x') {
|
|
402
|
-
try {
|
|
403
|
-
return require('./davey.linux-s390x-gnu.node')
|
|
404
|
-
} catch (e) {
|
|
405
|
-
loadErrors.push(e)
|
|
406
|
-
}
|
|
407
|
-
try {
|
|
408
|
-
const binding = require('@snazzah/davey-linux-s390x-gnu')
|
|
409
|
-
const bindingPackageVersion = require('@snazzah/davey-linux-s390x-gnu/package.json').version
|
|
410
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
411
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
412
|
-
}
|
|
413
|
-
return binding
|
|
414
|
-
} catch (e) {
|
|
415
|
-
loadErrors.push(e)
|
|
416
|
-
}
|
|
417
|
-
} else {
|
|
418
|
-
loadErrors.push(new Error(`Unsupported architecture on Linux: ${process.arch}`))
|
|
419
|
-
}
|
|
420
|
-
} else if (process.platform === 'openharmony') {
|
|
421
|
-
if (process.arch === 'arm64') {
|
|
422
|
-
try {
|
|
423
|
-
return require('./davey.openharmony-arm64.node')
|
|
424
|
-
} catch (e) {
|
|
425
|
-
loadErrors.push(e)
|
|
426
|
-
}
|
|
427
|
-
try {
|
|
428
|
-
const binding = require('@snazzah/davey-openharmony-arm64')
|
|
429
|
-
const bindingPackageVersion = require('@snazzah/davey-openharmony-arm64/package.json').version
|
|
430
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
431
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
432
|
-
}
|
|
433
|
-
return binding
|
|
434
|
-
} catch (e) {
|
|
435
|
-
loadErrors.push(e)
|
|
436
|
-
}
|
|
437
|
-
} else if (process.arch === 'x64') {
|
|
438
|
-
try {
|
|
439
|
-
return require('./davey.openharmony-x64.node')
|
|
440
|
-
} catch (e) {
|
|
441
|
-
loadErrors.push(e)
|
|
442
|
-
}
|
|
443
|
-
try {
|
|
444
|
-
const binding = require('@snazzah/davey-openharmony-x64')
|
|
445
|
-
const bindingPackageVersion = require('@snazzah/davey-openharmony-x64/package.json').version
|
|
446
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
447
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
448
|
-
}
|
|
449
|
-
return binding
|
|
450
|
-
} catch (e) {
|
|
451
|
-
loadErrors.push(e)
|
|
452
|
-
}
|
|
453
|
-
} else if (process.arch === 'arm') {
|
|
454
|
-
try {
|
|
455
|
-
return require('./davey.openharmony-arm.node')
|
|
456
|
-
} catch (e) {
|
|
457
|
-
loadErrors.push(e)
|
|
458
|
-
}
|
|
459
|
-
try {
|
|
460
|
-
const binding = require('@snazzah/davey-openharmony-arm')
|
|
461
|
-
const bindingPackageVersion = require('@snazzah/davey-openharmony-arm/package.json').version
|
|
462
|
-
if (bindingPackageVersion !== '0.1.11' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
463
|
-
throw new Error(`Native binding package version mismatch, expected 0.1.11 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
|
|
464
|
-
}
|
|
465
|
-
return binding
|
|
466
|
-
} catch (e) {
|
|
467
|
-
loadErrors.push(e)
|
|
468
|
-
}
|
|
469
|
-
} else {
|
|
470
|
-
loadErrors.push(new Error(`Unsupported architecture on OpenHarmony: ${process.arch}`))
|
|
471
|
-
}
|
|
472
|
-
} else {
|
|
473
|
-
loadErrors.push(new Error(`Unsupported OS: ${process.platform}, architecture: ${process.arch}`))
|
|
474
|
-
}
|
|
475
|
-
}
|
|
476
|
-
|
|
477
|
-
nativeBinding = requireNative()
|
|
478
|
-
|
|
479
|
-
if (!nativeBinding || process.env.NAPI_RS_FORCE_WASI) {
|
|
480
|
-
try {
|
|
481
|
-
nativeBinding = require('./davey.wasi.cjs')
|
|
482
|
-
} catch (err) {
|
|
483
|
-
if (process.env.NAPI_RS_FORCE_WASI) {
|
|
484
|
-
loadErrors.push(err)
|
|
485
|
-
}
|
|
486
|
-
}
|
|
487
|
-
if (!nativeBinding) {
|
|
488
|
-
try {
|
|
489
|
-
nativeBinding = require('@snazzah/davey-wasm32-wasi')
|
|
490
|
-
} catch (err) {
|
|
491
|
-
if (process.env.NAPI_RS_FORCE_WASI) {
|
|
492
|
-
loadErrors.push(err)
|
|
493
|
-
}
|
|
494
|
-
}
|
|
495
|
-
}
|
|
23
|
+
function generateP256Keypair() {
|
|
24
|
+
return { publicKey: Buffer.alloc(0), privateKey: Buffer.alloc(0) };
|
|
496
25
|
}
|
|
497
26
|
|
|
498
|
-
|
|
499
|
-
|
|
27
|
+
class DAVESession {
|
|
28
|
+
constructor() {
|
|
500
29
|
throw new Error(
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
'Please try `npm i` again after removing both package-lock.json and node_modules directory.',
|
|
504
|
-
{ cause: loadErrors }
|
|
505
|
-
)
|
|
30
|
+
"@snazzah/davey has been replaced by a noop package. Set daveEncryption: false in your config.",
|
|
31
|
+
);
|
|
506
32
|
}
|
|
507
|
-
throw new Error(`Failed to load native binding`)
|
|
508
33
|
}
|
|
509
34
|
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
module.exports
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
35
|
+
const DaveSession = DAVESession;
|
|
36
|
+
|
|
37
|
+
module.exports = {
|
|
38
|
+
Codec,
|
|
39
|
+
MediaType,
|
|
40
|
+
SessionStatus,
|
|
41
|
+
ProposalsOperationType,
|
|
42
|
+
DAVE_PROTOCOL_VERSION,
|
|
43
|
+
VERSION,
|
|
44
|
+
DEBUG_BUILD,
|
|
45
|
+
generateKeyFingerprint,
|
|
46
|
+
generatePairwiseFingerprint,
|
|
47
|
+
generateDisplayableCode,
|
|
48
|
+
generateP256Keypair,
|
|
49
|
+
DAVESession,
|
|
50
|
+
DaveSession,
|
|
51
|
+
};
|