@leofcoin/chain 1.7.71 → 1.7.73
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/exports/browser/{browser-DQJ6xf_F-BCS5wcAv.js → browser-BogfGRzB-D3fc2MzB.js} +2 -1
- package/exports/browser/chain.js +8 -4
- package/exports/browser/{client-C0VVXIWm-DcqDljSm.js → client-DD7vhDK_-UAymLS2i.js} +31 -8
- package/exports/browser/{identity-CQ_ieRiz-CTM-_kGF.js → identity--VAIVSMm-DTWL357I.js} +217 -127
- package/exports/browser/{index-CEwkDK9g-CHsuUR8y.js → index-Vgr1JQcP-DNJYAZ_u.js} +63 -42
- package/exports/browser/{index-BeqbCwUk-BNpn0JK0.js → index-Vl0cNziw-Dw2QX2H3.js} +1 -1
- package/exports/browser/{messages-BdevLRCA-DCm-zGuC.js → messages-CW17jRdc-c9cSXiiQ.js} +2 -2
- package/exports/browser/{node-browser-DcYcGvEF.js → node-browser-BvxzAdLe.js} +279 -4323
- package/exports/browser/node-browser.js +2 -2
- package/exports/chain.js +8 -4
- package/package.json +3 -3
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { N as default } from './node-browser-
|
|
2
|
-
import './identity-
|
|
1
|
+
export { N as default } from './node-browser-BvxzAdLe.js';
|
|
2
|
+
import './identity--VAIVSMm-DTWL357I.js';
|
|
3
3
|
import './index-DUfUgiQY.js';
|
package/exports/chain.js
CHANGED
|
@@ -365,7 +365,10 @@ class Machine {
|
|
|
365
365
|
}
|
|
366
366
|
}
|
|
367
367
|
else if (data.question === 'peers') {
|
|
368
|
-
this.worker.postMessage({
|
|
368
|
+
this.worker.postMessage({
|
|
369
|
+
id: data.id,
|
|
370
|
+
input: peernet.connections ? Object.entries(peernet.connections).map(([id, peer]) => peer.toJSON()) : []
|
|
371
|
+
});
|
|
369
372
|
}
|
|
370
373
|
else {
|
|
371
374
|
this.worker.postMessage({ id: data.id, input: data.input });
|
|
@@ -1538,6 +1541,10 @@ class Chain extends VersionControl {
|
|
|
1538
1541
|
}
|
|
1539
1542
|
async #invalidTransaction(hash) {
|
|
1540
1543
|
hash = new TextDecoder().decode(hash);
|
|
1544
|
+
if (!(await globalThis.transactionPoolStore.has(hash))) {
|
|
1545
|
+
debug(`transaction ${hash} not in pool`);
|
|
1546
|
+
return;
|
|
1547
|
+
}
|
|
1541
1548
|
console.log(`removing invalid transaction: ${hash}`);
|
|
1542
1549
|
await globalThis.transactionPoolStore.delete(hash);
|
|
1543
1550
|
}
|
|
@@ -1749,10 +1756,7 @@ class Chain extends VersionControl {
|
|
|
1749
1756
|
console.log({ e });
|
|
1750
1757
|
console.log(hash);
|
|
1751
1758
|
peernet.publish('invalid-transaction', hash);
|
|
1752
|
-
console.log(await globalThis.transactionPoolStore.keys());
|
|
1753
|
-
console.log(await globalThis.transactionPoolStore.has(e.hash));
|
|
1754
1759
|
await globalThis.transactionPoolStore.delete(e.hash);
|
|
1755
|
-
console.log(await globalThis.transactionPoolStore.has(e.hash));
|
|
1756
1760
|
}
|
|
1757
1761
|
}
|
|
1758
1762
|
// todo filter tx that need to wait on prev nonce
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@leofcoin/chain",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.73",
|
|
4
4
|
"description": "Official javascript implementation",
|
|
5
5
|
"private": false,
|
|
6
6
|
"exports": {
|
|
@@ -69,10 +69,10 @@
|
|
|
69
69
|
"@leofcoin/messages": "^1.4.40",
|
|
70
70
|
"@leofcoin/multi-wallet": "^3.1.8",
|
|
71
71
|
"@leofcoin/networks": "^1.1.25",
|
|
72
|
-
"@leofcoin/peernet": "^1.1.
|
|
72
|
+
"@leofcoin/peernet": "^1.1.84",
|
|
73
73
|
"@leofcoin/storage": "^3.5.38",
|
|
74
74
|
"@leofcoin/utils": "^1.1.39",
|
|
75
|
-
"@leofcoin/workers": "^1.5.
|
|
75
|
+
"@leofcoin/workers": "^1.5.23",
|
|
76
76
|
"@vandeurenglenn/base58": "^1.1.9",
|
|
77
77
|
"@vandeurenglenn/easy-worker": "^1.0.2",
|
|
78
78
|
"semver": "^7.7.2"
|