@pkcprotocol/pkc-js 0.0.149 → 0.0.151

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.
Files changed (86) hide show
  1. package/dist/browser/errors.d.ts +1 -0
  2. package/dist/browser/errors.js +1 -0
  3. package/dist/browser/errors.js.map +1 -1
  4. package/dist/browser/generated-version.d.ts +1 -1
  5. package/dist/browser/generated-version.js +1 -1
  6. package/dist/browser/helia/helia-for-pkc.js +85 -11
  7. package/dist/browser/helia/helia-for-pkc.js.map +1 -1
  8. package/dist/browser/helia/util.d.ts +3 -2
  9. package/dist/browser/helia/util.js +17 -7
  10. package/dist/browser/helia/util.js.map +1 -1
  11. package/dist/browser/pkc/pkc.js +19 -5
  12. package/dist/browser/pkc/pkc.js.map +1 -1
  13. package/dist/browser/pkc-error.d.ts +1 -1
  14. package/dist/browser/publications/comment/comment.d.ts +3 -1
  15. package/dist/browser/publications/comment/comment.js +40 -28
  16. package/dist/browser/publications/comment/comment.js.map +1 -1
  17. package/dist/browser/runtime/node/community/local-community/cleanup.js +3 -0
  18. package/dist/browser/runtime/node/community/local-community/cleanup.js.map +1 -1
  19. package/dist/browser/runtime/node/community/local-community/comment-updates.js +30 -62
  20. package/dist/browser/runtime/node/community/local-community/comment-updates.js.map +1 -1
  21. package/dist/browser/runtime/node/community/local-community/post-updates-bucket.d.ts +7 -5
  22. package/dist/browser/runtime/node/community/local-community/post-updates-bucket.js +122 -121
  23. package/dist/browser/runtime/node/community/local-community/post-updates-bucket.js.map +1 -1
  24. package/dist/browser/runtime/node/community/local-community/unixfs-directory-patch.d.ts +20 -0
  25. package/dist/browser/runtime/node/community/local-community/unixfs-directory-patch.js +231 -0
  26. package/dist/browser/runtime/node/community/local-community/unixfs-directory-patch.js.map +1 -0
  27. package/dist/browser/runtime/node/community/local-community.d.ts +1 -1
  28. package/dist/browser/runtime/node/community/local-community.js +3 -4
  29. package/dist/browser/runtime/node/community/local-community.js.map +1 -1
  30. package/dist/browser/util.d.ts +1 -12
  31. package/dist/browser/util.js +0 -53
  32. package/dist/browser/util.js.map +1 -1
  33. package/dist/bundled/bundle-manifest.json +122 -108
  34. package/dist/bundled/challenges.js +1 -1
  35. package/dist/bundled/chunks/{helia-for-pkc-8iett8xl.js → helia-for-pkc-C86lDfh5.js} +62 -12
  36. package/dist/bundled/chunks/{local-community-ChZZa9bm.js → local-community-DKZRsY97.js} +1 -1
  37. package/dist/bundled/chunks/{local-community-BlBIYSsF.js → local-community-k_ETfr57.js} +374 -156
  38. package/dist/bundled/chunks/{node-BH_HrtON.js → node-Br5aH83u.js} +43 -26
  39. package/dist/bundled/chunks/{page-sort-scoring-NpdjWYfa.js → page-sort-scoring-DK29vmN0.js} +1 -1
  40. package/dist/bundled/chunks/{rpc-local-community-Byj5ZmMa.js → rpc-local-community-Cfc2G6NP.js} +3 -3
  41. package/dist/bundled/chunks/src-66iuMY_4.js +2 -0
  42. package/dist/bundled/chunks/{src-evzEHW9W.js → src-BSYNGtIQ.js} +2 -44
  43. package/dist/bundled/chunks/{src-CNab3O7M.js → src-CAvdjq_i.js} +2 -2
  44. package/dist/bundled/chunks/{src-Bj5iE3qB.js → src-DIOHVUq9.js} +5 -4
  45. package/dist/bundled/chunks/src-DeIT_BDx.js +44 -0
  46. package/dist/bundled/chunks/{src-ltPxiZKf.js → src-NvrGEL7T.js} +2 -1
  47. package/dist/bundled/chunks/{util-CUZ1U2Go.js → util-Bmd1e0QJ.js} +4 -45
  48. package/dist/bundled/chunks/{util-DmmLFRbV.js → util-XNoDQ4hb.js} +19 -7
  49. package/dist/bundled/chunks/{validate-package-factories-CkU4qFQx.js → validate-package-factories-evt2DaRs.js} +2 -2
  50. package/dist/bundled/index.js +1 -1
  51. package/dist/bundled/page-sorts.js +1 -1
  52. package/dist/bundled/rpc/src/index.js +4 -4
  53. package/dist/node/errors.d.ts +1 -0
  54. package/dist/node/errors.js +1 -0
  55. package/dist/node/errors.js.map +1 -1
  56. package/dist/node/generated-version.d.ts +1 -1
  57. package/dist/node/generated-version.js +1 -1
  58. package/dist/node/helia/helia-for-pkc.js +85 -11
  59. package/dist/node/helia/helia-for-pkc.js.map +1 -1
  60. package/dist/node/helia/util.d.ts +3 -2
  61. package/dist/node/helia/util.js +17 -7
  62. package/dist/node/helia/util.js.map +1 -1
  63. package/dist/node/pkc/pkc.js +19 -5
  64. package/dist/node/pkc/pkc.js.map +1 -1
  65. package/dist/node/pkc-error.d.ts +1 -1
  66. package/dist/node/publications/comment/comment.d.ts +3 -1
  67. package/dist/node/publications/comment/comment.js +40 -28
  68. package/dist/node/publications/comment/comment.js.map +1 -1
  69. package/dist/node/runtime/node/community/local-community/cleanup.js +3 -0
  70. package/dist/node/runtime/node/community/local-community/cleanup.js.map +1 -1
  71. package/dist/node/runtime/node/community/local-community/comment-updates.js +30 -62
  72. package/dist/node/runtime/node/community/local-community/comment-updates.js.map +1 -1
  73. package/dist/node/runtime/node/community/local-community/post-updates-bucket.d.ts +7 -5
  74. package/dist/node/runtime/node/community/local-community/post-updates-bucket.js +122 -121
  75. package/dist/node/runtime/node/community/local-community/post-updates-bucket.js.map +1 -1
  76. package/dist/node/runtime/node/community/local-community/unixfs-directory-patch.d.ts +20 -0
  77. package/dist/node/runtime/node/community/local-community/unixfs-directory-patch.js +231 -0
  78. package/dist/node/runtime/node/community/local-community/unixfs-directory-patch.js.map +1 -0
  79. package/dist/node/runtime/node/community/local-community.d.ts +1 -1
  80. package/dist/node/runtime/node/community/local-community.js +3 -4
  81. package/dist/node/runtime/node/community/local-community.js.map +1 -1
  82. package/dist/node/util.d.ts +1 -12
  83. package/dist/node/util.js +0 -53
  84. package/dist/node/util.js.map +1 -1
  85. package/package.json +3 -1
  86. package/dist/bundled/chunks/src-BC60-Q7v.js +0 -2
