@pkcprotocol/pkc-js 0.0.76 → 0.0.78
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/browser/errors.d.ts +1 -1
- package/dist/browser/errors.js +1 -1
- package/dist/browser/errors.js.map +1 -1
- package/dist/browser/generated-version.d.ts +1 -1
- package/dist/browser/generated-version.js +1 -1
- package/dist/browser/runtime/node/community/local-community/cleanup.d.ts +2 -1
- package/dist/browser/runtime/node/community/local-community/cleanup.js +81 -30
- package/dist/browser/runtime/node/community/local-community/cleanup.js.map +1 -1
- package/dist/browser/runtime/node/community/local-community/comment-updates.js +5 -0
- package/dist/browser/runtime/node/community/local-community/comment-updates.js.map +1 -1
- package/dist/browser/runtime/node/community/local-community/ipns-publishing.js +11 -28
- package/dist/browser/runtime/node/community/local-community/ipns-publishing.js.map +1 -1
- package/dist/browser/runtime/node/setup-kubo-address-rewriter-and-http-router.js +21 -3
- package/dist/browser/runtime/node/setup-kubo-address-rewriter-and-http-router.js.map +1 -1
- package/dist/browser/util.js +13 -4
- package/dist/browser/util.js.map +1 -1
- package/dist/bundled/bundle-manifest.json +31 -31
- package/dist/bundled/chunks/{helia-for-pkc-cKp6JSwA.js → helia-for-pkc-DPyYKV_m.js} +33 -33
- package/dist/bundled/chunks/{local-community-DerKPzJm.js → local-community-DS4PU-HF.js} +1 -1
- package/dist/bundled/chunks/{local-community-B3Fhrtiy.js → local-community-KNlSpG2e.js} +80 -62
- package/dist/bundled/chunks/{node-DffqRPit.js → node-CcPI4aNc.js} +12 -7
- package/dist/bundled/chunks/{rpc-local-community-BdNiruAf.js → rpc-local-community-DHhucg8-.js} +17 -17
- package/dist/bundled/chunks/{schema-BvBJX6m7.js → schema-CH2yoI0b.js} +10 -6
- package/dist/bundled/chunks/{util-BRxHPb9G.js → util-CiBeiLBn.js} +1 -1
- package/dist/bundled/index.js +1 -1
- package/dist/bundled/rpc/src/index.js +4 -4
- package/dist/node/errors.d.ts +1 -1
- package/dist/node/errors.js +1 -1
- package/dist/node/errors.js.map +1 -1
- package/dist/node/generated-version.d.ts +1 -1
- package/dist/node/generated-version.js +1 -1
- package/dist/node/runtime/node/community/local-community/cleanup.d.ts +2 -1
- package/dist/node/runtime/node/community/local-community/cleanup.js +81 -30
- package/dist/node/runtime/node/community/local-community/cleanup.js.map +1 -1
- package/dist/node/runtime/node/community/local-community/comment-updates.js +5 -0
- package/dist/node/runtime/node/community/local-community/comment-updates.js.map +1 -1
- package/dist/node/runtime/node/community/local-community/ipns-publishing.js +11 -28
- package/dist/node/runtime/node/community/local-community/ipns-publishing.js.map +1 -1
- package/dist/node/runtime/node/setup-kubo-address-rewriter-and-http-router.js +21 -3
- package/dist/node/runtime/node/setup-kubo-address-rewriter-and-http-router.js.map +1 -1
- package/dist/node/util.js +13 -4
- package/dist/node/util.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { i as __toESM, r as __require, t as __commonJSMin } from "./chunk-2rV9d50f.js";
|
|
2
|
-
import { $ as pubsubTopicToDhtKey, $n as n$3, An as CommentsTableRowSchema, At as trackStartedCommunity, Bn as CommentEditsTableRowSchema, Bt as CommunityEditPublicationPubsubReservedFields, C as contentContainsMarkdownAudio, Ct as findUpdatingCommunity, Dn as CommentUpdateSchema, F as getIpnsRecordInLocalKuboNode, Ft as untrackUpdatingCommunity, G as isLinkOfAudio, Gt as CommentModerationPubsubMessagePublicationSchema, In as CommentEditPubsubMessagePublicationSchema, It as require_sha256, J as isLinkOfVideo, Jt as CommentModerationsTableRowSchema, K as isLinkOfImage, Kt as CommentModerationReservedFields, L as hideClassPrivateProps, Ln as CommentEditPubsubMessagePublicationWithFlexibleAuthorSchema, M as genToArray, Mt as trackUpdatingCommunity, N as getEquivalentCommunityAddresses, Nr as ZodError, Nt as untrackStartedCommunity, O as derivePublicationFromChallengeRequest, P as getErrorCodeFromMessage, Q as isStringDomain, Qn as t$8, R as ipnsNameToIpnsOverPubsubTopic, Rn as CommentEditReservedFields,
|
|
3
|
-
import { $n as t$11, A as deriveCommentIpfsFromCommentTableRow, At as verifyCommunity, B as resolveDbPostsCidRefs, Bt as getCommunityNameFromWire, C as encryptEd25519AesGcmPublicKeyBuffer, Ct as verifyChallengeRequest, D as calculateInlineRepliesBudget, Dt as verifyCommentModeration, E as calculateExpectedSignatureSize, Et as verifyCommentIpfs, F as getThumbnailPropsOfLink, G as POST_REPLIES_SORT_TYPES, I as importSignerIntoKuboNode, It as getAuthorNameFromWire, Jt as getPKCAddressFromPublicKeySync, K as REPLY_REPLIES_SORT_TYPES, Kt as getIpfsKeyFromPrivateKey, M as deriveDbReplies, Mt as verifyVote, N as getDefaultCommunityDbConfig, Nt as buildRuntimeAuthor, Ot as verifyCommentPubsubMessage, Pt as cleanWireAuthor, Q as iterateOverPageCidsToFindAllCids, Qn as r$2, Sn as parseJsonWithPKCErrorIfFails, T as backupCommunityDb, Tt as verifyCommentEdit, Ut as decode, Vt as getCommunityPublicKeyFromWire, W as POSTS_SORT_TYPES, Wt as encode, Xn as t$9, Xt as createSchemaRowParser, Yt as getPublicKeyFromPrivateKey, Zn as t$12, _ as SignerWithPublicKeyAddress, _t as signCommentUpdateForChallengeVerification, a as pkcJsChallenges, ar as STORAGE_KEYS, at as pLimit, ct as cleanUpBeforePublishing, d as MAX_FILE_SIZE_BYTES_FOR_COMMUNITY_IPFS, er as n$6, f as KeyvBetterSqlite3, ft as signChallengeVerification, gt as signCommentUpdate, i as getCommunityChallengeFromCommunityChallengeSettings, ir as stringify, j as deriveDbPosts, jt as verifyCommunityEdit, k as deleteOldCommunityInWindows, kt as verifyCommentUpdate, l as normalizeSelfAddrsForProvider, ln as parseCommunityIpfsSchemaPassthroughWithPKCErrorIfItFails, mt as signCommentEdit, o as TrackedInstanceRegistry, or as require_lodash_merge, pt as signComment, q as TIMEFRAMES_TO_SECONDS, qt as getPKCAddressFromPublicKey, r as getChallengeVerification, rr as t$10, s as LRUCache, sn as parseCommunityEditOptionsSchemaWithPKCErrorIfItFails, t as RpcLocalCommunity, tr as n$5, ut as signChallengeMessage, vt as signCommunity, w as BackupAbortError, x as decryptEd25519AesGcmPublicKeyBuffer, xt as verifyChallengeAnswer, yn as parseDecryptedChallengeAnswerWithPKCErrorIfItFails, z as moveCommunityDbToDeletedDirectory } from "./rpc-local-community-
|
|
2
|
+
import { $ as pubsubTopicToDhtKey, $n as n$3, An as CommentsTableRowSchema, At as trackStartedCommunity, Bn as CommentEditsTableRowSchema, Bt as CommunityEditPublicationPubsubReservedFields, C as contentContainsMarkdownAudio, Ct as findUpdatingCommunity, Dn as CommentUpdateSchema, F as getIpnsRecordInLocalKuboNode, Ft as untrackUpdatingCommunity, G as isLinkOfAudio, Gt as CommentModerationPubsubMessagePublicationSchema, In as CommentEditPubsubMessagePublicationSchema, It as require_sha256, J as isLinkOfVideo, Jt as CommentModerationsTableRowSchema, K as isLinkOfImage, Kt as CommentModerationReservedFields, L as hideClassPrivateProps, Ln as CommentEditPubsubMessagePublicationWithFlexibleAuthorSchema, M as genToArray, Mt as trackUpdatingCommunity, N as getEquivalentCommunityAddresses, Nr as ZodError, Nt as untrackStartedCommunity, O as derivePublicationFromChallengeRequest, P as getErrorCodeFromMessage, Q as isStringDomain, Qn as t$8, R as ipnsNameToIpnsOverPubsubTopic, Rn as CommentEditReservedFields, S as calculateStringSizeSameAsIpfsAddCidV0, T as contentContainsMarkdownVideos, W as isLinkOfAnimatedImage, Wn as AuthorReservedFields, Y as isLinkValid, Zn as n$4, _t as timestamp, a as ChallengeRequestMessageSchema, ar as r$1, at as removeNullUndefinedValues, b as areEquivalentCommunityAddresses, bn as CommentPubsubMessageReservedFields, br as logger_default, bt as findCommunityInRegistry, d as DecryptedChallengeRequestSchema, dt as retryKuboIpfsAddAndProvide, er as t$7, fr as require_retry, gn as VoteTablesRowSchema, ht as statMfsPathSafely, in as CommunitySignedPropertyNames, k as doesDomainAddressHaveCapitalLetter, kn as CommentUpdateTableRowSchema, kt as syncCommunityRegistryEntry, lr as t$5, lt as retryKuboBlockPutPinAndProvidePubsubTopic, mn as VotePubsubReservedFields, mt as sleepUntilTimeoutOrAbort, nr as e, nt as removeBlocksFromKuboNode, or as t$4, pn as VotePubsubMessagePublicationSchema, q as isLinkOfMedia, r as ChallengeMessageSchema, rn as CommunityIpfsSchema, rr as e$1, rt as removeMfsFilesSafely, s as ChallengeVerificationMessageSchema, t as ChallengeAnswerMessageSchema, tr as t$6, u as DecryptedChallengeRequestPublicationSchema, ur as t$3, vr as PKCError, w as contentContainsMarkdownImages, x as calculateIpfsCidV0, xt as findStartedCommunity, y as version_default, yn as CommentIpfsSchema, yr as messages, yt as writeKuboFilesWithTimeout } from "./schema-CH2yoI0b.js";
|
|
3
|
+
import { $n as t$11, A as deriveCommentIpfsFromCommentTableRow, At as verifyCommunity, B as resolveDbPostsCidRefs, Bt as getCommunityNameFromWire, C as encryptEd25519AesGcmPublicKeyBuffer, Ct as verifyChallengeRequest, D as calculateInlineRepliesBudget, Dt as verifyCommentModeration, E as calculateExpectedSignatureSize, Et as verifyCommentIpfs, F as getThumbnailPropsOfLink, G as POST_REPLIES_SORT_TYPES, I as importSignerIntoKuboNode, It as getAuthorNameFromWire, Jt as getPKCAddressFromPublicKeySync, K as REPLY_REPLIES_SORT_TYPES, Kt as getIpfsKeyFromPrivateKey, M as deriveDbReplies, Mt as verifyVote, N as getDefaultCommunityDbConfig, Nt as buildRuntimeAuthor, Ot as verifyCommentPubsubMessage, Pt as cleanWireAuthor, Q as iterateOverPageCidsToFindAllCids, Qn as r$2, Sn as parseJsonWithPKCErrorIfFails, T as backupCommunityDb, Tt as verifyCommentEdit, Ut as decode, Vt as getCommunityPublicKeyFromWire, W as POSTS_SORT_TYPES, Wt as encode, Xn as t$9, Xt as createSchemaRowParser, Yt as getPublicKeyFromPrivateKey, Zn as t$12, _ as SignerWithPublicKeyAddress, _t as signCommentUpdateForChallengeVerification, a as pkcJsChallenges, ar as STORAGE_KEYS, at as pLimit, ct as cleanUpBeforePublishing, d as MAX_FILE_SIZE_BYTES_FOR_COMMUNITY_IPFS, er as n$6, f as KeyvBetterSqlite3, ft as signChallengeVerification, gt as signCommentUpdate, i as getCommunityChallengeFromCommunityChallengeSettings, ir as stringify, j as deriveDbPosts, jt as verifyCommunityEdit, k as deleteOldCommunityInWindows, kt as verifyCommentUpdate, l as normalizeSelfAddrsForProvider, ln as parseCommunityIpfsSchemaPassthroughWithPKCErrorIfItFails, mt as signCommentEdit, o as TrackedInstanceRegistry, or as require_lodash_merge, pt as signComment, q as TIMEFRAMES_TO_SECONDS, qt as getPKCAddressFromPublicKey, r as getChallengeVerification, rr as t$10, s as LRUCache, sn as parseCommunityEditOptionsSchemaWithPKCErrorIfItFails, t as RpcLocalCommunity, tr as n$5, ut as signChallengeMessage, vt as signCommunity, w as BackupAbortError, x as decryptEd25519AesGcmPublicKeyBuffer, xt as verifyChallengeAnswer, yn as parseDecryptedChallengeAnswerWithPKCErrorIfItFails, z as moveCommunityDbToDeletedDirectory } from "./rpc-local-community-DHhucg8-.js";
|
|
4
4
|
import { randomFillSync, randomUUID } from "node:crypto";
|
|
5
5
|
import { fileURLToPath, pathToFileURL } from "node:url";
|
|
6
|
-
import
|
|
6
|
+
import path from "node:path";
|
|
7
7
|
import os from "os";
|
|
8
8
|
import { existsSync, promises } from "node:fs";
|
|
9
|
-
import path from "path";
|
|
9
|
+
import path$1 from "path";
|
|
10
10
|
import assert from "assert";
|
|
11
11
|
import fs from "fs";
|
|
12
12
|
import Database from "better-sqlite3";
|
|
@@ -468,28 +468,64 @@ async function repinCommentUpdateIfNeeded(community) {
|
|
|
468
468
|
log(`CommentUpdate directory`, community.address, "will republish all comment updates");
|
|
469
469
|
community._dbHandler.forceUpdateOnAllComments();
|
|
470
470
|
}
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
471
|
+
const GC_HIGH_WATERMARK = .9;
|
|
472
|
+
const MIN_MS_BETWEEN_GC = 3600 * 1e3;
|
|
473
|
+
const lastGcFinishedAtByKuboUrl = /* @__PURE__ */ new Map();
|
|
474
|
+
const inFlightGcByKuboUrl = /* @__PURE__ */ new Map();
|
|
475
|
+
async function cleanUpIpfsRepoIfDue(community, force = false) {
|
|
476
|
+
const log = logger_default("pkc-js:local-community:syncIpnsWithDb:_cleanUpIpfsRepoIfDue");
|
|
477
|
+
const kuboRpc = community._clientsManager.getDefaultKuboRpcClient();
|
|
478
|
+
const kuboUrl = String(kuboRpc.url);
|
|
479
|
+
const inFlight = inFlightGcByKuboUrl.get(kuboUrl);
|
|
480
|
+
if (inFlight) return inFlight;
|
|
481
|
+
const gcRun = _runRepoGcIfDue({
|
|
482
|
+
community,
|
|
483
|
+
kuboUrl,
|
|
484
|
+
force,
|
|
485
|
+
log
|
|
486
|
+
}).finally(() => inFlightGcByKuboUrl.delete(kuboUrl));
|
|
487
|
+
inFlightGcByKuboUrl.set(kuboUrl, gcRun);
|
|
488
|
+
return gcRun;
|
|
489
|
+
}
|
|
490
|
+
async function _runRepoGcIfDue({ community, kuboUrl, force, log }) {
|
|
491
|
+
const kuboRpc = community._clientsManager.getDefaultKuboRpcClient();
|
|
492
|
+
let repoSizeBefore;
|
|
493
|
+
if (!force) {
|
|
494
|
+
const lastGcFinishedAt = lastGcFinishedAtByKuboUrl.get(kuboUrl);
|
|
495
|
+
if (typeof lastGcFinishedAt === "number" && Date.now() - lastGcFinishedAt < MIN_MS_BETWEEN_GC) return;
|
|
496
|
+
let repoStat;
|
|
476
497
|
try {
|
|
477
|
-
await
|
|
478
|
-
milliseconds: 15e3,
|
|
479
|
-
message: "Timed out flushing MFS root before repo.gc"
|
|
480
|
-
});
|
|
498
|
+
repoStat = await kuboRpc._client.repo.stat({ searchParams: new URLSearchParams({ "size-only": "true" }) });
|
|
481
499
|
} catch (e) {
|
|
482
|
-
log.error("Skipping repo.gc: failed to
|
|
500
|
+
log.error("Skipping repo.gc: failed to read repo.stat from the kubo node", kuboUrl, e);
|
|
483
501
|
return;
|
|
484
502
|
}
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
503
|
+
repoSizeBefore = repoStat.repoSize;
|
|
504
|
+
if (repoStat.storageMax > 0n) {
|
|
505
|
+
const gcThreshold = repoStat.storageMax * BigInt(Math.round(GC_HIGH_WATERMARK * 100)) / 100n;
|
|
506
|
+
if (repoStat.repoSize < gcThreshold) {
|
|
507
|
+
log.trace("Skipping repo.gc on", kuboUrl, "- repo size", repoStat.repoSize, "is below the", `${GC_HIGH_WATERMARK * 100}%`, "watermark", gcThreshold, "of StorageMax", repoStat.storageMax);
|
|
508
|
+
return;
|
|
509
|
+
}
|
|
490
510
|
}
|
|
491
|
-
log("GC cleaned", gcCids, "cids out of the IPFS node");
|
|
492
511
|
}
|
|
512
|
+
let gcCids = 0;
|
|
513
|
+
try {
|
|
514
|
+
for await (const res of kuboRpc._client.repo.gc({ quiet: true })) if (res.cid) gcCids++;
|
|
515
|
+
else log.error("Failed to GC ipfs repo due to error", res.err);
|
|
516
|
+
} catch (e) {
|
|
517
|
+
log.error("Failed to GC ipfs repo due to error", e);
|
|
518
|
+
return;
|
|
519
|
+
} finally {
|
|
520
|
+
lastGcFinishedAtByKuboUrl.set(kuboUrl, Date.now());
|
|
521
|
+
}
|
|
522
|
+
let repoSizeAfter;
|
|
523
|
+
try {
|
|
524
|
+
repoSizeAfter = (await kuboRpc._client.repo.stat({ searchParams: new URLSearchParams({ "size-only": "true" }) })).repoSize;
|
|
525
|
+
} catch (e) {
|
|
526
|
+
log.trace("repo.gc finished but the follow-up repo.stat failed", e);
|
|
527
|
+
}
|
|
528
|
+
log("GC cleaned", gcCids, "cids out of the IPFS node", kuboUrl, "- repo size", repoSizeBefore ?? "unknown", "->", repoSizeAfter ?? "unknown");
|
|
493
529
|
}
|
|
494
530
|
async function addAllCidsUnderPurgedCommentToBeRemoved(community, purgedCommentAndCommentUpdate) {
|
|
495
531
|
community._cidsToUnPin.add(purgedCommentAndCommentUpdate.commentTableRow.cid);
|
|
@@ -3416,9 +3452,9 @@ var DbHandler = class {
|
|
|
3416
3452
|
if (needToMigrate) {
|
|
3417
3453
|
if (dbExistsAlready && currentDbVersion > 0) {
|
|
3418
3454
|
this.destoryConnection();
|
|
3419
|
-
backupDbPath = path.join(path.dirname(dbPath), ".backup_before_migration", `${path.basename(dbPath)}.${currentDbVersion}.${timestamp()}`);
|
|
3420
|
-
log(`Copying db ${path.basename(dbPath)} to ${backupDbPath} before migration`);
|
|
3421
|
-
if (!fs.existsSync(path.dirname(backupDbPath))) await fs.promises.mkdir(path.dirname(backupDbPath), { recursive: true });
|
|
3455
|
+
backupDbPath = path$1.join(path$1.dirname(dbPath), ".backup_before_migration", `${path$1.basename(dbPath)}.${currentDbVersion}.${timestamp()}`);
|
|
3456
|
+
log(`Copying db ${path$1.basename(dbPath)} to ${backupDbPath} before migration`);
|
|
3457
|
+
if (!fs.existsSync(path$1.dirname(backupDbPath))) await fs.promises.mkdir(path$1.dirname(backupDbPath), { recursive: true });
|
|
3422
3458
|
const sourceDb = new Database(dbPath, { fileMustExist: true });
|
|
3423
3459
|
await sourceDb.backup(backupDbPath);
|
|
3424
3460
|
sourceDb.close();
|
|
@@ -5229,10 +5265,10 @@ var DbHandler = class {
|
|
|
5229
5265
|
if (this._db || this._keyv) await this.destoryConnection();
|
|
5230
5266
|
this._transactionDepth = 0;
|
|
5231
5267
|
const dataPath = this._community._pkc.dataPath;
|
|
5232
|
-
const oldPathString = path.join(dataPath, "communities", oldDbName);
|
|
5233
|
-
const newPathString = path.join(dataPath, "communities", newDbName);
|
|
5234
|
-
await fs.promises.mkdir(path.dirname(oldPathString), { recursive: true });
|
|
5235
|
-
await fs.promises.mkdir(path.dirname(newPathString), { recursive: true });
|
|
5268
|
+
const oldPathString = path$1.join(dataPath, "communities", oldDbName);
|
|
5269
|
+
const newPathString = path$1.join(dataPath, "communities", newDbName);
|
|
5270
|
+
await fs.promises.mkdir(path$1.dirname(oldPathString), { recursive: true });
|
|
5271
|
+
await fs.promises.mkdir(path$1.dirname(newPathString), { recursive: true });
|
|
5236
5272
|
try {
|
|
5237
5273
|
if (!fs.existsSync(oldPathString)) log(`Old DB file ${oldPathString} does not exist. Cannot backup/rename.`);
|
|
5238
5274
|
else {
|
|
@@ -5254,8 +5290,8 @@ var DbHandler = class {
|
|
|
5254
5290
|
}
|
|
5255
5291
|
async lockCommunityStart(communityAddress = this._community.address) {
|
|
5256
5292
|
const log = logger_default("pkc-js:local-community:db-handler:lock:start");
|
|
5257
|
-
const lockfilePath = path.join(this._community._pkc.dataPath, "communities", `${communityAddress}.start.lock`);
|
|
5258
|
-
const communityDbPath = path.join(this._community._pkc.dataPath, "communities", communityAddress);
|
|
5293
|
+
const lockfilePath = path$1.join(this._community._pkc.dataPath, "communities", `${communityAddress}.start.lock`);
|
|
5294
|
+
const communityDbPath = path$1.join(this._community._pkc.dataPath, "communities", communityAddress);
|
|
5259
5295
|
try {
|
|
5260
5296
|
await import_src.default.lock(communityDbPath, {
|
|
5261
5297
|
lockfilePath,
|
|
@@ -5276,8 +5312,8 @@ var DbHandler = class {
|
|
|
5276
5312
|
async unlockCommunityStart(communityAddress = this._community.address) {
|
|
5277
5313
|
const log = logger_default("pkc-js:local-community:db-handler:unlock:start");
|
|
5278
5314
|
log.trace(`Attempting to unlock the start of community (${communityAddress})`);
|
|
5279
|
-
const lockfilePath = path.join(this._community._pkc.dataPath, "communities", `${communityAddress}.start.lock`);
|
|
5280
|
-
const communityDbPath = path.join(this._community._pkc.dataPath, "communities", communityAddress);
|
|
5315
|
+
const lockfilePath = path$1.join(this._community._pkc.dataPath, "communities", `${communityAddress}.start.lock`);
|
|
5316
|
+
const communityDbPath = path$1.join(this._community._pkc.dataPath, "communities", communityAddress);
|
|
5281
5317
|
if (!fs.existsSync(lockfilePath) || !fs.existsSync(communityDbPath)) return;
|
|
5282
5318
|
try {
|
|
5283
5319
|
await import_src.default.unlock(communityDbPath, { lockfilePath });
|
|
@@ -5288,8 +5324,8 @@ var DbHandler = class {
|
|
|
5288
5324
|
}
|
|
5289
5325
|
}
|
|
5290
5326
|
async isCommunityStartLocked(communityAddress = this._community.address) {
|
|
5291
|
-
const lockfilePath = path.join(this._community._pkc.dataPath, "communities", `${communityAddress}.start.lock`);
|
|
5292
|
-
const communityDbPath = path.join(this._community._pkc.dataPath, "communities", communityAddress);
|
|
5327
|
+
const lockfilePath = path$1.join(this._community._pkc.dataPath, "communities", `${communityAddress}.start.lock`);
|
|
5328
|
+
const communityDbPath = path$1.join(this._community._pkc.dataPath, "communities", communityAddress);
|
|
5293
5329
|
return await import_src.default.check(communityDbPath, {
|
|
5294
5330
|
lockfilePath,
|
|
5295
5331
|
realpath: false,
|
|
@@ -5298,8 +5334,8 @@ var DbHandler = class {
|
|
|
5298
5334
|
}
|
|
5299
5335
|
async lockCommunityState() {
|
|
5300
5336
|
const log = logger_default("pkc-js:local-community:db-handler:lock:lockCommunityState");
|
|
5301
|
-
const lockfilePath = path.join(this._community._pkc.dataPath, "communities", `${this._community.address}.state.lock`);
|
|
5302
|
-
const communityDbPath = path.join(this._community._pkc.dataPath, "communities", this._community.address);
|
|
5337
|
+
const lockfilePath = path$1.join(this._community._pkc.dataPath, "communities", `${this._community.address}.state.lock`);
|
|
5338
|
+
const communityDbPath = path$1.join(this._community._pkc.dataPath, "communities", this._community.address);
|
|
5303
5339
|
try {
|
|
5304
5340
|
await import_src.default.lock(communityDbPath, {
|
|
5305
5341
|
lockfilePath,
|
|
@@ -5316,8 +5352,8 @@ var DbHandler = class {
|
|
|
5316
5352
|
}
|
|
5317
5353
|
async unlockCommunityState() {
|
|
5318
5354
|
const log = logger_default("pkc-js:local-community:db-handler:lock:unlockCommunityState");
|
|
5319
|
-
const lockfilePath = path.join(this._community._pkc.dataPath, "communities", `${this._community.address}.state.lock`);
|
|
5320
|
-
const communityDbPath = path.join(this._community._pkc.dataPath, "communities", this._community.address);
|
|
5355
|
+
const lockfilePath = path$1.join(this._community._pkc.dataPath, "communities", `${this._community.address}.state.lock`);
|
|
5356
|
+
const communityDbPath = path$1.join(this._community._pkc.dataPath, "communities", this._community.address);
|
|
5321
5357
|
if (!fs.existsSync(lockfilePath)) return;
|
|
5322
5358
|
try {
|
|
5323
5359
|
await import_src.default.unlock(communityDbPath, { lockfilePath });
|
|
@@ -5327,7 +5363,7 @@ var DbHandler = class {
|
|
|
5327
5363
|
}
|
|
5328
5364
|
}
|
|
5329
5365
|
communityDbExists() {
|
|
5330
|
-
const communityDbPath = path.join(this._community._pkc.dataPath, "communities", this._community.address);
|
|
5366
|
+
const communityDbPath = path$1.join(this._community._pkc.dataPath, "communities", this._community.address);
|
|
5331
5367
|
return fs.existsSync(communityDbPath);
|
|
5332
5368
|
}
|
|
5333
5369
|
markCommentsAsPublishedToPostUpdates(commentCids) {
|
|
@@ -6246,25 +6282,7 @@ async function calculateNextCommunityRecord(community, commentUpdateRowsToPublis
|
|
|
6246
6282
|
const latestComment = community._dbHandler.queryLatestCommentCid();
|
|
6247
6283
|
community._dbHandler.commitTransaction();
|
|
6248
6284
|
const stats = community._dbHandler.queryCommunityStats();
|
|
6249
|
-
if (commentUpdateRowsToPublishToIpfs.length > 0)
|
|
6250
|
-
await syncPostUpdatesWithIpfs(community, commentUpdateRowsToPublishToIpfs);
|
|
6251
|
-
} catch (e) {
|
|
6252
|
-
const err = e;
|
|
6253
|
-
if (err.message.includes("Timed out writing to MFS path") || err.message.includes("Timed out removing MFS paths")) {
|
|
6254
|
-
log.error(`MFS sync stuck for community ${community.address} - auto-nuking /${community.address} and forcing a full republish. See https://github.com/ipfs/kubo/issues/10842 for upstream context.`);
|
|
6255
|
-
const kuboRpc = community._clientsManager.getDefaultKuboRpcClient();
|
|
6256
|
-
try {
|
|
6257
|
-
await kuboRpc._client.files.rm("/" + community.address, {
|
|
6258
|
-
recursive: true,
|
|
6259
|
-
force: true
|
|
6260
|
-
});
|
|
6261
|
-
} catch (rmErr) {
|
|
6262
|
-
log.error(`Auto-nuke files.rm of /${community.address} failed:`, rmErr);
|
|
6263
|
-
}
|
|
6264
|
-
community._dbHandler.forceUpdateOnAllComments();
|
|
6265
|
-
}
|
|
6266
|
-
throw e;
|
|
6267
|
-
}
|
|
6285
|
+
if (commentUpdateRowsToPublishToIpfs.length > 0) await syncPostUpdatesWithIpfs(community, commentUpdateRowsToPublishToIpfs);
|
|
6268
6286
|
const newPostUpdates = await community._calculateNewPostUpdates();
|
|
6269
6287
|
const newModQueue = await community._pageGenerator.generateModQueuePages();
|
|
6270
6288
|
const statsCid = (await retryKuboIpfsAddAndProvide({
|
|
@@ -6435,7 +6453,7 @@ async function syncIpnsWithDb(community) {
|
|
|
6435
6453
|
const commentUpdateRows = await updateCommentsThatNeedToBeUpdated(community);
|
|
6436
6454
|
requireCommunityUpdateIfModQueueChanged(community);
|
|
6437
6455
|
await updateCommunityIpnsIfNeeded(community, commentUpdateRows);
|
|
6438
|
-
await
|
|
6456
|
+
await cleanUpIpfsRepoIfDue(community);
|
|
6439
6457
|
} catch (e) {
|
|
6440
6458
|
e.details = {
|
|
6441
6459
|
...e.details,
|
|
@@ -7060,11 +7078,11 @@ async function edit(community, newCommunityOptions) {
|
|
|
7060
7078
|
const EXPORTS_KEY = STORAGE_KEYS[STORAGE_KEYS.EXPORTS];
|
|
7061
7079
|
function defaultExportPathFor(community, exportId) {
|
|
7062
7080
|
if (typeof community._pkc.dataPath !== "string") throw new PKCError("ERR_DATA_PATH_IS_NOT_DEFINED", { communityAddress: community.address });
|
|
7063
|
-
return
|
|
7081
|
+
return path.join(community._pkc.dataPath, "exports", `${exportId}.sqlite`);
|
|
7064
7082
|
}
|
|
7065
7083
|
function sourceDbPathFor(community) {
|
|
7066
7084
|
if (typeof community._pkc.dataPath !== "string") throw new PKCError("ERR_DATA_PATH_IS_NOT_DEFINED", { communityAddress: community.address });
|
|
7067
|
-
return
|
|
7085
|
+
return path.join(community._pkc.dataPath, "communities", community.address);
|
|
7068
7086
|
}
|
|
7069
7087
|
async function persistExports(community) {
|
|
7070
7088
|
if (!community._dbHandler) return;
|
|
@@ -7140,9 +7158,9 @@ async function runExportTask(community, exportId, opts) {
|
|
|
7140
7158
|
async function exportCommunityEmbedded(community, options = {}) {
|
|
7141
7159
|
if (options.signal?.aborted) throw options.signal.reason ?? new DOMException("The operation was aborted.", "AbortError");
|
|
7142
7160
|
const exportId = v4();
|
|
7143
|
-
const destPath = options.exportPath ?
|
|
7161
|
+
const destPath = options.exportPath ? path.resolve(options.exportPath) : defaultExportPathFor(community, exportId);
|
|
7144
7162
|
const includePrivateKey = options.includePrivateKey === true;
|
|
7145
|
-
if (
|
|
7163
|
+
if (path.resolve(destPath) === path.resolve(sourceDbPathFor(community))) throw new PKCError("ERR_EXPORT_PATH_TARGETS_LIVE_DB", {
|
|
7146
7164
|
communityAddress: community.address,
|
|
7147
7165
|
exportPath: destPath
|
|
7148
7166
|
});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { i as __toESM, r as __require, t as __commonJSMin } from "./chunk-2rV9d50f.js";
|
|
2
|
-
import { $n as n$1, B as isIpfsCid, Cr as setErrorMap, Ct as findUpdatingCommunity, D as deepMergeRuntimeFields, Dn as CommentUpdateSchema, Dt as refreshTrackedCommentAliases, E as createAbortError, Et as listUpdatingCommunities, Fr as parsedType, H as isIpns, Ir as stringifyPrimitive, It as require_sha256, L as hideClassPrivateProps, Lt as TimeoutError, Pr as joinValues, Pt as untrackUpdatingComment, Q as isStringDomain, Qt as CommunityAnchorSchema, R as ipnsNameToIpnsOverPubsubTopic, Rt as pTimeout, St as findUpdatingComment, Tt as listUpdatingComments, Zn as n$2, _t as timestamp, a as ChallengeRequestMessageSchema, ar as r, b as areEquivalentCommunityAddresses, br as logger_default, ct as resolveWhenPredicateIsTrue, fr as require_retry, ft as shortifyAddress, jt as trackUpdatingComment, k as doesDomainAddressHaveCapitalLetter, ln as PubsubTopicSchema, mt as sleepUntilTimeoutOrAbort, nr as e, ot as removeUndefinedValuesRecursively, pr as FailedToFetchCommentIpfsFromGatewaysError, pt as shortifyCid, r as ChallengeMessageSchema, rn as CommunityIpfsSchema, rr as e$1, s as ChallengeVerificationMessageSchema, st as replaceXWithY, t as ChallengeAnswerMessageSchema, tr as t$1, ut as retryKuboIpfsAdd, vr as PKCError, vt as waitForUpdateInCommunityInstanceWithErrorAndTimeout, wn as CommentUpdateForChallengeVerificationSchema, wt as listStartedCommunities, xr as require_supports_color, xt as findStartedCommunity, y as version_default, yn as CommentIpfsSchema, yr as messages, z as isAbortError } from "./schema-
|
|
3
|
-
import { $ as parseRawPages, $n as t$3, An as RpcAuthorNameParamSchema, Bn as RpcExportCommunityResultSchema, Bt as getCommunityNameFromWire, Cn as parsePKCUserOptionsSchemaWithPKCErrorIfItFails, Dt as verifyCommentModeration, En as parseSetNewSettingsPKCWsServerSchemaWithPKCErrorIfItFails, Et as verifyCommentIpfs, Fn as RpcCommunityPageParamSchema, Ft as getAuthorNameFromRuntime, Gn as RpcPublishedAnchorRecordResultSchema, Gt as getBufferedPKCAddressFromPublicKey, H as tryToDeleteCommunitiesThatFailedToBeDeletedBefore, Hn as RpcFetchCidResultSchema, Ht as normalizeCommunityInputFromCommunity, In as RpcEditCommunityParamSchema, Jn as RpcSuccessResultSchema, Jt as getPKCAddressFromPublicKeySync, Kn as RpcResolveAuthorNameResultSchema, L as listCommunitiesSync, Ln as RpcExportCommunityModLogsParamSchema, Lt as normalizeCreatePublicationAuthor, Mn as RpcCidParamSchema, Mt as verifyVote, Nn as RpcCommentRepliesPageParamSchema, Nt as buildRuntimeAuthor, O as createKuboRpcClient, On as parseVotePubsubMessagePublicationSchemaWithPKCErrorIfItFails, Ot as verifyCommentPubsubMessage, P as getDefaultDataPath, Pn as RpcCommunityIdentifierParamSchema, Pt as cleanWireAuthor, R as monitorCommunitiesDirectory, Rn as RpcExportCommunityModLogsResultSchema, Rt as buildRuntimeCommunityFields, S as encryptEd25519AesGcm, Sn as parseJsonWithPKCErrorIfFails, St as verifyChallengeMessage, Tn as parseRpcCommentUpdateEventWithPKCErrorIfItFails, Tt as verifyCommentEdit, U as CommentClientsManager, Un as RpcPublishAnchorRecordParamSchema, Ut as decode, V as setNativeFunctions$1, Vn as RpcFetchCidParamSchema, Vt as getCommunityPublicKeyFromWire, Wn as RpcPublishChallengeAnswersParamSchema, X as extractCommunityRuntimeFieldsFromParsedPages, Xn as t$4, Yn as RpcUnsubscribeParamSchema, Z as findCommentInPageInstanceRecursively, Zt as parseCidStringSchemaWithPKCErrorIfItFails, _n as parseCreateRpcCommunityFunctionArgumentSchemaWithPKCErrorIfItFails, a as pkcJsChallenges, an as parseCommunityAddressWithPKCErrorIfItFails, b as decryptEd25519AesGcm, bn as parseDecryptedChallengeVerification, bt as signVote, c as AddressesRewriterProxyServer, cn as parseCommunityEditPubsubMessagePublicationSchemaWithPKCErrorIfItFails, cr as require_undici, ct as cleanUpBeforePublishing, dn as parseCreateCommentModerationOptionsSchemaWithPKCErrorIfItFails, dt as signChallengeRequest, en as parseCommentEditPubsubMessagePublicationSchemaWithPKCErrorIfItFails, er as n$3, et as RepliesPages, f as KeyvBetterSqlite3, fn as parseCreateCommentOptionsSchemaWithPKCErrorIfItFails, g as decodeRpcChallengeVerificationPubsubMsg, gn as parseCreateRemoteCommunityFunctionArgumentSchemaWithPKCErrorIfItFails, h as decodeRpcChallengeRequestPubsubMsg, ht as signCommentModeration, in as parseCommentPubsubMessagePublicationWithPKCErrorIfItFails, jn as RpcCancelExportParamSchema, jt as verifyCommunityEdit, kn as RpcAnchorPublishPreparationResultSchema, kt as verifyCommentUpdate, lt as signChallengeAnswer, m as decodeRpcChallengePubsubMsg, mt as signCommentEdit, n as RpcRemoteCommunity, nr as t$2, nt as PKCClientsManager, o as TrackedInstanceRegistry, ot as PKCTypedEmitter, p as decodeRpcChallengeAnswerPubsubMsg, pn as parseCreateCommunityEditPublicationOptionsSchemaWithPKCErrorIfItFails, pt as signComment, qn as RpcSubscriptionIdResultSchema, rn as parseCommentModerationPubsubMessagePublicationSchemaWithPKCErrorIfItFails, rr as t$5, rt as InflightFetchManager, s as LRUCache, sr as nativeFunctions$2, st as require_lib$1, t as RpcLocalCommunity, tn as parseCommentIpfsSchemaWithPKCErrorIfItFails, tt as PublicationClientsManager, u as RemoteCommunity, un as parseCreateCommentEditOptionsSchemaWithPKCErrorIfItFails, v as createSigner, vn as parseCreateVoteOptionsSchemaWithPKCErrorIfItFails, wn as parseRpcCommentEventWithPKCErrorIfItFails, wt as verifyChallengeVerification, xn as parseDecryptedChallengeWithPKCErrorIfItFails, y as createAnchorIpnsRecord$1, yn as parseDecryptedChallengeAnswerWithPKCErrorIfItFails, yt as signCommunityEdit, zn as RpcExportCommunityParamSchema, zt as getCommunityAddressFromRecord } from "./rpc-local-community-
|
|
4
|
-
import { o as getHeliaDebugContext } from "./util-
|
|
2
|
+
import { $n as n$1, B as isIpfsCid, Cr as setErrorMap, Ct as findUpdatingCommunity, D as deepMergeRuntimeFields, Dn as CommentUpdateSchema, Dt as refreshTrackedCommentAliases, E as createAbortError, Et as listUpdatingCommunities, Fr as parsedType, H as isIpns, Ir as stringifyPrimitive, It as require_sha256, L as hideClassPrivateProps, Lt as TimeoutError, Pr as joinValues, Pt as untrackUpdatingComment, Q as isStringDomain, Qt as CommunityAnchorSchema, R as ipnsNameToIpnsOverPubsubTopic, Rt as pTimeout, St as findUpdatingComment, Tt as listUpdatingComments, Zn as n$2, _t as timestamp, a as ChallengeRequestMessageSchema, ar as r, b as areEquivalentCommunityAddresses, br as logger_default, ct as resolveWhenPredicateIsTrue, fr as require_retry, ft as shortifyAddress, jt as trackUpdatingComment, k as doesDomainAddressHaveCapitalLetter, ln as PubsubTopicSchema, mt as sleepUntilTimeoutOrAbort, nr as e, ot as removeUndefinedValuesRecursively, pr as FailedToFetchCommentIpfsFromGatewaysError, pt as shortifyCid, r as ChallengeMessageSchema, rn as CommunityIpfsSchema, rr as e$1, s as ChallengeVerificationMessageSchema, st as replaceXWithY, t as ChallengeAnswerMessageSchema, tr as t$1, ut as retryKuboIpfsAdd, vr as PKCError, vt as waitForUpdateInCommunityInstanceWithErrorAndTimeout, wn as CommentUpdateForChallengeVerificationSchema, wt as listStartedCommunities, xr as require_supports_color, xt as findStartedCommunity, y as version_default, yn as CommentIpfsSchema, yr as messages, z as isAbortError } from "./schema-CH2yoI0b.js";
|
|
3
|
+
import { $ as parseRawPages, $n as t$3, An as RpcAuthorNameParamSchema, Bn as RpcExportCommunityResultSchema, Bt as getCommunityNameFromWire, Cn as parsePKCUserOptionsSchemaWithPKCErrorIfItFails, Dt as verifyCommentModeration, En as parseSetNewSettingsPKCWsServerSchemaWithPKCErrorIfItFails, Et as verifyCommentIpfs, Fn as RpcCommunityPageParamSchema, Ft as getAuthorNameFromRuntime, Gn as RpcPublishedAnchorRecordResultSchema, Gt as getBufferedPKCAddressFromPublicKey, H as tryToDeleteCommunitiesThatFailedToBeDeletedBefore, Hn as RpcFetchCidResultSchema, Ht as normalizeCommunityInputFromCommunity, In as RpcEditCommunityParamSchema, Jn as RpcSuccessResultSchema, Jt as getPKCAddressFromPublicKeySync, Kn as RpcResolveAuthorNameResultSchema, L as listCommunitiesSync, Ln as RpcExportCommunityModLogsParamSchema, Lt as normalizeCreatePublicationAuthor, Mn as RpcCidParamSchema, Mt as verifyVote, Nn as RpcCommentRepliesPageParamSchema, Nt as buildRuntimeAuthor, O as createKuboRpcClient, On as parseVotePubsubMessagePublicationSchemaWithPKCErrorIfItFails, Ot as verifyCommentPubsubMessage, P as getDefaultDataPath, Pn as RpcCommunityIdentifierParamSchema, Pt as cleanWireAuthor, R as monitorCommunitiesDirectory, Rn as RpcExportCommunityModLogsResultSchema, Rt as buildRuntimeCommunityFields, S as encryptEd25519AesGcm, Sn as parseJsonWithPKCErrorIfFails, St as verifyChallengeMessage, Tn as parseRpcCommentUpdateEventWithPKCErrorIfItFails, Tt as verifyCommentEdit, U as CommentClientsManager, Un as RpcPublishAnchorRecordParamSchema, Ut as decode, V as setNativeFunctions$1, Vn as RpcFetchCidParamSchema, Vt as getCommunityPublicKeyFromWire, Wn as RpcPublishChallengeAnswersParamSchema, X as extractCommunityRuntimeFieldsFromParsedPages, Xn as t$4, Yn as RpcUnsubscribeParamSchema, Z as findCommentInPageInstanceRecursively, Zt as parseCidStringSchemaWithPKCErrorIfItFails, _n as parseCreateRpcCommunityFunctionArgumentSchemaWithPKCErrorIfItFails, a as pkcJsChallenges, an as parseCommunityAddressWithPKCErrorIfItFails, b as decryptEd25519AesGcm, bn as parseDecryptedChallengeVerification, bt as signVote, c as AddressesRewriterProxyServer, cn as parseCommunityEditPubsubMessagePublicationSchemaWithPKCErrorIfItFails, cr as require_undici, ct as cleanUpBeforePublishing, dn as parseCreateCommentModerationOptionsSchemaWithPKCErrorIfItFails, dt as signChallengeRequest, en as parseCommentEditPubsubMessagePublicationSchemaWithPKCErrorIfItFails, er as n$3, et as RepliesPages, f as KeyvBetterSqlite3, fn as parseCreateCommentOptionsSchemaWithPKCErrorIfItFails, g as decodeRpcChallengeVerificationPubsubMsg, gn as parseCreateRemoteCommunityFunctionArgumentSchemaWithPKCErrorIfItFails, h as decodeRpcChallengeRequestPubsubMsg, ht as signCommentModeration, in as parseCommentPubsubMessagePublicationWithPKCErrorIfItFails, jn as RpcCancelExportParamSchema, jt as verifyCommunityEdit, kn as RpcAnchorPublishPreparationResultSchema, kt as verifyCommentUpdate, lt as signChallengeAnswer, m as decodeRpcChallengePubsubMsg, mt as signCommentEdit, n as RpcRemoteCommunity, nr as t$2, nt as PKCClientsManager, o as TrackedInstanceRegistry, ot as PKCTypedEmitter, p as decodeRpcChallengeAnswerPubsubMsg, pn as parseCreateCommunityEditPublicationOptionsSchemaWithPKCErrorIfItFails, pt as signComment, qn as RpcSubscriptionIdResultSchema, rn as parseCommentModerationPubsubMessagePublicationSchemaWithPKCErrorIfItFails, rr as t$5, rt as InflightFetchManager, s as LRUCache, sr as nativeFunctions$2, st as require_lib$1, t as RpcLocalCommunity, tn as parseCommentIpfsSchemaWithPKCErrorIfItFails, tt as PublicationClientsManager, u as RemoteCommunity, un as parseCreateCommentEditOptionsSchemaWithPKCErrorIfItFails, v as createSigner, vn as parseCreateVoteOptionsSchemaWithPKCErrorIfItFails, wn as parseRpcCommentEventWithPKCErrorIfItFails, wt as verifyChallengeVerification, xn as parseDecryptedChallengeWithPKCErrorIfItFails, y as createAnchorIpnsRecord$1, yn as parseDecryptedChallengeAnswerWithPKCErrorIfItFails, yt as signCommunityEdit, zn as RpcExportCommunityParamSchema, zt as getCommunityAddressFromRecord } from "./rpc-local-community-DHhucg8-.js";
|
|
4
|
+
import { o as getHeliaDebugContext } from "./util-CiBeiLBn.js";
|
|
5
5
|
import path from "path";
|
|
6
6
|
import assert from "assert";
|
|
7
7
|
import fs from "fs";
|
|
@@ -8527,6 +8527,7 @@ var import_tcp_port_used = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMi
|
|
|
8527
8527
|
return deferred.promise;
|
|
8528
8528
|
}
|
|
8529
8529
|
})))(), 1);
|
|
8530
|
+
const MAX_TCP_PORT = 65535;
|
|
8530
8531
|
function _mergeRouterConfigs(existingConfig, newConfig) {
|
|
8531
8532
|
if (!existingConfig?.Routers) return newConfig;
|
|
8532
8533
|
const existingRoutersByEndpoint = /* @__PURE__ */ new Map();
|
|
@@ -8658,7 +8659,8 @@ async function setupKuboAddressesRewriterAndHttpRouters(pkc) {
|
|
|
8658
8659
|
logger_default("pkc-js:node:setupKuboAddressesRewriterAndHttpRouters");
|
|
8659
8660
|
const httpRouterProxyUrls = [];
|
|
8660
8661
|
const proxyServers = [];
|
|
8661
|
-
|
|
8662
|
+
const parsedStartPortOverride = Number(process.env.PKC_ADDRESSES_REWRITER_START_PORT);
|
|
8663
|
+
let addressesRewriterStartPort = Number.isInteger(parsedStartPortOverride) && parsedStartPortOverride > 0 && parsedStartPortOverride <= MAX_TCP_PORT ? parsedStartPortOverride : 19575;
|
|
8662
8664
|
for (const httpRouter of pkc.httpRoutersOptions) {
|
|
8663
8665
|
if (pkc.destroyed) break;
|
|
8664
8666
|
const startedProxyUrl = await _getStartedProxyUrl(pkc, httpRouter);
|
|
@@ -8668,7 +8670,10 @@ async function setupKuboAddressesRewriterAndHttpRouters(pkc) {
|
|
|
8668
8670
|
}
|
|
8669
8671
|
let port = addressesRewriterStartPort;
|
|
8670
8672
|
const hostname = "127.0.0.1";
|
|
8671
|
-
while (await import_tcp_port_used.check(port, hostname))
|
|
8673
|
+
while (await import_tcp_port_used.check(port, hostname)) {
|
|
8674
|
+
port++;
|
|
8675
|
+
if (port > MAX_TCP_PORT) throw Error(`No free loopback port for the addresses rewriter proxy between ${addressesRewriterStartPort} and ${MAX_TCP_PORT}`);
|
|
8676
|
+
}
|
|
8672
8677
|
const addressesRewriterProxyServer = new AddressesRewriterProxyServer({
|
|
8673
8678
|
kuboClients: Object.values(pkc.clients.kuboRpcClients).map((kubo) => kubo._client),
|
|
8674
8679
|
port,
|
|
@@ -8912,7 +8917,7 @@ var PKC$1 = class extends PKCTypedEmitter {
|
|
|
8912
8917
|
this.clients.libp2pJsClients = {};
|
|
8913
8918
|
if (!this.libp2pJsClientsOptions) return;
|
|
8914
8919
|
if (!this.httpRoutersOptions) throw Error("httpRoutersOptions is required for libp2pJsClient");
|
|
8915
|
-
const { createLibp2pJsClientOrUseExistingOne } = await import("./helia-for-pkc-
|
|
8920
|
+
const { createLibp2pJsClientOrUseExistingOne } = await import("./helia-for-pkc-DPyYKV_m.js");
|
|
8916
8921
|
for (const clientOptions of this.libp2pJsClientsOptions) {
|
|
8917
8922
|
const heliaNode = await createLibp2pJsClientOrUseExistingOne({
|
|
8918
8923
|
...clientOptions,
|
|
@@ -9161,7 +9166,7 @@ var PKC$1 = class extends PKCTypedEmitter {
|
|
|
9161
9166
|
const log = logger_default("pkc-js:pkc:createLocalCommunity");
|
|
9162
9167
|
log.trace("Received community options to create a local community instance:", options);
|
|
9163
9168
|
if (!this._canCreateNewLocalCommunity()) throw new PKCError("ERR_CAN_NOT_CREATE_A_LOCAL_COMMUNITY", { pkcOptions: this._userPKCOptions });
|
|
9164
|
-
const { LocalCommunity, createNewLocalCommunityDb, updateInstancePropsWithStartedCommunityOrDb } = await import("./local-community-
|
|
9169
|
+
const { LocalCommunity, createNewLocalCommunityDb, updateInstancePropsWithStartedCommunityOrDb } = await import("./local-community-DS4PU-HF.js");
|
|
9165
9170
|
const isLocalCommunity = (await listCommunitiesSync(this)).includes(options.address);
|
|
9166
9171
|
const community = new LocalCommunity(this);
|
|
9167
9172
|
if (isLocalCommunity) {
|
package/dist/bundled/chunks/{rpc-local-community-BdNiruAf.js → rpc-local-community-DHhucg8-.js}
RENAMED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { i as __toESM, n as __exportAll, r as __require, t as __commonJSMin } from "./chunk-2rV9d50f.js";
|
|
2
|
-
import { $ as pubsubTopicToDhtKey, $n as n$9, $t as CommunityChallengeSettingSchema, A as extractNetworkErrorDetails, Ar as object, At as trackStartedCommunity, B as isIpfsCid, Cn as CommentUpdateChallengeReservedFieldNames, Ct as findUpdatingCommunity, D as deepMergeRuntimeFields, Dn as CommentUpdateSchema, Dr as custom, E as createAbortError, En as CommentUpdateReservedFields, Er as boolean, Et as listUpdatingCommunities, Fn as CommentEditChallengeRequestToEncryptSchema, Ft as untrackUpdatingCommunity, Gn as ChallengeAnswersSchema, Gt as CommentModerationPubsubMessagePublicationSchema, H as isIpns, Hn as AuthorAddressSchema, Ht as CommunityEditPubsubMessagePublicationSchema, I as getPostUpdateTimestampRange, It as require_sha256$1, Jn as CommunityAddressSchema, Jt as CommentModerationsTableRowSchema, Kn as CidPathSchema, L as hideClassPrivateProps, Ln as CommentEditPubsubMessagePublicationWithFlexibleAuthorSchema, Mn as GetPageParamSchema, Mr as string, Mt as trackUpdatingCommunity, Nn as ModQueuePageIpfsSchema, Nt as untrackStartedCommunity, O as derivePublicationFromChallengeRequest, On as CommentUpdateSignedPropertyNames, Or as literal, Ot as refreshTrackedCommunityAliases, Pn as PageIpfsSchema, Q as isStringDomain, R as ipnsNameToIpnsOverPubsubTopic, Rt as pTimeout, Sn as CommentSignedPropertyNames, Sr as require_ms$1, St as findUpdatingComment, Tn as CommentUpdateForChallengeVerificationSignedPropertyNames, Tr as array, U as isIpnsPath, Un as AuthorCommentIpfsReservedFields, Ut as CreateCommunityEditPublicationOptionsWithRefinementSchema, V as isIpfsPath, Vn as CreateCommentEditOptionsWithRefinementSchema, Vt as CommunityEditPublicationSignedPropertyNames, Wt as CommentModerationChallengeRequestToEncryptSchema, X as isRequestPubsubPublicationOfPost, Xn as CreateSignerSchema, Xt as ChallengeFileFactorySchema, Yn as CommunityAuthorChallengeReservedFieldNames, Yt as CreateCommentModerationOptionsWithRefinementSchema, Z as isRequestPubsubPublicationOfReply, Zn as n$10, Zt as ChallengeFileSchema, _ as PKCUserOptionBaseSchema, _n as CommentChallengeRequestToEncryptSchema, _r as FailedToFetchPageIpfsFromGatewaysError, _t as timestamp, an as CreateNewLocalCommunityUserOptionsSchema, ar as r$8, b as areEquivalentCommunityAddresses, br as logger_default, c as ChallengeVerificationMessageSignedPropertyNames, cn as ExportCommunityModLogsOptionsSchema, cr as r$7, ct as resolveWhenPredicateIsTrue, dn as CreateVoteUserOptionsWithRefinementSchema, dr as e$4, en as CommunityEditOptionsSchema, f as DecryptedChallengeSchema, fn as VoteChallengeRequestToEncryptSchema, fr as require_retry$1, ft as shortifyAddress, g as PKCParsedOptionsSchema, gr as FailedToFetchGenericIpfsFromGatewaysError, gt as throwIfAbortSignalAborted, h as NameResolverSerializedSchema, hn as VoteSignedPropertyNames, hr as FailedToFetchCommunityFromGatewaysError, i as ChallengeMessageSignedPropertyNames, in as CommunitySignedPropertyNames, ir as t$11, it as removeNullUndefinedEmptyObjectsValuesRecursively, j as fetchAndValidateIpnsRecordFromGateway, jn as CreateCommentOptionsWithRefinementSchema, jr as record, k as doesDomainAddressHaveCapitalLetter, kr as number, l as DecryptedChallengeAnswerSchema, lr as t$10, m as NameResolveCacheOptionsSchema, mr as FailedToFetchCommentUpdateFromGatewaysError, mt as sleepUntilTimeoutOrAbort, n as ChallengeAnswerMessageSignedPropertyNames, nn as CommunityIpfsReservedFields, nr as e$6, o as ChallengeRequestMessageSignedPropertyNames, on as CreateRemoteCommunityFunctionArgumentSchema, or as t$12, p as DecryptedChallengeVerificationSchema, pn as VotePubsubMessagePublicationSchema, pr as FailedToFetchCommentIpfsFromGatewaysError, pt as shortifyCid, qn as CidStringSchema, qt as CommentModerationSignedPropertyNames, rn as CommunityIpfsSchema, rr as e$5, sn as CreateRpcCommunityFunctionArgumentSchema, sr as n$8, tn as CommunityExportRecordsSchema, tr as t$13, tt as raceAgainstAbort, un as RpcRemoteCommunityUpdateEventResultSchema, ur as t$9, v as PKCUserOptionsSchema, vn as CommentIpfsReservedFields, vr as PKCError, vt as waitForUpdateInCommunityInstanceWithErrorAndTimeout, wr as _enum, wt as listStartedCommunities, x as calculateIpfsCidV0, xn as CommentPubsubMessageWithFlexibleAuthorRefinementSchema, xr as require_supports_color, xt as findStartedCommunity, yn as CommentIpfsSchema, yr as messages, z as isAbortError, zn as CommentEditSignedPropertyNames, zt as CommunityEditPublicationChallengeRequestToEncryptSchema } from "./schema-
|
|
2
|
+
import { $ as pubsubTopicToDhtKey, $n as n$9, $t as CommunityChallengeSettingSchema, A as extractNetworkErrorDetails, Ar as object, At as trackStartedCommunity, B as isIpfsCid, Cn as CommentUpdateChallengeReservedFieldNames, Ct as findUpdatingCommunity, D as deepMergeRuntimeFields, Dn as CommentUpdateSchema, Dr as custom, E as createAbortError, En as CommentUpdateReservedFields, Er as boolean, Et as listUpdatingCommunities, Fn as CommentEditChallengeRequestToEncryptSchema, Ft as untrackUpdatingCommunity, Gn as ChallengeAnswersSchema, Gt as CommentModerationPubsubMessagePublicationSchema, H as isIpns, Hn as AuthorAddressSchema, Ht as CommunityEditPubsubMessagePublicationSchema, I as getPostUpdateTimestampRange, It as require_sha256$1, Jn as CommunityAddressSchema, Jt as CommentModerationsTableRowSchema, Kn as CidPathSchema, L as hideClassPrivateProps, Ln as CommentEditPubsubMessagePublicationWithFlexibleAuthorSchema, Mn as GetPageParamSchema, Mr as string, Mt as trackUpdatingCommunity, Nn as ModQueuePageIpfsSchema, Nt as untrackStartedCommunity, O as derivePublicationFromChallengeRequest, On as CommentUpdateSignedPropertyNames, Or as literal, Ot as refreshTrackedCommunityAliases, Pn as PageIpfsSchema, Q as isStringDomain, R as ipnsNameToIpnsOverPubsubTopic, Rt as pTimeout, Sn as CommentSignedPropertyNames, Sr as require_ms$1, St as findUpdatingComment, Tn as CommentUpdateForChallengeVerificationSignedPropertyNames, Tr as array, U as isIpnsPath, Un as AuthorCommentIpfsReservedFields, Ut as CreateCommunityEditPublicationOptionsWithRefinementSchema, V as isIpfsPath, Vn as CreateCommentEditOptionsWithRefinementSchema, Vt as CommunityEditPublicationSignedPropertyNames, Wt as CommentModerationChallengeRequestToEncryptSchema, X as isRequestPubsubPublicationOfPost, Xn as CreateSignerSchema, Xt as ChallengeFileFactorySchema, Yn as CommunityAuthorChallengeReservedFieldNames, Yt as CreateCommentModerationOptionsWithRefinementSchema, Z as isRequestPubsubPublicationOfReply, Zn as n$10, Zt as ChallengeFileSchema, _ as PKCUserOptionBaseSchema, _n as CommentChallengeRequestToEncryptSchema, _r as FailedToFetchPageIpfsFromGatewaysError, _t as timestamp, an as CreateNewLocalCommunityUserOptionsSchema, ar as r$8, b as areEquivalentCommunityAddresses, br as logger_default, c as ChallengeVerificationMessageSignedPropertyNames, cn as ExportCommunityModLogsOptionsSchema, cr as r$7, ct as resolveWhenPredicateIsTrue, dn as CreateVoteUserOptionsWithRefinementSchema, dr as e$4, en as CommunityEditOptionsSchema, f as DecryptedChallengeSchema, fn as VoteChallengeRequestToEncryptSchema, fr as require_retry$1, ft as shortifyAddress, g as PKCParsedOptionsSchema, gr as FailedToFetchGenericIpfsFromGatewaysError, gt as throwIfAbortSignalAborted, h as NameResolverSerializedSchema, hn as VoteSignedPropertyNames, hr as FailedToFetchCommunityFromGatewaysError, i as ChallengeMessageSignedPropertyNames, in as CommunitySignedPropertyNames, ir as t$11, it as removeNullUndefinedEmptyObjectsValuesRecursively, j as fetchAndValidateIpnsRecordFromGateway, jn as CreateCommentOptionsWithRefinementSchema, jr as record, k as doesDomainAddressHaveCapitalLetter, kr as number, l as DecryptedChallengeAnswerSchema, lr as t$10, m as NameResolveCacheOptionsSchema, mr as FailedToFetchCommentUpdateFromGatewaysError, mt as sleepUntilTimeoutOrAbort, n as ChallengeAnswerMessageSignedPropertyNames, nn as CommunityIpfsReservedFields, nr as e$6, o as ChallengeRequestMessageSignedPropertyNames, on as CreateRemoteCommunityFunctionArgumentSchema, or as t$12, p as DecryptedChallengeVerificationSchema, pn as VotePubsubMessagePublicationSchema, pr as FailedToFetchCommentIpfsFromGatewaysError, pt as shortifyCid, qn as CidStringSchema, qt as CommentModerationSignedPropertyNames, rn as CommunityIpfsSchema, rr as e$5, sn as CreateRpcCommunityFunctionArgumentSchema, sr as n$8, tn as CommunityExportRecordsSchema, tr as t$13, tt as raceAgainstAbort, un as RpcRemoteCommunityUpdateEventResultSchema, ur as t$9, v as PKCUserOptionsSchema, vn as CommentIpfsReservedFields, vr as PKCError, vt as waitForUpdateInCommunityInstanceWithErrorAndTimeout, wr as _enum, wt as listStartedCommunities, x as calculateIpfsCidV0, xn as CommentPubsubMessageWithFlexibleAuthorRefinementSchema, xr as require_supports_color, xt as findStartedCommunity, yn as CommentIpfsSchema, yr as messages, z as isAbortError, zn as CommentEditSignedPropertyNames, zt as CommunityEditPublicationChallengeRequestToEncryptSchema } from "./schema-CH2yoI0b.js";
|
|
3
3
|
import { t as all } from "./src-CYIMjhjK.js";
|
|
4
4
|
import http from "node:http";
|
|
5
5
|
import { createHash } from "node:crypto";
|
|
6
6
|
import { pathToFileURL } from "node:url";
|
|
7
7
|
import fsp from "node:fs/promises";
|
|
8
|
-
import
|
|
8
|
+
import path from "node:path";
|
|
9
9
|
import dns from "node:dns";
|
|
10
10
|
import os from "os";
|
|
11
11
|
import { closeSync, createReadStream, existsSync, openSync, promises, readSync, readdirSync, rm, watch } from "node:fs";
|
|
12
|
-
import path from "path";
|
|
12
|
+
import path$1 from "path";
|
|
13
13
|
import assert from "assert";
|
|
14
14
|
import { Agent } from "https";
|
|
15
15
|
import { Agent as Agent$1 } from "http";
|
|
@@ -101620,14 +101620,14 @@ var CommentClientsManager = class extends PublicationClientsManager {
|
|
|
101620
101620
|
};
|
|
101621
101621
|
//#endregion
|
|
101622
101622
|
//#region dist/node/runtime/node/util.js
|
|
101623
|
-
const getDefaultDataPath = () => path.join(process.cwd(), ".pkc");
|
|
101623
|
+
const getDefaultDataPath = () => path$1.join(process.cwd(), ".pkc");
|
|
101624
101624
|
const getDefaultCommunityDbConfig = async (communityAddress, pkc) => {
|
|
101625
101625
|
let filename;
|
|
101626
101626
|
if (pkc.noData) filename = ":memory:";
|
|
101627
101627
|
else {
|
|
101628
101628
|
assert(typeof pkc.dataPath === "string", "pkc.dataPath need to be defined to get default community db config");
|
|
101629
|
-
filename = path.join(pkc.dataPath, "communities", communityAddress);
|
|
101630
|
-
await promises.mkdir(path.dirname(filename), { recursive: true });
|
|
101629
|
+
filename = path$1.join(pkc.dataPath, "communities", communityAddress);
|
|
101630
|
+
await promises.mkdir(path$1.dirname(filename), { recursive: true });
|
|
101631
101631
|
}
|
|
101632
101632
|
return {
|
|
101633
101633
|
filename,
|
|
@@ -101726,7 +101726,7 @@ const setNativeFunctions = (newNativeFunctions) => {
|
|
|
101726
101726
|
};
|
|
101727
101727
|
const deleteOldCommunityInWindows = async (subPath, pkc) => {
|
|
101728
101728
|
const log = logger_default("pkc-js:community:deleteStaleCommunityInWindows");
|
|
101729
|
-
const communityAddress = path.basename(subPath);
|
|
101729
|
+
const communityAddress = path$1.basename(subPath);
|
|
101730
101730
|
await new Promise((resolve) => setTimeout(resolve, 1e4));
|
|
101731
101731
|
try {
|
|
101732
101732
|
await promises.rm(subPath, { force: true });
|
|
@@ -101750,7 +101750,7 @@ async function tryToDeleteCommunitiesThatFailedToBeDeletedBefore(pkc, log) {
|
|
|
101750
101750
|
}
|
|
101751
101751
|
const communitiesThatWereDeletedSuccessfully = [];
|
|
101752
101752
|
for (const communityAddress of deletedPersistentCommunities) {
|
|
101753
|
-
const communityPath = path.join(pkc.dataPath, "communities", communityAddress);
|
|
101753
|
+
const communityPath = path$1.join(pkc.dataPath, "communities", communityAddress);
|
|
101754
101754
|
try {
|
|
101755
101755
|
await promises.rm(communityPath, { force: true });
|
|
101756
101756
|
log(`Succeeded in deleting old db path (${communityAddress})`);
|
|
@@ -101774,7 +101774,7 @@ async function tryToDeleteCommunitiesThatFailedToBeDeletedBefore(pkc, log) {
|
|
|
101774
101774
|
function listCommunitiesSync(pkc) {
|
|
101775
101775
|
logger_default("pkc-js:listCommunitiesSync");
|
|
101776
101776
|
if (typeof pkc.dataPath !== "string") throw Error("pkc.dataPath needs to be defined to listCommunities");
|
|
101777
|
-
const communitiesPath = path.join(pkc.dataPath, "communities");
|
|
101777
|
+
const communitiesPath = path$1.join(pkc.dataPath, "communities");
|
|
101778
101778
|
const files = readdirSync(communitiesPath, {
|
|
101779
101779
|
recursive: false,
|
|
101780
101780
|
withFileTypes: false
|
|
@@ -101782,7 +101782,7 @@ function listCommunitiesSync(pkc) {
|
|
|
101782
101782
|
const communityFilesWeDontNeedToCheck = pkc.communities ? files.filter((address) => pkc.communities.includes(address)) : [];
|
|
101783
101783
|
const sqliteFiles = files.filter((address) => !communityFilesWeDontNeedToCheck.includes(address)).filter((address) => {
|
|
101784
101784
|
try {
|
|
101785
|
-
const filePath = path.join(communitiesPath, address);
|
|
101785
|
+
const filePath = path$1.join(communitiesPath, address);
|
|
101786
101786
|
if (!existsSync(filePath)) return false;
|
|
101787
101787
|
const fd = openSync(filePath, "r");
|
|
101788
101788
|
const buffer = Buffer.alloc(16);
|
|
@@ -101863,7 +101863,7 @@ var BackupAbortError = class extends Error {
|
|
|
101863
101863
|
async function backupCommunityDb(opts) {
|
|
101864
101864
|
const { sourcePath, destPath, includePrivateKey, onProgress, signal } = opts;
|
|
101865
101865
|
if (signal?.aborted) throw new BackupAbortError();
|
|
101866
|
-
await promises.mkdir(path.dirname(destPath), { recursive: true });
|
|
101866
|
+
await promises.mkdir(path$1.dirname(destPath), { recursive: true });
|
|
101867
101867
|
const partialPath = destPath + ".partial";
|
|
101868
101868
|
try {
|
|
101869
101869
|
await promises.unlink(partialPath);
|
|
@@ -101947,9 +101947,9 @@ async function statAndHashFile(filePath) {
|
|
|
101947
101947
|
}
|
|
101948
101948
|
async function moveCommunityDbToDeletedDirectory(communityAddress, pkc) {
|
|
101949
101949
|
if (typeof pkc.dataPath !== "string") throw Error("pkc.dataPath is not defined");
|
|
101950
|
-
const oldPath = path.join(pkc.dataPath, "communities", communityAddress);
|
|
101951
|
-
const newPath = path.join(pkc.dataPath, "communities", "deleted", communityAddress);
|
|
101952
|
-
await promises.mkdir(path.join(pkc.dataPath, "communities", "deleted"), { recursive: true });
|
|
101950
|
+
const oldPath = path$1.join(pkc.dataPath, "communities", communityAddress);
|
|
101951
|
+
const newPath = path$1.join(pkc.dataPath, "communities", "deleted", communityAddress);
|
|
101952
|
+
await promises.mkdir(path$1.join(pkc.dataPath, "communities", "deleted"), { recursive: true });
|
|
101953
101953
|
if (!existsSync(oldPath)) throw Error(`Source database ${oldPath} does not exist`);
|
|
101954
101954
|
try {
|
|
101955
101955
|
const sourceDb = new Database(oldPath, { fileMustExist: true });
|
|
@@ -101985,7 +101985,7 @@ async function createKuboRpcClient(kuboRpcClientOptions) {
|
|
|
101985
101985
|
}
|
|
101986
101986
|
async function monitorCommunitiesDirectory(pkc) {
|
|
101987
101987
|
const watchAbortController = new AbortController();
|
|
101988
|
-
const communitiesPath = path.join(pkc.dataPath, "communities");
|
|
101988
|
+
const communitiesPath = path$1.join(pkc.dataPath, "communities");
|
|
101989
101989
|
await promises.mkdir(communitiesPath, { recursive: true });
|
|
101990
101990
|
const extensionsToIgnore = [
|
|
101991
101991
|
".lock",
|
|
@@ -125900,11 +125900,11 @@ var AddressRewriterDatabase = class {
|
|
|
125900
125900
|
if (kuboConfig && typeof kuboConfig === "object" && "host" in kuboConfig && "port" in kuboConfig) kuboIdentifier = `${kuboConfig.host}_${kuboConfig.port}`;
|
|
125901
125901
|
const proxyIdentifier = `${proxyTarget.hostname}_${proxyTarget.port || (proxyTarget.protocol === "https:" ? "443" : "80")}`;
|
|
125902
125902
|
const fileName = `address_rewriter_${kuboIdentifier}_${proxyIdentifier}.db`;
|
|
125903
|
-
return
|
|
125903
|
+
return path.join(dataPath, ".address-rewriter", fileName);
|
|
125904
125904
|
}
|
|
125905
125905
|
async initialize() {
|
|
125906
125906
|
try {
|
|
125907
|
-
const dbDir =
|
|
125907
|
+
const dbDir = path.dirname(this._dbPath);
|
|
125908
125908
|
await fsp.mkdir(dbDir, { recursive: true });
|
|
125909
125909
|
this._db = new Database(this._dbPath);
|
|
125910
125910
|
this._db.exec(`
|
|
@@ -5156,7 +5156,7 @@ var messages;
|
|
|
5156
5156
|
messages["ERR_TIMEOUT_WAITING_FOR_PUBSUB_TOPIC_PEERS"] = "Timeout waiting for propagation of pubsub topic peers";
|
|
5157
5157
|
messages["ERR_PUBSUB_TOPIC_PEER_WAIT_ABORTED"] = "Aborted while waiting for a peer to subscribe to a pubsub topic";
|
|
5158
5158
|
messages["ERR_IPNS_DIRECT_FETCH_ABORTED"] = "Aborted while fetching an IPNS record directly from subscribers/providers";
|
|
5159
|
-
messages["ERR_TIMED_OUT_RM_MFS_FILE"] = "Timed out removing MFS paths
|
|
5159
|
+
messages["ERR_TIMED_OUT_RM_MFS_FILE"] = "Timed out removing MFS paths";
|
|
5160
5160
|
messages["ERR_ABORTED_RESOLVING_TEXT_RECORD"] = "Aborted resolving text record on domain";
|
|
5161
5161
|
messages["ERR_CALLED_COMMUNITY_STOP_WITHOUT_UPDATE"] = "community.stop() called without calling update() first";
|
|
5162
5162
|
messages["ERR_PKC_MISSING_NATIVE_FUNCTIONS"] = "missing nativeFunctions required to create a community";
|
|
@@ -15760,7 +15760,11 @@ async function retryKuboIpfsAdd({ ipfsClient: kuboRpcClient, log, content, input
|
|
|
15760
15760
|
}
|
|
15761
15761
|
async function writeKuboFilesWithTimeout({ ipfsClient: kuboRpcClient, log, path, content, inputNumOfRetries, options, timeoutMs }) {
|
|
15762
15762
|
const numOfRetries = inputNumOfRetries ?? 3;
|
|
15763
|
-
const timeoutMilliseconds = timeoutMs ??
|
|
15763
|
+
const timeoutMilliseconds = timeoutMs ?? 6e4;
|
|
15764
|
+
const writeOptions = {
|
|
15765
|
+
timeout: timeoutMilliseconds,
|
|
15766
|
+
...options
|
|
15767
|
+
};
|
|
15764
15768
|
return new Promise((resolve, reject) => {
|
|
15765
15769
|
const operation = import_retry.operation({
|
|
15766
15770
|
retries: numOfRetries,
|
|
@@ -15769,9 +15773,9 @@ async function writeKuboFilesWithTimeout({ ipfsClient: kuboRpcClient, log, path,
|
|
|
15769
15773
|
});
|
|
15770
15774
|
operation.attempt(async (currentAttempt) => {
|
|
15771
15775
|
try {
|
|
15772
|
-
await pTimeout(kuboRpcClient.files.write(path, content,
|
|
15773
|
-
milliseconds: timeoutMilliseconds,
|
|
15774
|
-
message: `Timed out writing to MFS path ${path} after ${timeoutMilliseconds}ms`
|
|
15776
|
+
await pTimeout(kuboRpcClient.files.write(path, content, writeOptions), {
|
|
15777
|
+
milliseconds: timeoutMilliseconds + 5e3,
|
|
15778
|
+
message: `Timed out writing to MFS path ${path} after ${timeoutMilliseconds + 5e3}ms`
|
|
15775
15779
|
});
|
|
15776
15780
|
resolve();
|
|
15777
15781
|
} catch (error) {
|
|
@@ -16055,7 +16059,7 @@ function extractNetworkErrorDetails(err, depth = 0) {
|
|
|
16055
16059
|
}
|
|
16056
16060
|
//#endregion
|
|
16057
16061
|
//#region dist/node/generated-version.js
|
|
16058
|
-
const version = "0.0.
|
|
16062
|
+
const version = "0.0.78";
|
|
16059
16063
|
//#endregion
|
|
16060
16064
|
//#region dist/node/version.js
|
|
16061
16065
|
const protocolVersion = ProtocolVersionSchema.parse("1.0.0");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { et as pubsubTopicToDhtKeyCid, vr as PKCError } from "./schema-
|
|
1
|
+
import { et as pubsubTopicToDhtKeyCid, vr as PKCError } from "./schema-CH2yoI0b.js";
|
|
2
2
|
import { ipnsSelector } from "ipns/selector";
|
|
3
3
|
import { equals } from "uint8arrays/equals";
|
|
4
4
|
//#region dist/node/helia/util.js
|
package/dist/bundled/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as getShortCid, i as getShortAddress, n as challenges, o as nativeFunctions, r as createAnchorIpnsRecord, s as setNativeFunctions, t as PKC } from "./chunks/node-
|
|
1
|
+
import { a as getShortCid, i as getShortAddress, n as challenges, o as nativeFunctions, r as createAnchorIpnsRecord, s as setNativeFunctions, t as PKC } from "./chunks/node-CcPI4aNc.js";
|
|
2
2
|
export { challenges, createAnchorIpnsRecord, PKC as default, getShortAddress, getShortCid, nativeFunctions, setNativeFunctions };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { $n as n, L as hideClassPrivateProps, br as logger_default, st as replaceXWithY, tr as t, vr as PKCError, xt as findStartedCommunity } from "../../chunks/schema-
|
|
2
|
-
import { _ as parseRpcPublishAnchorRecordParam, c as parseRpcAuthorNameParam, d as parseRpcCommentRepliesPageParam, f as parseRpcCommunityIdentifierParam, g as parseRpcExportCommunityParam, h as parseRpcExportCommunityModLogsParam, l as parseRpcCancelExportParam, m as parseRpcEditCommunityParam, p as parseRpcCommunityPageParam, t as PKC, u as parseRpcCidParam, v as parseRpcPublishChallengeAnswersParam, y as parseRpcUnsubscribeParam } from "../../chunks/node-
|
|
3
|
-
import { $t as parseCommentEditChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, Dn as parseVoteChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, En as parseSetNewSettingsPKCWsServerSchemaWithPKCErrorIfItFails, J as buildPageRuntimeFields, Qt as parseCommentChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, Y as buildPagesRuntimeFields, Zn as t$1, at as pLimit, hn as parseCreatePKCWsServerOptionsSchemaWithPKCErrorIfItFails, ir as stringify, it as pRetry, mn as parseCreateNewLocalCommunityUserOptionsSchemaWithPKCErrorIfItFails, nn as parseCommentModerationChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, on as parseCommunityEditChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, sn as parseCommunityEditOptionsSchemaWithPKCErrorIfItFails, st as require_lib, yn as parseDecryptedChallengeAnswerWithPKCErrorIfItFails } from "../../chunks/rpc-local-community-
|
|
4
|
-
import { t as LocalCommunity } from "../../chunks/local-community-
|
|
1
|
+
import { $n as n, L as hideClassPrivateProps, br as logger_default, st as replaceXWithY, tr as t, vr as PKCError, xt as findStartedCommunity } from "../../chunks/schema-CH2yoI0b.js";
|
|
2
|
+
import { _ as parseRpcPublishAnchorRecordParam, c as parseRpcAuthorNameParam, d as parseRpcCommentRepliesPageParam, f as parseRpcCommunityIdentifierParam, g as parseRpcExportCommunityParam, h as parseRpcExportCommunityModLogsParam, l as parseRpcCancelExportParam, m as parseRpcEditCommunityParam, p as parseRpcCommunityPageParam, t as PKC, u as parseRpcCidParam, v as parseRpcPublishChallengeAnswersParam, y as parseRpcUnsubscribeParam } from "../../chunks/node-CcPI4aNc.js";
|
|
3
|
+
import { $t as parseCommentEditChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, Dn as parseVoteChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, En as parseSetNewSettingsPKCWsServerSchemaWithPKCErrorIfItFails, J as buildPageRuntimeFields, Qt as parseCommentChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, Y as buildPagesRuntimeFields, Zn as t$1, at as pLimit, hn as parseCreatePKCWsServerOptionsSchemaWithPKCErrorIfItFails, ir as stringify, it as pRetry, mn as parseCreateNewLocalCommunityUserOptionsSchemaWithPKCErrorIfItFails, nn as parseCommentModerationChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, on as parseCommunityEditChallengeRequestToEncryptSchemaWithPKCErrorIfItFails, sn as parseCommunityEditOptionsSchemaWithPKCErrorIfItFails, st as require_lib, yn as parseDecryptedChallengeAnswerWithPKCErrorIfItFails } from "../../chunks/rpc-local-community-DHhucg8-.js";
|
|
4
|
+
import { t as LocalCommunity } from "../../chunks/local-community-KNlSpG2e.js";
|
|
5
5
|
import { fileURLToPath } from "node:url";
|
|
6
6
|
import path from "path";
|
|
7
7
|
import assert from "assert";
|
package/dist/node/errors.d.ts
CHANGED
|
@@ -23,7 +23,7 @@ export declare enum messages {
|
|
|
23
23
|
ERR_TIMEOUT_WAITING_FOR_PUBSUB_TOPIC_PEERS = "Timeout waiting for propagation of pubsub topic peers",
|
|
24
24
|
ERR_PUBSUB_TOPIC_PEER_WAIT_ABORTED = "Aborted while waiting for a peer to subscribe to a pubsub topic",
|
|
25
25
|
ERR_IPNS_DIRECT_FETCH_ABORTED = "Aborted while fetching an IPNS record directly from subscribers/providers",
|
|
26
|
-
ERR_TIMED_OUT_RM_MFS_FILE = "Timed out removing MFS paths
|
|
26
|
+
ERR_TIMED_OUT_RM_MFS_FILE = "Timed out removing MFS paths",
|
|
27
27
|
ERR_ABORTED_RESOLVING_TEXT_RECORD = "Aborted resolving text record on domain",
|
|
28
28
|
ERR_CALLED_COMMUNITY_STOP_WITHOUT_UPDATE = "community.stop() called without calling update() first",
|
|
29
29
|
ERR_PKC_MISSING_NATIVE_FUNCTIONS = "missing nativeFunctions required to create a community",
|
package/dist/node/errors.js
CHANGED
|
@@ -24,7 +24,7 @@ export var messages;
|
|
|
24
24
|
messages["ERR_TIMEOUT_WAITING_FOR_PUBSUB_TOPIC_PEERS"] = "Timeout waiting for propagation of pubsub topic peers";
|
|
25
25
|
messages["ERR_PUBSUB_TOPIC_PEER_WAIT_ABORTED"] = "Aborted while waiting for a peer to subscribe to a pubsub topic";
|
|
26
26
|
messages["ERR_IPNS_DIRECT_FETCH_ABORTED"] = "Aborted while fetching an IPNS record directly from subscribers/providers";
|
|
27
|
-
messages["ERR_TIMED_OUT_RM_MFS_FILE"] = "Timed out removing MFS paths
|
|
27
|
+
messages["ERR_TIMED_OUT_RM_MFS_FILE"] = "Timed out removing MFS paths";
|
|
28
28
|
messages["ERR_ABORTED_RESOLVING_TEXT_RECORD"] = "Aborted resolving text record on domain";
|
|
29
29
|
// PKC errors
|
|
30
30
|
messages["ERR_CALLED_COMMUNITY_STOP_WITHOUT_UPDATE"] = "community.stop() called without calling update() first";
|
package/dist/node/errors.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../src/errors.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,QAiZX;AAjZD,WAAY,QAAQ;IAChB,gFAAoE,CAAA;IACpE,yHAA6G,CAAA;IAC7G,6EAAiE,CAAA;IACjE,4FAAgF,CAAA;IAChF,iMAAqL,CAAA;IACrL,4HAAgH,CAAA;IAChH,8HAAkH,CAAA;IAClH,iDAAqC,CAAA;IACrC,0GAA8F,CAAA;IAC9F,2KAA+J,CAAA;IAC/J,oGAAwF,CAAA;IACxF,8DAAkD,CAAA;IAClD,6EAAiE,CAAA;IACjE,iFAAqE,CAAA;IACrE,8HAAkH,CAAA;IAClH,8HAAkH,CAAA;IAClH,sHAA0G,CAAA;IAC1G,0JAA8I,CAAA;IAC9I,mJAAuI,CAAA;IACvI,kHAAsG,CAAA;IACtG,iFAAqE,CAAA;IACrE,gHAAoG,CAAA;IACpG,kHAAsG,CAAA;IACtG,uHAA2G,CAAA;IAC3G,
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../src/errors.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,QAiZX;AAjZD,WAAY,QAAQ;IAChB,gFAAoE,CAAA;IACpE,yHAA6G,CAAA;IAC7G,6EAAiE,CAAA;IACjE,4FAAgF,CAAA;IAChF,iMAAqL,CAAA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