@decentnetwork/peer 0.1.146 → 0.1.147
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/peer.js +6 -0
- package/package.json +1 -1
package/dist/peer.js
CHANGED
|
@@ -3739,8 +3739,14 @@ export class Peer {
|
|
|
3739
3739
|
}
|
|
3740
3740
|
#ensureExpressPullLoop() {
|
|
3741
3741
|
if (!this.#express?.hasNodes() || this.#expressPollTimer || EXPRESS_PULL_INTERVAL_MS <= 0) {
|
|
3742
|
+
// Three ways to silently do nothing, and no way to tell them apart from
|
|
3743
|
+
// outside — which cost a long evening of guessing why offline mail was
|
|
3744
|
+
// never collected in a browser.
|
|
3745
|
+
this.#debugLog(`express pull loop NOT started: hasClient=${!!this.#express} hasNodes=${!!this.#express?.hasNodes()} ` +
|
|
3746
|
+
`alreadyRunning=${!!this.#expressPollTimer} interval=${EXPRESS_PULL_INTERVAL_MS}`);
|
|
3742
3747
|
return;
|
|
3743
3748
|
}
|
|
3749
|
+
this.#debugLog(`express pull loop started, every ${EXPRESS_PULL_INTERVAL_MS}ms`);
|
|
3744
3750
|
const pull = () => {
|
|
3745
3751
|
void this.#express?.pullOnce().catch((error) => {
|
|
3746
3752
|
this.#debugLog(`express pull failed: ${error.message}`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@decentnetwork/peer",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.147",
|
|
4
4
|
"description": "Pure TypeScript port of Elastos Carrier (toxcore-derived) P2P messaging. DHT, onion routing, TCP relay, FlatBuffers app payloads, Express offline relay. Wire-compatible with iOS Beagle and the Carrier C SDK.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|