@@ -3,7 +3,7 @@
3
3
  "challenges.js": {
4
4
  "isEntry": true,
5
5
  "imports": [
6
- "chunks/validate-package-factories-CkU4qFQx.js"
6
+ "chunks/validate-package-factories-evt2DaRs.js"
7
7
  ],
8
8
  "dynamicImports": [],
9
9
  "inputs": [
@@ -16,7 +16,7 @@
16
16
  "node:module"
17
17
  ],
18
18
  "dynamicImports": [
19
- "chunks/node-BH_HrtON.js"
19
+ "chunks/node-Br5aH83u.js"
20
20
  ],
21
21
  "inputs": [
22
22
  "dist/node/runtime/node/compile-cache.js",
@@ -26,7 +26,7 @@
26
26
  "index.js": {
27
27
  "isEntry": true,
28
28
  "imports": [
29
- "chunks/node-BH_HrtON.js"
29
+ "chunks/node-Br5aH83u.js"
30
30
  ],
31
31
  "dynamicImports": [],
32
32
  "inputs": []
@@ -34,7 +34,7 @@
34
34
  "page-sorts.js": {
35
35
  "isEntry": true,
36
36
  "imports": [
37
- "chunks/validate-package-factories-CkU4qFQx.js"
37
+ "chunks/validate-package-factories-evt2DaRs.js"
38
38
  ],
39
39
  "dynamicImports": [],
40
40
  "inputs": [
@@ -44,10 +44,10 @@
44
44
  "rpc/src/index.js": {
45
45
  "isEntry": true,
46
46
  "imports": [
47
- "chunks/rpc-local-community-Byj5ZmMa.js",
48
- "chunks/node-BH_HrtON.js",
49
- "chunks/util-CUZ1U2Go.js",
50
- "chunks/local-community-BlBIYSsF.js",
47
+ "chunks/rpc-local-community-Cfc2G6NP.js",
48
+ "chunks/node-Br5aH83u.js",
49
+ "chunks/util-Bmd1e0QJ.js",
50
+ "chunks/local-community-k_ETfr57.js",
51
51
  "node:url",
52
52
  "path",
53
53
  "assert",
@@ -77,12 +77,12 @@
77
77
  "\u0000rolldown/runtime.js"
78
78
  ]
79
79
  },
80
- "chunks/helia-for-pkc-8iett8xl.js": {
80
+ "chunks/helia-for-pkc-C86lDfh5.js": {
81
81
  "isEntry": false,
82
82
  "imports": [
83
83
  "chunks/chunk-2rV9d50f.js",
84
- "chunks/util-CUZ1U2Go.js",
85
- "chunks/util-DmmLFRbV.js",
84
+ "chunks/util-Bmd1e0QJ.js",
85
+ "chunks/util-XNoDQ4hb.js",
86
86
  "chunks/src-DKntVmyX.js",
87
87
  "chunks/src-Cpx2Sts8.js",
88
88
  "node:url",
@@ -99,13 +99,13 @@
99
99
  "ipns",
100
100
  "uint8arrays/equals",
101
101
  "@libp2p/utils",
102
+ "multiformats/hashes/sha2",
102
103
  "helia",
103
104
  "@helia/libp2p",
104
105
  "@helia/bitswap",
105
106
  "@helia/ipns",
106
107
  "@libp2p/gossipsub",
107
108
  "@libp2p/identify",
108
- "multiformats/hashes/sha2",
109
109
  "blockstore-core",
110
110
  "multiformats/codecs/raw",
111
111
  "@helia/delegated-routing-v1-http-api-client",
@@ -204,13 +204,23 @@
204
204
  "dist/node/helia/helia-for-pkc.js"
205
205
  ]
206
206
  },
207
- "chunks/local-community-BlBIYSsF.js": {
207
+ "chunks/local-community-DKZRsY97.js": {
208
+ "isEntry": false,
209
+ "imports": [
210
+ "chunks/local-community-k_ETfr57.js"
211
+ ],
212
+ "dynamicImports": [],
213
+ "inputs": []
214
+ },
215
+ "chunks/local-community-k_ETfr57.js": {
208
216
  "isEntry": false,
209
217
  "imports": [
210
218
  "chunks/chunk-2rV9d50f.js",
211
- "chunks/rpc-local-community-Byj5ZmMa.js",
212
- "chunks/util-CUZ1U2Go.js",
213
- "chunks/page-sort-scoring-NpdjWYfa.js",
219
+ "chunks/rpc-local-community-Cfc2G6NP.js",
220
+ "chunks/util-Bmd1e0QJ.js",
221
+ "chunks/page-sort-scoring-DK29vmN0.js",
222
+ "chunks/src-BSYNGtIQ.js",
223
+ "chunks/src-CAvdjq_i.js",
214
224
  "node:url",
215
225
  "node:path",
216
226
  "os",
@@ -223,12 +233,14 @@
223
233
  "multiformats/cid",
224
234
  "@libp2p/peer-id",
225
235
  "typestub-ipfs-only-hash",
226
- "node:v8"
236
+ "node:v8",
237
+ "multiformats/hashes/sha2",
238
+ "@multiformats/murmur3"
227
239
  ],
228
240
  "dynamicImports": [
229
- "chunks/src-CNab3O7M.js",
230
- "chunks/src-Bj5iE3qB.js",
231
- "chunks/src-ABfmT8J2.js"
241
+ "chunks/src-DIOHVUq9.js",
242
+ "chunks/src-ABfmT8J2.js",
243
+ "chunks/src-BSYNGtIQ.js"
232
244
  ],
233
245
  "inputs": [
234
246
  "node_modules/remeda/dist/entries.js",
@@ -246,6 +258,7 @@
246
258
  "dist/node/runtime/node/community/local-community/db-state.js",
247
259
  "dist/node/runtime/node/community/db-row-parser.js",
248
260
  "dist/node/runtime/node/community/db-handler.js",
261
+ "dist/node/runtime/node/community/local-community/unixfs-directory-patch.js",
249
262
  "dist/node/runtime/node/community/local-community/post-updates-bucket.js",
250
263
  "dist/node/runtime/node/community/local-community/comment-updates.js",
251
264
  "dist/node/runtime/node/community/local-community/cleanup.js",
@@ -262,21 +275,13 @@
262
275
  "dist/node/runtime/node/community/local-community.js"
263
276
  ]
264
277
  },
265
- "chunks/local-community-ChZZa9bm.js": {
266
- "isEntry": false,
267
- "imports": [
268
- "chunks/local-community-BlBIYSsF.js"
269
- ],
270
- "dynamicImports": [],
271
- "inputs": []
272
- },
273
- "chunks/node-BH_HrtON.js": {
278
+ "chunks/node-Br5aH83u.js": {
274
279
  "isEntry": false,
275
280
  "imports": [
276
281
  "chunks/chunk-2rV9d50f.js",
277
- "chunks/rpc-local-community-Byj5ZmMa.js",
278
- "chunks/util-CUZ1U2Go.js",
279
- "chunks/util-DmmLFRbV.js",
282
+ "chunks/rpc-local-community-Cfc2G6NP.js",
283
+ "chunks/util-Bmd1e0QJ.js",
284
+ "chunks/util-XNoDQ4hb.js",
280
285
  "path",
281
286
  "assert",
282
287
  "fs",
@@ -287,8 +292,8 @@
287
292
  "rpc-websockets"
288
293
  ],
289
294
  "dynamicImports": [
290
- "chunks/helia-for-pkc-8iett8xl.js",
291
- "chunks/local-community-BlBIYSsF.js"
295
+ "chunks/helia-for-pkc-C86lDfh5.js",
296
+ "chunks/local-community-k_ETfr57.js"
292
297
  ],
293
298
  "inputs": [
294
299
  "dist/node/zod-error-map.js",
@@ -448,22 +453,22 @@
448
453
  "dist/node/index.js"
449
454
  ]
450
455
  },
451
- "chunks/page-sort-scoring-NpdjWYfa.js": {
456
+ "chunks/page-sort-scoring-DK29vmN0.js": {
452
457
  "isEntry": false,
453
458
  "imports": [
454
- "chunks/util-CUZ1U2Go.js"
459
+ "chunks/util-Bmd1e0QJ.js"
455
460
  ],
456
461
  "dynamicImports": [],
457
462
  "inputs": [
458
463
  "dist/node/pages/page-sort-scoring.js"
459
464
  ]
460
465
  },
461
- "chunks/rpc-local-community-Byj5ZmMa.js": {
466
+ "chunks/rpc-local-community-Cfc2G6NP.js": {
462
467
  "isEntry": false,
463
468
  "imports": [
464
469
  "chunks/chunk-2rV9d50f.js",
465
- "chunks/util-CUZ1U2Go.js",
466
- "chunks/page-sort-scoring-NpdjWYfa.js",
470
+ "chunks/util-Bmd1e0QJ.js",
471
+ "chunks/page-sort-scoring-DK29vmN0.js",
467
472
  "chunks/src-CYIMjhjK.js",
468
473
  "node:crypto",
469
474
  "node:url",
@@ -488,7 +493,7 @@
488
493
  "perf_hooks"
489
494
  ],
490
495
  "dynamicImports": [
491
- "chunks/src-ltPxiZKf.js"
496
+ "chunks/src-NvrGEL7T.js"
492
497
  ],
493
498
  "inputs": [
494
499
  "dist/node/runtime/node/native-functions.js",
@@ -1160,6 +1165,14 @@
1160
1165
  "dist/node/community/rpc-local-community.js"
1161
1166
  ]
1162
1167
  },
1168
+ "chunks/src-66iuMY_4.js": {
1169
+ "isEntry": false,
1170
+ "imports": [
1171
+ "chunks/src-BSYNGtIQ.js"
1172
+ ],
1173
+ "dynamicImports": [],
1174
+ "inputs": []
1175
+ },
1163
1176
  "chunks/src-ABfmT8J2.js": {
1164
1177
  "isEntry": false,
1165
1178
  "imports": [
@@ -1188,14 +1201,6 @@
1188
1201
  "node_modules/@ipld/dag-cbor/src/index.js"
1189
1202
  ]
1190
1203
  },
1191
- "chunks/src-BC60-Q7v.js": {
1192
- "isEntry": false,
1193
- "imports": [
1194
- "chunks/src-CNab3O7M.js"
1195
- ],
1196
- "dynamicImports": [],
1197
- "inputs": []
1198
- },
1199
1204
  "chunks/src-BHqirG63.js": {
1200
1205
  "isEntry": false,
1201
1206
  "imports": [
@@ -1204,58 +1209,26 @@
1204
1209
  "dynamicImports": [],
1205
1210
  "inputs": []
1206
1211
  },
1207
- "chunks/src-Bj5iE3qB.js": {
1212
+ "chunks/src-BSYNGtIQ.js": {
1208
1213
  "isEntry": false,
1209
1214
  "imports": [
1210
1215
  "chunks/chunk-2rV9d50f.js",
1211
- "chunks/src-evzEHW9W.js",
1212
- "chunks/src-CNab3O7M.js",
1213
- "chunks/src-DKntVmyX.js",
1214
- "multiformats/cid",
1215
- "uint8arrays/from-string",
1216
- "uint8arrays/equals",
1217
- "uint8arrays/concat",
1218
- "multiformats/hashes/sha2",
1219
- "multiformats/codecs/raw",
1220
- "uint8arrays/alloc",
1221
- "@multiformats/murmur3",
1222
- "blockstore-core/black-hole"
1216
+ "multiformats/cid"
1223
1217
  ],
1224
1218
  "dynamicImports": [],
1225
1219
  "inputs": [
1226
- "node_modules/ipfs-unixfs-importer/node_modules/uint8arraylist/dist/src/index.js",
1227
- "node_modules/ipfs-unixfs-importer/dist/src/constants.js",
1228
- "node_modules/ipfs-unixfs-importer/dist/src/chunker/fixed-size.js",
1229
- "node_modules/progress-events/dist/src/index.js",
1230
- "node_modules/ipfs-unixfs-importer/dist/src/utils/persist.js",
1231
- "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/buffer-importer.js",
1232
- "node_modules/ipfs-unixfs-importer/dist/src/errors.js",
1233
- "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/dir.js",
1234
- "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/file.js",
1235
- "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/index.js",
1236
- "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/validate-chunks.js",
1237
- "node_modules/ipfs-unixfs-importer/dist/src/layout/balanced.js",
1238
- "node_modules/ipfs-unixfs-importer/dist/src/dir.js",
1239
- "node_modules/ipfs-unixfs-importer/dist/src/utils/pb-size.js",
1240
- "node_modules/ipfs-unixfs-importer/dist/src/dir-flat.js",
1241
- "node_modules/sparse-array/index.js",
1242
- "node_modules/hamt-sharding/dist/src/bucket.js",
1243
- "node_modules/hamt-sharding/dist/src/consumable-buffer.js",
1244
- "node_modules/hamt-sharding/dist/src/consumable-hash.js",
1245
- "node_modules/hamt-sharding/dist/src/index.js",
1246
- "node_modules/ipfs-unixfs-importer/dist/src/dir-sharded.js",
1247
- "node_modules/ipfs-unixfs-importer/dist/src/flat-to-shard.js",
1248
- "node_modules/ipfs-unixfs-importer/dist/src/utils/to-path-components.js",
1249
- "node_modules/ipfs-unixfs-importer/dist/src/tree-builder.js",
1250
- "node_modules/ipfs-unixfs-importer/dist/src/index.js"
1220
+ "node_modules/@ipld/dag-pb/src/pb-decode.js",
1221
+ "node_modules/@ipld/dag-pb/src/pb-encode.js",
1222
+ "node_modules/@ipld/dag-pb/src/util.js",
1223
+ "node_modules/@ipld/dag-pb/src/index.js"
1251
1224
  ]
1252
1225
  },
1253
- "chunks/src-CNab3O7M.js": {
1226
+ "chunks/src-CAvdjq_i.js": {
1254
1227
  "isEntry": false,
1255
1228
  "imports": [
1256
1229
  "uint8arrays/from-string",
1257
- "uint8arrays/alloc",
1258
- "uint8arrays/with-array-buffer"
1230
+ "uint8arrays/with-array-buffer",
1231
+ "uint8arrays/alloc"
1259
1232
  ],
1260
1233
  "dynamicImports": [],
1261
1234
  "inputs": [
@@ -1295,6 +1268,53 @@
1295
1268
  "node_modules/it-map/dist/src/index.js"
1296
1269
  ]
1297
1270
  },
1271
+ "chunks/src-DIOHVUq9.js": {
1272
+ "isEntry": false,
1273
+ "imports": [
1274
+ "chunks/chunk-2rV9d50f.js",
1275
+ "chunks/src-BSYNGtIQ.js",
1276
+ "chunks/src-CAvdjq_i.js",
1277
+ "chunks/src-DKntVmyX.js",
1278
+ "chunks/src-DeIT_BDx.js",
1279
+ "multiformats/cid",
1280
+ "uint8arrays/from-string",
1281
+ "uint8arrays/equals",
1282
+ "uint8arrays/concat",
1283
+ "multiformats/hashes/sha2",
1284
+ "@multiformats/murmur3",
1285
+ "uint8arrays/alloc",
1286
+ "multiformats/codecs/raw",
1287
+ "blockstore-core/black-hole"
1288
+ ],
1289
+ "dynamicImports": [],
1290
+ "inputs": [
1291
+ "node_modules/ipfs-unixfs-importer/node_modules/uint8arraylist/dist/src/index.js",
1292
+ "node_modules/ipfs-unixfs-importer/dist/src/constants.js",
1293
+ "node_modules/ipfs-unixfs-importer/dist/src/chunker/fixed-size.js",
1294
+ "node_modules/progress-events/dist/src/index.js",
1295
+ "node_modules/ipfs-unixfs-importer/dist/src/utils/persist.js",
1296
+ "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/buffer-importer.js",
1297
+ "node_modules/ipfs-unixfs-importer/dist/src/errors.js",
1298
+ "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/dir.js",
1299
+ "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/file.js",
1300
+ "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/index.js",
1301
+ "node_modules/ipfs-unixfs-importer/dist/src/dag-builder/validate-chunks.js",
1302
+ "node_modules/ipfs-unixfs-importer/dist/src/layout/balanced.js",
1303
+ "node_modules/ipfs-unixfs-importer/dist/src/dir.js",
1304
+ "node_modules/ipfs-unixfs-importer/dist/src/utils/pb-size.js",
1305
+ "node_modules/ipfs-unixfs-importer/dist/src/dir-flat.js",
1306
+ "node_modules/sparse-array/index.js",
1307
+ "node_modules/hamt-sharding/dist/src/bucket.js",
1308
+ "node_modules/hamt-sharding/dist/src/consumable-buffer.js",
1309
+ "node_modules/hamt-sharding/dist/src/consumable-hash.js",
1310
+ "node_modules/hamt-sharding/dist/src/index.js",
1311
+ "node_modules/ipfs-unixfs-importer/dist/src/dir-sharded.js",
1312
+ "node_modules/ipfs-unixfs-importer/dist/src/flat-to-shard.js",
1313
+ "node_modules/ipfs-unixfs-importer/dist/src/utils/to-path-components.js",
1314
+ "node_modules/ipfs-unixfs-importer/dist/src/tree-builder.js",
1315
+ "node_modules/ipfs-unixfs-importer/dist/src/index.js"
1316
+ ]
1317
+ },
1298
1318
  "chunks/src-DKntVmyX.js": {
1299
1319
  "isEntry": false,
1300
1320
  "imports": [],
@@ -1304,28 +1324,22 @@
1304
1324
  "node_modules/it-parallel-batch/dist/src/index.js"
1305
1325
  ]
1306
1326
  },
1307
- "chunks/src-evzEHW9W.js": {
1327
+ "chunks/src-DeIT_BDx.js": {
1308
1328
  "isEntry": false,
1309
- "imports": [
1310
- "chunks/chunk-2rV9d50f.js",
1311
- "multiformats/cid"
1312
- ],
1329
+ "imports": [],
1313
1330
  "dynamicImports": [],
1314
1331
  "inputs": [
1315
- "node_modules/it-first/dist/src/index.js",
1316
- "node_modules/@ipld/dag-pb/src/pb-decode.js",
1317
- "node_modules/@ipld/dag-pb/src/pb-encode.js",
1318
- "node_modules/@ipld/dag-pb/src/util.js",
1319
- "node_modules/@ipld/dag-pb/src/index.js"
1332
+ "node_modules/it-first/dist/src/index.js"
1320
1333
  ]
1321
1334
  },
1322
- "chunks/src-ltPxiZKf.js": {
1335
+ "chunks/src-NvrGEL7T.js": {
1323
1336
  "isEntry": false,
1324
1337
  "imports": [
1325
1338
  "chunks/chunk-2rV9d50f.js",
1326
1339
  "chunks/src-ABfmT8J2.js",
1327
- "chunks/src-evzEHW9W.js",
1340
+ "chunks/src-BSYNGtIQ.js",
1328
1341
  "chunks/src-CYIMjhjK.js",
1342
+ "chunks/src-DeIT_BDx.js",
1329
1343
  "chunks/src-Cpx2Sts8.js",
1330
1344
  "node:http",
1331
1345
  "node:crypto",
@@ -1576,7 +1590,7 @@
1576
1590
  "node_modules/kubo-rpc-client/dist/src/index.js"
1577
1591
  ]
1578
1592
  },
1579
- "chunks/util-CUZ1U2Go.js": {
1593
+ "chunks/util-Bmd1e0QJ.js": {
1580
1594
  "isEntry": false,
1581
1595
  "imports": [
1582
1596
  "chunks/chunk-2rV9d50f.js",
@@ -1590,7 +1604,7 @@
1590
1604
  "multiformats/bases/base32"
1591
1605
  ],
1592
1606
  "dynamicImports": [
1593
- "chunks/src-Bj5iE3qB.js"
1607
+ "chunks/src-DIOHVUq9.js"
1594
1608
  ],
1595
1609
  "inputs": [
1596
1610
  "node_modules/zod/v4/core/util.js",
@@ -1671,10 +1685,10 @@
1671
1685
  "dist/node/util.js"
1672
1686
  ]
1673
1687
  },
1674
- "chunks/util-DmmLFRbV.js": {
1688
+ "chunks/util-XNoDQ4hb.js": {
1675
1689
  "isEntry": false,
1676
1690
  "imports": [
1677
- "chunks/util-CUZ1U2Go.js",
1691
+ "chunks/util-Bmd1e0QJ.js",
1678
1692
  "ipns/selector",
1679
1693
  "ipns/validator",
1680
1694
  "ipns",
@@ -1686,11 +1700,11 @@
1686
1700
  "dist/node/helia/util.js"
1687
1701
  ]
1688
1702
  },
1689
- "chunks/validate-package-factories-CkU4qFQx.js": {
1703
+ "chunks/validate-package-factories-evt2DaRs.js": {
1690
1704
  "isEntry": false,
1691
1705
  "imports": [
1692
- "chunks/util-CUZ1U2Go.js",
1693
- "chunks/page-sort-scoring-NpdjWYfa.js"
1706
+ "chunks/util-Bmd1e0QJ.js",
1707
+ "chunks/page-sort-scoring-DK29vmN0.js"
1694
1708
  ],
1695
1709
  "dynamicImports": [],
1696
1710
  "inputs": [
@@ -1,2 +1,2 @@
1
- import { t as validateChallengeFileFactory } from "./chunks/validate-package-factories-CkU4qFQx.js";
1
+ import { t as validateChallengeFileFactory } from "./chunks/validate-package-factories-evt2DaRs.js";
2
2
  export { validateChallengeFileFactory };
@@ -1,6 +1,6 @@
1
1
  import { i as __toESM, r as __require, t as __commonJSMin } from "./chunk-2rV9d50f.js";
2
- import { Br as logger_default, C as hideClassPrivateProps, Rr as PKCError, T as ipnsNameToIpnsOverPubsubTopic, n as binaryKeyToPubsubTopic } from "./util-CUZ1U2Go.js";
3
- import { a as directFetchIpnsRecordFromProviders, c as readFreshCachedIpnsRecordFromPubsubLocalStore, i as connectToPubsubPeers, l as selectBitswapSessionSeedPeers, n as REACHABILITY_DOCS_URL, o as fetchBlockWithStalledSessionFailover, r as cacheIpnsRecordInPubsubLocalStore, s as getHeliaDebugContext, u as summarizeProviderReachability } from "./util-DmmLFRbV.js";
2
+ import { C as hideClassPrivateProps, Lr as PKCError, T as ipnsNameToIpnsOverPubsubTopic, n as binaryKeyToPubsubTopic, zr as logger_default } from "./util-Bmd1e0QJ.js";
3
+ import { a as directFetchIpnsRecordFromProviders, c as readFreshCachedIpnsRecordFromPubsubLocalStore, i as connectToPubsubPeers, l as selectBitswapSessionSeedPeers, n as REACHABILITY_DOCS_URL, o as fetchBlockWithStalledSessionFailover, r as cacheIpnsRecordInPubsubLocalStore, s as getHeliaDebugContext, u as summarizeProviderReachability } from "./util-XNoDQ4hb.js";
4
4
  import { t as map } from "./src-Cpx2Sts8.js";
5
5
  import { t as parallelBatch } from "./src-DKntVmyX.js";
6
6
  import { fileURLToPath } from "node:url";
@@ -17,13 +17,13 @@ import { ipnsValidator } from "ipns/validator";
17
17
  import { multihashToIPNSRoutingKey, unmarshalIPNSRecord } from "ipns";
18
18
  import { equals } from "uint8arrays/equals";
19
19
  import { circuitRelayAddressesLast, loopbackAddressLast, publicAddressesFirst, reliableTransportsFirst } from "@libp2p/utils";
20
+ import { sha512 } from "multiformats/hashes/sha2";
20
21
  import { createHeliaLight } from "helia";
21
22
  import { libp2pDefaults, withLibp2p } from "@helia/libp2p";
22
23
  import { withBitswap } from "@helia/bitswap";
23
24
  import { ipns, pubSubIPNSRouting } from "@helia/ipns";
24
25
  import { gossipsub } from "@libp2p/gossipsub";
25
26
  import { identify } from "@libp2p/identify";
26
- import { sha512 } from "multiformats/hashes/sha2";
27
27
  import { MemoryBlockstore } from "blockstore-core";
28
28
  import * as raw from "multiformats/codecs/raw";
29
29
  import { delegatedRoutingV1HttpApiClientContentRouting } from "@helia/delegated-routing-v1-http-api-client";
@@ -6661,6 +6661,53 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
6661
6661
  }, ms);
6662
6662
  signal.addEventListener("abort", onAbort, { once: true });
6663
6663
  });
6664
+ const createNoProvidersRetryWaiter = (rootCid, signal) => {
6665
+ let wantController;
6666
+ let rootBlockArrived;
6667
+ let arrived = false;
6668
+ let earlyWakeUsed = false;
6669
+ const abortWant = () => wantController?.abort(signal.reason);
6670
+ const startWant = () => {
6671
+ wantController = new AbortController();
6672
+ if (signal.aborted) abortWant();
6673
+ else signal.addEventListener("abort", abortWant, { once: true });
6674
+ const wantSignal = wantController.signal;
6675
+ rootBlockArrived = (async () => {
6676
+ for await (const _chunk of helia.blockstore.get(rootCid, { signal: wantSignal }));
6677
+ arrived = true;
6678
+ })().catch((error) => {
6679
+ if (!wantSignal.aborted) log.trace("Broadcast want for", String(rootCid), "failed, keeping the retry backoff", error);
6680
+ return new Promise(() => {});
6681
+ });
6682
+ };
6683
+ return {
6684
+ async wait(attempt) {
6685
+ const delayMs = Math.min(SESSION_NO_PROVIDERS_RETRY_BASE_DELAY_MS * 2 ** attempt, 8e3);
6686
+ if (signal.aborted) return;
6687
+ if (!rootBlockArrived) startWant();
6688
+ if (earlyWakeUsed) return delayAbortable(delayMs, signal);
6689
+ if (!arrived) {
6690
+ const endDelay = new AbortController();
6691
+ const endDelayOnAbort = () => endDelay.abort();
6692
+ signal.addEventListener("abort", endDelayOnAbort, { once: true });
6693
+ try {
6694
+ await Promise.race([delayAbortable(delayMs, endDelay.signal), rootBlockArrived]);
6695
+ } finally {
6696
+ signal.removeEventListener("abort", endDelayOnAbort);
6697
+ endDelay.abort();
6698
+ }
6699
+ }
6700
+ if (arrived) {
6701
+ earlyWakeUsed = true;
6702
+ log.trace("Root block", String(rootCid), "arrived through the broadcast want, retrying the session now");
6703
+ }
6704
+ },
6705
+ stop() {
6706
+ signal.removeEventListener("abort", abortWant);
6707
+ wantController?.abort();
6708
+ }
6709
+ };
6710
+ };
6664
6711
  const createSeededBitswapSession = (rootCid, scopeIpnsPubsubTopic) => {
6665
6712
  const session = helia.blockstore.createSession(rootCid, { providers: getBitswapSessionSeedPeers(scopeIpnsPubsubTopic).map((peerId) => peerId.toCID()) });
6666
6713
  const sessionGet = session.get.bind(session);
@@ -6750,6 +6797,7 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
6750
6797
  log.error("An IPNS record arrival listener threw for topic", pubsubTopic, e);
6751
6798
  }
6752
6799
  };
6800
+ const stopController = new AbortController();
6753
6801
  const WARMUP_MAX_PEERS = 4;
6754
6802
  const warmupPromisesByTopic = /* @__PURE__ */ new Map();
6755
6803
  const warmupForTopic = (topic, options) => {
@@ -6761,6 +6809,7 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
6761
6809
  pubsubTopic: topic,
6762
6810
  maxPeers: WARMUP_MAX_PEERS,
6763
6811
  options,
6812
+ stopSignal: stopController.signal,
6764
6813
  log: logger_default("pkc-js:helia:pubsub:warmup")
6765
6814
  }).then(() => void 0).finally(() => {
6766
6815
  warmupPromisesByTopic.delete(topic);
@@ -6775,7 +6824,6 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
6775
6824
  ...getHeliaDebugContext(helia)
6776
6825
  });
6777
6826
  };
6778
- const catStopController = new AbortController();
6779
6827
  const inFlightCats = /* @__PURE__ */ new Set();
6780
6828
  const IN_FLIGHT_CATS_UNWIND_TIMEOUT_MS = 5e3;
6781
6829
  const heliaWithKuboRpcClientShape = {
@@ -6948,8 +6996,8 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
6948
6996
  ipfsPath,
6949
6997
  ...getHeliaDebugContext(helia)
6950
6998
  }));
6951
- if (catStopController.signal.aborted) abortFromStop();
6952
- else catStopController.signal.addEventListener("abort", abortFromStop, { once: true });
6999
+ if (stopController.signal.aborted) abortFromStop();
7000
+ else stopController.signal.addEventListener("abort", abortFromStop, { once: true });
6953
7001
  let markUnwound;
6954
7002
  const unwound = new Promise((resolve) => markUnwound = resolve);
6955
7003
  inFlightCats.add(unwound);
@@ -6957,6 +7005,7 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
6957
7005
  ipfsPath,
6958
7006
  timeoutMs
6959
7007
  })), timeoutMs) : void 0;
7008
+ const noProvidersRetryWaiter = createNoProvidersRetryWaiter(rootCid, controller.signal);
6960
7009
  try {
6961
7010
  for (let attempt = 0;; attempt++) {
6962
7011
  const session = createSeededBitswapSession(rootCid, bitswapSessionSeedScopeIpnsPubsubTopic);
@@ -6979,7 +7028,7 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
6979
7028
  } finally {
6980
7029
  session.close();
6981
7030
  }
6982
- await delayAbortable(Math.min(SESSION_NO_PROVIDERS_RETRY_BASE_DELAY_MS * 2 ** attempt, 8e3), controller.signal);
7031
+ await noProvidersRetryWaiter.wait(attempt);
6983
7032
  if (controller.signal.aborted) {
6984
7033
  if (controller.signal.reason instanceof Error) throw controller.signal.reason;
6985
7034
  throw new PKCError("ERR_FETCH_CID_P2P_TIMEOUT", {
@@ -6989,9 +7038,10 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
6989
7038
  }
6990
7039
  }
6991
7040
  } finally {
7041
+ noProvidersRetryWaiter.stop();
6992
7042
  if (timeoutTimer !== void 0) clearTimeout(timeoutTimer);
6993
7043
  callerSignal?.removeEventListener("abort", abortFromCallerSignal);
6994
- catStopController.signal.removeEventListener("abort", abortFromStop);
7044
+ stopController.signal.removeEventListener("abort", abortFromStop);
6995
7045
  inFlightCats.delete(unwound);
6996
7046
  markUnwound();
6997
7047
  }
@@ -7044,8 +7094,8 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
7044
7094
  }));
7045
7095
  if (callerSignal?.aborted) abortFromCaller();
7046
7096
  else callerSignal?.addEventListener("abort", abortFromCaller, { once: true });
7047
- if (catStopController.signal.aborted) abortFromStop();
7048
- else catStopController.signal.addEventListener("abort", abortFromStop, { once: true });
7097
+ if (stopController.signal.aborted) abortFromStop();
7098
+ else stopController.signal.addEventListener("abort", abortFromStop, { once: true });
7049
7099
  const timeoutTimer = timeoutMs !== void 0 ? setTimeout(() => controller.abort(new PKCError("ERR_FETCH_CID_P2P_TIMEOUT", {
7050
7100
  ipfsPath,
7051
7101
  timeoutMs
@@ -7078,7 +7128,7 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
7078
7128
  } finally {
7079
7129
  if (timeoutTimer) clearTimeout(timeoutTimer);
7080
7130
  callerSignal?.removeEventListener("abort", abortFromCaller);
7081
- catStopController.signal.removeEventListener("abort", abortFromStop);
7131
+ stopController.signal.removeEventListener("abort", abortFromStop);
7082
7132
  }
7083
7133
  },
7084
7134
  async add(entry, options) {
@@ -7118,7 +7168,7 @@ async function createLibp2pJsClientOrUseExistingOne(pkcOptions) {
7118
7168
  }
7119
7169
  }
7120
7170
  for (const topic of helia.libp2p.services.pubsub.getTopics()) helia.libp2p.services.pubsub.unsubscribe(topic);
7121
- catStopController.abort();
7171
+ stopController.abort();
7122
7172
  if (inFlightCats.size > 0) {
7123
7173
  const unwindTimeout = new AbortController();
7124
7174
  const allUnwound = Promise.all([...inFlightCats]).then(() => "unwound");
@@ -1,2 +1,2 @@
1
- import { n as createNewLocalCommunityDb, r as updateInstancePropsWithStartedCommunityOrDb, t as LocalCommunity } from "./local-community-BlBIYSsF.js";
1
+ import { n as createNewLocalCommunityDb, r as updateInstancePropsWithStartedCommunityOrDb, t as LocalCommunity } from "./local-community-k_ETfr57.js";
2
2
  export { LocalCommunity, createNewLocalCommunityDb, updateInstancePropsWithStartedCommunityOrDb };