@sym-bot/mesh-channel 0.1.11 → 0.1.13
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/bin/install.js +4 -3
- package/package.json +2 -2
- package/server.js +5 -1
package/bin/install.js
CHANGED
|
@@ -42,9 +42,10 @@ if (cmd !== 'init') {
|
|
|
42
42
|
|
|
43
43
|
// ── Detect platform & defaults ────────────────────────────────────
|
|
44
44
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
45
|
+
// Default: hostname-based identity, unique per machine. Prevents
|
|
46
|
+
// the ghost-peer bug where two machines with the same default name
|
|
47
|
+
// create phantom peers that absorb messages.
|
|
48
|
+
const defaultNodeName = `claude-${os.hostname().toLowerCase().replace(/[^a-z0-9-]/g, '-')}`;
|
|
48
49
|
|
|
49
50
|
// SYM_NODE_NAME from env wins over default
|
|
50
51
|
const nodeName = process.env.SYM_NODE_NAME || defaultNodeName;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sym-bot/mesh-channel",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.13",
|
|
4
4
|
"description": "MCP server — Claude Code as a peer node on the SYM mesh. LAN-first via Bonjour, no relay required.",
|
|
5
5
|
"main": "server.js",
|
|
6
6
|
"bin": {
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
],
|
|
16
16
|
"dependencies": {
|
|
17
17
|
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
18
|
-
"@sym-bot/sym": "^0.3.
|
|
18
|
+
"@sym-bot/sym": "^0.3.76"
|
|
19
19
|
},
|
|
20
20
|
"engines": {
|
|
21
21
|
"node": ">=18"
|
package/server.js
CHANGED
|
@@ -44,7 +44,11 @@ const FIELD_WEIGHTS = {
|
|
|
44
44
|
|
|
45
45
|
// ── SymNode — full peer on the mesh ──────────────────────────
|
|
46
46
|
|
|
47
|
-
|
|
47
|
+
// Default: hostname-based identity, unique per machine. The old default
|
|
48
|
+
// ('claude-code-mac') caused ghost-peer bugs when another machine ran
|
|
49
|
+
// without SYM_NODE_NAME set — both machines claimed the same name with
|
|
50
|
+
// different nodeIds, creating phantom peers that absorbed messages.
|
|
51
|
+
const NODE_NAME = process.env.SYM_NODE_NAME || `claude-${require('os').hostname().toLowerCase().replace(/[^a-z0-9-]/g, '-')}`;
|
|
48
52
|
|
|
49
53
|
const node = new SymNode({
|
|
50
54
|
name: NODE_NAME,
|