thinkpool-pair 0.7.87 → 0.7.88

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/package.json +1 -1
  2. package/service.mjs +11 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "thinkpool-pair",
3
- "version": "0.7.87",
3
+ "version": "0.7.88",
4
4
  "description": "Share a local coding-agent CLI (Claude Code, Codex, Gemini, Aider, …) into a ThinkPool Code room, live.",
5
5
  "type": "module",
6
6
  "bin": {
package/service.mjs CHANGED
@@ -67,7 +67,15 @@ export function buildArtifact(platform, { room = null, cmdArgs = [], autoUpdate
67
67
  // version — a bad publish can't auto-roll here. `autoUpdate` opts into `@latest` tracking
68
68
  // (and the in-process self-updater via THINKPOOL_PAIR_AUTOUPDATE below).
69
69
  const verSpec = autoUpdate ? 'thinkpool-pair@latest' : `thinkpool-pair@${version}`
70
- const pkgArgs = room ? ['-y', verSpec, room] : ['-y', verSpec]
70
+ // Anti-zombie (2026-06-29): cacheWipe removes the INSTALLED package, but npx still
71
+ // resolves `@latest` from npm's cached registry metadata (TTL'd). A restart inside
72
+ // that window reinstalls the OLD version even though a newer one is published — the
73
+ // bridge "comes back from the dead" stale (left FVIHV1DE on 0.7.86 while @latest was
74
+ // 0.7.87). `--prefer-online` forces npx to REVALIDATE the packument against the
75
+ // registry every resolve, so `@latest` always means the true latest. Only needed for
76
+ // the @latest (autoUpdate) tier — a pinned exact version is immutable, no staleness.
77
+ const onlineFlag = autoUpdate ? ['--prefer-online'] : []
78
+ const pkgArgs = room ? ['-y', ...onlineFlag, verSpec, room] : ['-y', ...onlineFlag, verSpec]
71
79
  // In-process self-update (account.mjs / bridge.mjs) is gated on this env — only on when
72
80
  // the user explicitly opted into auto-update.
73
81
  const autoUpdateEnv = autoUpdate ? { THINKPOOL_PAIR_AUTOUPDATE: '1' } : {}
@@ -158,8 +166,8 @@ WantedBy=default.target
158
166
  const startup = path.join(process.env.APPDATA || path.join(os.homedir(), 'AppData', 'Roaming'), 'Microsoft', 'Windows', 'Start Menu', 'Programs', 'Startup')
159
167
  const file = path.join(startup, `thinkpool-pair-${id}.cmd`)
160
168
  const inner = room
161
- ? ['npx', '-y', verSpec, room, '--supervise', ...tail].join(' ')
162
- : ['npx', '-y', verSpec].join(' ')
169
+ ? ['npx', '-y', ...onlineFlag, verSpec, room, '--supervise', ...tail].join(' ')
170
+ : ['npx', '-y', ...onlineFlag, verSpec].join(' ')
163
171
  const content = `@echo off\r\ntitle thinkpool-pair ${id}\r\n${inner}\r\n`
164
172
  return { file, content, logDir, post: [], note: 'Installed to the Startup folder — runs at login' + (room ? ' with --supervise (auto-restart on crash).' : ' (account mode).') + ' Start it now without rebooting by double-clicking the .cmd, or run it from a terminal.' }
165
173
  }