@decentnetwork/peer 0.1.11 → 0.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/peer.js +10 -2
  2. package/package.json +1 -1
package/dist/peer.js CHANGED
@@ -1974,7 +1974,12 @@ export class Peer {
1974
1974
  this.#debugLog(`self announce step1 no response from ${c.node.host}:${c.node.port}`);
1975
1975
  continue;
1976
1976
  }
1977
- this.#debugLog(`self announce step1 response from ${c.node.host}:${c.node.port} isStored=${resp1.isStored}`);
1977
+ // Promoted to console.log so we can see what bootstraps respond
1978
+ // without needing DECENT_DEBUG=1 set up at process launch.
1979
+ // selfAnnounceStoredOn has been stuck at 0 across all peers and
1980
+ // we need to see whether step1 itself fails or just step2.
1981
+ // Temporary — to be reverted once UDP is actually working.
1982
+ console.log(`[announce-step1] from=${c.node.host}:${c.node.port} isStored=${resp1.isStored}`);
1978
1983
  step1Hits.push({ c, resp1 });
1979
1984
  }
1980
1985
  const step2Settled = await Promise.allSettled(step1Hits.map(({ c, resp1 }) => this.#sendAnnounceAndWait({
@@ -1995,7 +2000,10 @@ export class Peer {
1995
2000
  const resp2 = r2.status === "fulfilled" ? r2.value : undefined;
1996
2001
  const final = resp2 ?? resp1;
1997
2002
  if (resp2) {
1998
- this.#debugLog(`self announce step2 response from ${c.node.host}:${c.node.port} isStored=${resp2.isStored}`);
2003
+ console.log(`[announce-step2] from=${c.node.host}:${c.node.port} isStored=${resp2.isStored}`);
2004
+ }
2005
+ else {
2006
+ console.log(`[announce-step2] from=${c.node.host}:${c.node.port} NO_RESPONSE`);
1999
2007
  }
2000
2008
  if (final.isStored === 2) {
2001
2009
  storedNodes.push(c.node);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@decentnetwork/peer",
3
- "version": "0.1.11",
3
+ "version": "0.1.12",
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",