bulletin-deploy 0.6.2 → 0.6.3-rc.0
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/{chunk-3I7SHB4A.js → chunk-46DQDQUC.js} +23 -14
- package/dist/{chunk-72ZGQO3T.js → chunk-BGKAKGPP.js} +60 -16
- package/dist/{chunk-OUE2NAOG.js → chunk-YN6UEDUA.js} +1 -1
- package/dist/deploy.d.ts +10 -2
- package/dist/deploy.js +5 -3
- package/dist/dotns.d.ts +2 -1
- package/dist/dotns.js +4 -2
- package/dist/index.js +3 -3
- package/dist/telemetry.js +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
captureWarning,
|
|
3
3
|
withSpan
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-YN6UEDUA.js";
|
|
5
5
|
|
|
6
6
|
// src/dotns.ts
|
|
7
7
|
import crypto from "crypto";
|
|
@@ -43,6 +43,7 @@ var CONTRACTS = {
|
|
|
43
43
|
};
|
|
44
44
|
var DECIMALS = 12n;
|
|
45
45
|
var NATIVE_TO_ETH_RATIO = 1000000n;
|
|
46
|
+
var CONNECTION_TIMEOUT_MS = 3e4;
|
|
46
47
|
var OPERATION_TIMEOUT_MS = 3e5;
|
|
47
48
|
var TX_TIMEOUT_MS = 9e4;
|
|
48
49
|
var DEFAULT_MNEMONIC = "bottom drive obey lake curtain smoke basket hold race lonely fit walk";
|
|
@@ -401,10 +402,15 @@ var DotNS = class {
|
|
|
401
402
|
this.substrateAddress = account.address;
|
|
402
403
|
this.signer = getPolkadotSigner(account.publicKey, "Sr25519", async (input) => account.sign(input));
|
|
403
404
|
}
|
|
404
|
-
this.evmAddress = await
|
|
405
|
-
|
|
405
|
+
this.evmAddress = await withTimeout(
|
|
406
|
+
this.clientWrapper.getEvmAddress(this.substrateAddress),
|
|
407
|
+
CONNECTION_TIMEOUT_MS,
|
|
408
|
+
`Connect to ${rpc}`
|
|
409
|
+
);
|
|
406
410
|
console.log(` SS58 Address: ${this.substrateAddress}`);
|
|
407
411
|
console.log(` H160 Address: ${this.evmAddress}`);
|
|
412
|
+
await this.clientWrapper.ensureAccountMapped(this.substrateAddress, this.signer);
|
|
413
|
+
this.connected = true;
|
|
408
414
|
return this;
|
|
409
415
|
} catch (e) {
|
|
410
416
|
lastError = e;
|
|
@@ -612,10 +618,7 @@ var DotNS = class {
|
|
|
612
618
|
}
|
|
613
619
|
async register(label, options = {}) {
|
|
614
620
|
return withSpan("deploy.dotns.register", `2a. register ${label}.dot`, {}, async () => {
|
|
615
|
-
const
|
|
616
|
-
const isMainnet = this.rpc && MAINNET_RPC_PATTERNS.some((p) => this.rpc.includes(p));
|
|
617
|
-
const statusDefault = isMainnet ? "none" : "full";
|
|
618
|
-
const status = parseProofOfPersonhoodStatus(options.status || process.env.DOTNS_STATUS || statusDefault);
|
|
621
|
+
const explicitStatus = options.status || process.env.DOTNS_STATUS;
|
|
619
622
|
const reverse = options.reverse ?? (process.env.DOTNS_REVERSE ?? "false").toLowerCase() === "true";
|
|
620
623
|
if (!this.connected) await this.connect(options);
|
|
621
624
|
label = validateDomainLabel(label);
|
|
@@ -623,17 +626,22 @@ var DotNS = class {
|
|
|
623
626
|
this.classifyName(label),
|
|
624
627
|
this.ensureNotRegistered(label)
|
|
625
628
|
]);
|
|
626
|
-
await this.setUserPopStatus(status);
|
|
627
|
-
const userStatus = await this.getUserPopStatus();
|
|
628
629
|
const requiredStatus = classification.requiredStatus;
|
|
629
630
|
if (requiredStatus === ProofOfPersonhoodStatus.Reserved) {
|
|
630
631
|
throw new Error(classification.message);
|
|
631
632
|
}
|
|
632
|
-
if (requiredStatus
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
633
|
+
if (requiredStatus !== ProofOfPersonhoodStatus.NoStatus || explicitStatus) {
|
|
634
|
+
const targetStatus = explicitStatus ? parseProofOfPersonhoodStatus(explicitStatus) : requiredStatus;
|
|
635
|
+
if (targetStatus !== ProofOfPersonhoodStatus.NoStatus) {
|
|
636
|
+
await this.setUserPopStatus(targetStatus);
|
|
637
|
+
}
|
|
638
|
+
const userStatus = await this.getUserPopStatus();
|
|
639
|
+
if (requiredStatus === ProofOfPersonhoodStatus.ProofOfPersonhoodFull && userStatus !== ProofOfPersonhoodStatus.ProofOfPersonhoodFull) {
|
|
640
|
+
throw new Error("Requires Full Personhood verification. Set DOTNS_STATUS=full or use a domain with trailing digits (e.g. my-app00.dot)");
|
|
641
|
+
}
|
|
642
|
+
if (requiredStatus === ProofOfPersonhoodStatus.ProofOfPersonhoodLite && userStatus !== ProofOfPersonhoodStatus.ProofOfPersonhoodLite && userStatus !== ProofOfPersonhoodStatus.ProofOfPersonhoodFull) {
|
|
643
|
+
throw new Error("Requires Personhood Lite verification. Set DOTNS_STATUS=lite or DOTNS_STATUS=full");
|
|
644
|
+
}
|
|
637
645
|
}
|
|
638
646
|
const { commitment, registration } = await this.generateCommitment(label, reverse);
|
|
639
647
|
await withSpan("deploy.dotns.submit-commitment", "2a-i. submit-commitment", {}, () => this.submitCommitment(commitment));
|
|
@@ -662,6 +670,7 @@ export {
|
|
|
662
670
|
CONTRACTS,
|
|
663
671
|
DECIMALS,
|
|
664
672
|
NATIVE_TO_ETH_RATIO,
|
|
673
|
+
CONNECTION_TIMEOUT_MS,
|
|
665
674
|
OPERATION_TIMEOUT_MS,
|
|
666
675
|
TX_TIMEOUT_MS,
|
|
667
676
|
DEFAULT_MNEMONIC,
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
DotNS,
|
|
4
4
|
TX_TIMEOUT_MS,
|
|
5
5
|
fetchNonce
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-46DQDQUC.js";
|
|
7
7
|
import {
|
|
8
8
|
derivePoolAccounts,
|
|
9
9
|
ensureAuthorized,
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
setDeployAttribute,
|
|
18
18
|
withDeploySpan,
|
|
19
19
|
withSpan
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-YN6UEDUA.js";
|
|
21
21
|
|
|
22
22
|
// src/deploy.ts
|
|
23
23
|
import { Buffer } from "buffer";
|
|
@@ -279,6 +279,11 @@ var BULLETIN_RPC = DEFAULT_BULLETIN_RPC;
|
|
|
279
279
|
var POOL_SIZE = DEFAULT_POOL_SIZE;
|
|
280
280
|
var CHUNK_SIZE = 1 * 1024 * 1024;
|
|
281
281
|
var MAX_FILE_SIZE = 8 * 1024 * 1024;
|
|
282
|
+
var MAX_RECONNECTIONS = parseInt(process.env.BULLETIN_MAX_RECONNECTIONS ?? "1", 10);
|
|
283
|
+
function isConnectionError(error) {
|
|
284
|
+
const msg = error?.message || String(error);
|
|
285
|
+
return /heartbeat timeout|WS halt|Unable to connect/i.test(msg);
|
|
286
|
+
}
|
|
282
287
|
var CID_CONFIG = { version: 1, codec: 85, hashCode: 18, hashLength: 32 };
|
|
283
288
|
function getGitRemoteUrl() {
|
|
284
289
|
try {
|
|
@@ -496,12 +501,13 @@ async function storeFile(contentBytes, { client: existingClient, unsafeApi: exis
|
|
|
496
501
|
throw e;
|
|
497
502
|
}
|
|
498
503
|
}
|
|
499
|
-
async function storeChunkedContent(chunks, { client: existingClient, unsafeApi: existingApi, signer: existingSigner, ss58: existingSS58 } = {}) {
|
|
504
|
+
async function storeChunkedContent(chunks, { client: existingClient, unsafeApi: existingApi, signer: existingSigner, ss58: existingSS58, reconnect } = {}) {
|
|
500
505
|
console.log(`
|
|
501
506
|
Chunks: ${chunks.length}`);
|
|
502
507
|
const totalBytes = chunks.reduce((s, c) => s + c.length, 0);
|
|
503
508
|
console.log(` Total: ${(totalBytes / 1024).toFixed(2)} KB`);
|
|
504
509
|
let client, unsafeApi, signer, ss58;
|
|
510
|
+
let ownsClient = false;
|
|
505
511
|
if (existingClient) {
|
|
506
512
|
client = existingClient;
|
|
507
513
|
unsafeApi = existingApi;
|
|
@@ -513,6 +519,27 @@ async function storeChunkedContent(chunks, { client: existingClient, unsafeApi:
|
|
|
513
519
|
unsafeApi = provider.unsafeApi;
|
|
514
520
|
signer = provider.signer;
|
|
515
521
|
ss58 = provider.ss58;
|
|
522
|
+
ownsClient = true;
|
|
523
|
+
}
|
|
524
|
+
let reconnectionsUsed = 0;
|
|
525
|
+
async function doReconnect() {
|
|
526
|
+
if (!reconnect || reconnectionsUsed >= MAX_RECONNECTIONS) {
|
|
527
|
+
throw new Error(`Connection lost and max reconnections (${MAX_RECONNECTIONS}) exhausted`);
|
|
528
|
+
}
|
|
529
|
+
reconnectionsUsed++;
|
|
530
|
+
console.log(`
|
|
531
|
+
Connection lost, reconnecting to Bulletin (${reconnectionsUsed}/${MAX_RECONNECTIONS})...`);
|
|
532
|
+
captureWarning("WebSocket connection lost, reconnecting", { reconnection: reconnectionsUsed, maxReconnections: MAX_RECONNECTIONS });
|
|
533
|
+
try {
|
|
534
|
+
client.destroy();
|
|
535
|
+
} catch {
|
|
536
|
+
}
|
|
537
|
+
const fresh = await reconnect();
|
|
538
|
+
client = fresh.client;
|
|
539
|
+
unsafeApi = fresh.unsafeApi;
|
|
540
|
+
signer = fresh.signer;
|
|
541
|
+
ss58 = fresh.ss58;
|
|
542
|
+
ownsClient = true;
|
|
516
543
|
}
|
|
517
544
|
try {
|
|
518
545
|
let startNonce = await fetchNonce(BULLETIN_RPC, ss58);
|
|
@@ -523,10 +550,18 @@ async function storeChunkedContent(chunks, { client: existingClient, unsafeApi:
|
|
|
523
550
|
Submitting ${chunks.length} chunks in batches of ${BATCH_SIZE}...`);
|
|
524
551
|
const stored = new Array(chunks.length).fill(null);
|
|
525
552
|
for (let b = 0; b < chunks.length; b += BATCH_SIZE) {
|
|
526
|
-
const
|
|
527
|
-
const
|
|
528
|
-
|
|
553
|
+
const batchIndices = [];
|
|
554
|
+
const batchChunks = [];
|
|
555
|
+
for (let j = 0; j < BATCH_SIZE && b + j < chunks.length; j++) {
|
|
529
556
|
const i = b + j;
|
|
557
|
+
if (stored[i] === null) {
|
|
558
|
+
batchIndices.push(i);
|
|
559
|
+
batchChunks.push(chunks[i]);
|
|
560
|
+
}
|
|
561
|
+
}
|
|
562
|
+
if (batchIndices.length === 0) continue;
|
|
563
|
+
const batchPromises = batchChunks.map((chunkData, j) => {
|
|
564
|
+
const i = batchIndices[j];
|
|
530
565
|
const nonce = startNonce + i;
|
|
531
566
|
console.log(` [${i + 1}/${chunks.length}] ${(chunkData.length / 1024 / 1024).toFixed(2)} MB (nonce: ${nonce})`);
|
|
532
567
|
return storeChunk(unsafeApi, signer, chunkData, nonce, ss58);
|
|
@@ -535,7 +570,13 @@ async function storeChunkedContent(chunks, { client: existingClient, unsafeApi:
|
|
|
535
570
|
results.forEach((r, j) => {
|
|
536
571
|
if (r.status === "fulfilled") stored[batchIndices[j]] = r.value;
|
|
537
572
|
});
|
|
538
|
-
const failures = results.map((r, j) => r.status === "rejected" ? { index: batchIndices[j], chunkData:
|
|
573
|
+
const failures = results.map((r, j) => r.status === "rejected" ? { index: batchIndices[j], chunkData: batchChunks[j], error: r.reason } : null).filter(Boolean);
|
|
574
|
+
if (failures.some((f) => isConnectionError(f.error))) {
|
|
575
|
+
await doReconnect();
|
|
576
|
+
startNonce = await fetchNonce(BULLETIN_RPC, ss58);
|
|
577
|
+
b -= BATCH_SIZE;
|
|
578
|
+
continue;
|
|
579
|
+
}
|
|
539
580
|
for (const fail of failures) {
|
|
540
581
|
captureWarning("Chunk upload failed, retrying", { chunkIndex: fail.index + 1, maxRetries: MAX_CHUNK_RETRIES, error: fail.error?.message?.slice(0, 200) });
|
|
541
582
|
let retried = false;
|
|
@@ -589,10 +630,10 @@ async function storeChunkedContent(chunks, { client: existingClient, unsafeApi:
|
|
|
589
630
|
`);
|
|
590
631
|
return rootCid.toString();
|
|
591
632
|
}, { label: "root-node", rpc: BULLETIN_RPC, senderSS58: ss58, expectedNonce: rootNonce });
|
|
592
|
-
if (
|
|
633
|
+
if (ownsClient) client.destroy();
|
|
593
634
|
return result;
|
|
594
635
|
} catch (e) {
|
|
595
|
-
if (
|
|
636
|
+
if (ownsClient) client.destroy();
|
|
596
637
|
throw e;
|
|
597
638
|
}
|
|
598
639
|
}
|
|
@@ -663,8 +704,10 @@ async function deploy(content, domainName = null, options = {}) {
|
|
|
663
704
|
if (typeof content === "string") console.log(` Build dir: ${path.resolve(content)}`);
|
|
664
705
|
if (options.password) console.log(` Encrypted: yes`);
|
|
665
706
|
let provider;
|
|
707
|
+
const reconnect = options.mnemonic ? () => getDirectProvider(options.mnemonic) : () => getProvider();
|
|
666
708
|
try {
|
|
667
|
-
provider =
|
|
709
|
+
provider = await reconnect();
|
|
710
|
+
const providerWithReconnect = { ...provider, reconnect };
|
|
668
711
|
console.log("\n" + "=".repeat(60));
|
|
669
712
|
console.log("Storage");
|
|
670
713
|
console.log("=".repeat(60));
|
|
@@ -689,7 +732,7 @@ async function deploy(content, domainName = null, options = {}) {
|
|
|
689
732
|
console.log(` Encrypted: ${(encrypted.length / 1024).toFixed(1)} KB`);
|
|
690
733
|
contentChunks = chunk(encrypted);
|
|
691
734
|
}
|
|
692
|
-
cid = await storeChunkedContent(contentChunks,
|
|
735
|
+
cid = await storeChunkedContent(contentChunks, providerWithReconnect);
|
|
693
736
|
} else if (typeof content === "string") {
|
|
694
737
|
const contentPath = path.resolve(content);
|
|
695
738
|
if (!fs.existsSync(contentPath)) throw new Error(`Path not found: ${contentPath}`);
|
|
@@ -698,7 +741,7 @@ async function deploy(content, domainName = null, options = {}) {
|
|
|
698
741
|
console.log(`
|
|
699
742
|
Mode: Directory`);
|
|
700
743
|
console.log(` Path: ${contentPath}`);
|
|
701
|
-
const dirResult = await storeDirectory(contentPath,
|
|
744
|
+
const dirResult = await storeDirectory(contentPath, providerWithReconnect, options.password);
|
|
702
745
|
cid = dirResult.storageCid;
|
|
703
746
|
ipfsCid = dirResult.ipfsCid;
|
|
704
747
|
} else {
|
|
@@ -713,9 +756,9 @@ async function deploy(content, domainName = null, options = {}) {
|
|
|
713
756
|
}
|
|
714
757
|
if (fileContent.length > MAX_FILE_SIZE) {
|
|
715
758
|
console.log(` Exceeds 8MB, chunking...`);
|
|
716
|
-
cid = await storeChunkedContent(chunk(fileContent),
|
|
759
|
+
cid = await storeChunkedContent(chunk(fileContent), providerWithReconnect);
|
|
717
760
|
} else {
|
|
718
|
-
cid = await storeFile(fileContent,
|
|
761
|
+
cid = await storeFile(fileContent, providerWithReconnect);
|
|
719
762
|
}
|
|
720
763
|
}
|
|
721
764
|
} else if (content instanceof Uint8Array) {
|
|
@@ -729,9 +772,9 @@ async function deploy(content, domainName = null, options = {}) {
|
|
|
729
772
|
}
|
|
730
773
|
if (bytesContent.length > MAX_FILE_SIZE) {
|
|
731
774
|
console.log(` Exceeds 8MB, chunking...`);
|
|
732
|
-
cid = await storeChunkedContent(chunk(bytesContent),
|
|
775
|
+
cid = await storeChunkedContent(chunk(bytesContent), providerWithReconnect);
|
|
733
776
|
} else {
|
|
734
|
-
cid = await storeFile(bytesContent,
|
|
777
|
+
cid = await storeFile(bytesContent, providerWithReconnect);
|
|
735
778
|
}
|
|
736
779
|
} else {
|
|
737
780
|
throw new Error("Invalid content: must be path, Uint8Array, or Array<Uint8Array>");
|
|
@@ -817,6 +860,7 @@ async function deploy(content, domainName = null, options = {}) {
|
|
|
817
860
|
export {
|
|
818
861
|
DEFAULT_BULLETIN_RPC,
|
|
819
862
|
DEFAULT_POOL_SIZE,
|
|
863
|
+
isConnectionError,
|
|
820
864
|
deriveRootSigner,
|
|
821
865
|
createCID,
|
|
822
866
|
encodeContenthash,
|
package/dist/deploy.d.ts
CHANGED
|
@@ -8,14 +8,22 @@ interface DeployResult {
|
|
|
8
8
|
ipfsCid?: string;
|
|
9
9
|
}
|
|
10
10
|
type DeployContent = string | Uint8Array | Uint8Array[];
|
|
11
|
+
interface ProviderResult {
|
|
12
|
+
client: any;
|
|
13
|
+
unsafeApi: any;
|
|
14
|
+
signer: PolkadotSigner;
|
|
15
|
+
ss58: string;
|
|
16
|
+
}
|
|
11
17
|
interface ExistingProvider {
|
|
12
18
|
client?: any;
|
|
13
19
|
unsafeApi?: any;
|
|
14
20
|
signer?: PolkadotSigner;
|
|
15
21
|
ss58?: string;
|
|
22
|
+
reconnect?: () => Promise<ProviderResult>;
|
|
16
23
|
}
|
|
17
24
|
declare const DEFAULT_BULLETIN_RPC = "wss://paseo-bulletin-rpc.polkadot.io";
|
|
18
25
|
declare const DEFAULT_POOL_SIZE = 10;
|
|
26
|
+
declare function isConnectionError(error: any): boolean;
|
|
19
27
|
declare function deriveRootSigner(mnemonic: string): {
|
|
20
28
|
signer: PolkadotSigner;
|
|
21
29
|
ss58: string;
|
|
@@ -30,7 +38,7 @@ declare const ENCRYPT_KEY_LEN = 32;
|
|
|
30
38
|
declare const ENCRYPT_PBKDF2_ITERATIONS = 100000;
|
|
31
39
|
declare function encryptContent(data: Uint8Array, password: string): Promise<Uint8Array>;
|
|
32
40
|
declare function storeFile(contentBytes: Uint8Array, { client: existingClient, unsafeApi: existingApi, signer: existingSigner }?: ExistingProvider): Promise<string>;
|
|
33
|
-
declare function storeChunkedContent(chunks: Uint8Array[], { client: existingClient, unsafeApi: existingApi, signer: existingSigner, ss58: existingSS58 }?: ExistingProvider): Promise<string>;
|
|
41
|
+
declare function storeChunkedContent(chunks: Uint8Array[], { client: existingClient, unsafeApi: existingApi, signer: existingSigner, ss58: existingSS58, reconnect }?: ExistingProvider): Promise<string>;
|
|
34
42
|
declare function chunk(data: Uint8Array, size?: number): Uint8Array[];
|
|
35
43
|
declare function hasIPFS(): boolean;
|
|
36
44
|
declare function merkleize(directoryPath: string, outputCarPath: string): Promise<{
|
|
@@ -54,4 +62,4 @@ interface DeployOptions {
|
|
|
54
62
|
}
|
|
55
63
|
declare function deploy(content: DeployContent, domainName?: string | null, options?: DeployOptions): Promise<DeployResult>;
|
|
56
64
|
|
|
57
|
-
export { DEFAULT_BULLETIN_RPC, DEFAULT_POOL_SIZE, type DeployContent, type DeployOptions, type DeployResult, ENCRYPT_KEY_LEN, ENCRYPT_MAGIC, ENCRYPT_NONCE_LEN, ENCRYPT_PBKDF2_ITERATIONS, ENCRYPT_SALT_LEN, ENCRYPT_TAG_LEN, chunk, createCID, deploy, deriveRootSigner, encodeContenthash, encryptContent, hasIPFS, merkleize, storeChunkedContent, storeDirectory, storeFile };
|
|
65
|
+
export { DEFAULT_BULLETIN_RPC, DEFAULT_POOL_SIZE, type DeployContent, type DeployOptions, type DeployResult, ENCRYPT_KEY_LEN, ENCRYPT_MAGIC, ENCRYPT_NONCE_LEN, ENCRYPT_PBKDF2_ITERATIONS, ENCRYPT_SALT_LEN, ENCRYPT_TAG_LEN, chunk, createCID, deploy, deriveRootSigner, encodeContenthash, encryptContent, hasIPFS, isConnectionError, merkleize, storeChunkedContent, storeDirectory, storeFile };
|
package/dist/deploy.js
CHANGED
|
@@ -14,14 +14,15 @@ import {
|
|
|
14
14
|
encodeContenthash,
|
|
15
15
|
encryptContent,
|
|
16
16
|
hasIPFS,
|
|
17
|
+
isConnectionError,
|
|
17
18
|
merkleize,
|
|
18
19
|
storeChunkedContent,
|
|
19
20
|
storeDirectory,
|
|
20
21
|
storeFile
|
|
21
|
-
} from "./chunk-
|
|
22
|
-
import "./chunk-
|
|
22
|
+
} from "./chunk-BGKAKGPP.js";
|
|
23
|
+
import "./chunk-46DQDQUC.js";
|
|
23
24
|
import "./chunk-AIHW2WLO.js";
|
|
24
|
-
import "./chunk-
|
|
25
|
+
import "./chunk-YN6UEDUA.js";
|
|
25
26
|
import "./chunk-QGM4M3NI.js";
|
|
26
27
|
export {
|
|
27
28
|
DEFAULT_BULLETIN_RPC,
|
|
@@ -39,6 +40,7 @@ export {
|
|
|
39
40
|
encodeContenthash,
|
|
40
41
|
encryptContent,
|
|
41
42
|
hasIPFS,
|
|
43
|
+
isConnectionError,
|
|
42
44
|
merkleize,
|
|
43
45
|
storeChunkedContent,
|
|
44
46
|
storeDirectory,
|
package/dist/dotns.d.ts
CHANGED
|
@@ -30,6 +30,7 @@ declare const CONTRACTS: {
|
|
|
30
30
|
};
|
|
31
31
|
declare const DECIMALS: bigint;
|
|
32
32
|
declare const NATIVE_TO_ETH_RATIO: bigint;
|
|
33
|
+
declare const CONNECTION_TIMEOUT_MS: number;
|
|
33
34
|
declare const OPERATION_TIMEOUT_MS: number;
|
|
34
35
|
declare const TX_TIMEOUT_MS: number;
|
|
35
36
|
declare const DEFAULT_MNEMONIC: string;
|
|
@@ -115,4 +116,4 @@ declare class DotNS {
|
|
|
115
116
|
}
|
|
116
117
|
declare const dotns: DotNS;
|
|
117
118
|
|
|
118
|
-
export { CONTRACTS, DECIMALS, DEFAULT_MNEMONIC, DOT_NODE, DotNS, type DotNSConnectOptions, NATIVE_TO_ETH_RATIO, OPERATION_TIMEOUT_MS, type OwnershipResult, type PriceValidationResult, ProofOfPersonhoodStatus, RPC_ENDPOINTS, TX_TIMEOUT_MS, computeDomainTokenId, convertWeiToNative, countTrailingDigits, dotns, fetchNonce, parseProofOfPersonhoodStatus, sanitizeDomainLabel, stripTrailingDigits, validateDomainLabel };
|
|
119
|
+
export { CONNECTION_TIMEOUT_MS, CONTRACTS, DECIMALS, DEFAULT_MNEMONIC, DOT_NODE, DotNS, type DotNSConnectOptions, NATIVE_TO_ETH_RATIO, OPERATION_TIMEOUT_MS, type OwnershipResult, type PriceValidationResult, ProofOfPersonhoodStatus, RPC_ENDPOINTS, TX_TIMEOUT_MS, computeDomainTokenId, convertWeiToNative, countTrailingDigits, dotns, fetchNonce, parseProofOfPersonhoodStatus, sanitizeDomainLabel, stripTrailingDigits, validateDomainLabel };
|
package/dist/dotns.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import {
|
|
2
|
+
CONNECTION_TIMEOUT_MS,
|
|
2
3
|
CONTRACTS,
|
|
3
4
|
DECIMALS,
|
|
4
5
|
DEFAULT_MNEMONIC,
|
|
@@ -18,10 +19,11 @@ import {
|
|
|
18
19
|
sanitizeDomainLabel,
|
|
19
20
|
stripTrailingDigits,
|
|
20
21
|
validateDomainLabel
|
|
21
|
-
} from "./chunk-
|
|
22
|
-
import "./chunk-
|
|
22
|
+
} from "./chunk-46DQDQUC.js";
|
|
23
|
+
import "./chunk-YN6UEDUA.js";
|
|
23
24
|
import "./chunk-QGM4M3NI.js";
|
|
24
25
|
export {
|
|
26
|
+
CONNECTION_TIMEOUT_MS,
|
|
25
27
|
CONTRACTS,
|
|
26
28
|
DECIMALS,
|
|
27
29
|
DEFAULT_MNEMONIC,
|
package/dist/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
deploy
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-BGKAKGPP.js";
|
|
4
4
|
import {
|
|
5
5
|
DotNS
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-46DQDQUC.js";
|
|
7
7
|
import {
|
|
8
8
|
bootstrapPool,
|
|
9
9
|
derivePoolAccounts,
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
fetchPoolAuthorizations,
|
|
12
12
|
selectAccount
|
|
13
13
|
} from "./chunk-AIHW2WLO.js";
|
|
14
|
-
import "./chunk-
|
|
14
|
+
import "./chunk-YN6UEDUA.js";
|
|
15
15
|
import "./chunk-QGM4M3NI.js";
|
|
16
16
|
export {
|
|
17
17
|
DotNS,
|
package/dist/telemetry.js
CHANGED