thinkpool-pair 0.6.9 → 0.6.10
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/bridge.mjs +10 -3
- package/package.json +4 -2
package/bridge.mjs
CHANGED
|
@@ -49,11 +49,13 @@ const SCROLLBACK_MAX = 120_000
|
|
|
49
49
|
|
|
50
50
|
// node-pty is a native module — loaded lazily so a friendly message shows
|
|
51
51
|
// if it isn't built yet.
|
|
52
|
-
|
|
52
|
+
// Structured Claude (the default) runs through the Agent SDK and needs NO PTY,
|
|
53
|
+
// so a failed node-pty build must not block the bridge — it only disables the
|
|
54
|
+
// raw-PTY path (other CLIs / TP_PTY=1), which we flag clearly if it's used.
|
|
55
|
+
let pty = null
|
|
53
56
|
try { pty = (await import('node-pty')).default ?? (await import('node-pty')) }
|
|
54
57
|
catch {
|
|
55
|
-
console.error('\n node-pty
|
|
56
|
-
process.exit(1)
|
|
58
|
+
console.error('\n ⚠ node-pty not built — raw terminal sharing is off (structured Claude still works).\n For PTY mode (bash / aider / codex / TP_PTY=1): install a C toolchain, then `npm i` in the bridge.\n (Xcode CLT on mac · build-essential on linux · VS Build Tools on Windows.)\n')
|
|
57
59
|
}
|
|
58
60
|
|
|
59
61
|
// ── Known coding-agent CLIs we feature in the picker ──────────────
|
|
@@ -325,6 +327,11 @@ const attachedDims = () => ({
|
|
|
325
327
|
|
|
326
328
|
function openTerm({ id, cmd, args = [], attached = false, cols, rows }) {
|
|
327
329
|
if (terms.has(id)) return
|
|
330
|
+
if (!pty) { // raw-PTY path needs node-pty; structured Claude never lands here
|
|
331
|
+
process.stderr.write(`\n ⚠ can't open "${cmd}" — node-pty isn't built (PTY mode disabled).\n`)
|
|
332
|
+
bcast('term-exit', { id })
|
|
333
|
+
return
|
|
334
|
+
}
|
|
328
335
|
const ad = attached ? attachedDims() : null
|
|
329
336
|
const term = pty.spawn(cmd, args, {
|
|
330
337
|
name: 'xterm-256color',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "thinkpool-pair",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.10",
|
|
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": {
|
|
@@ -21,7 +21,9 @@
|
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"@anthropic-ai/claude-agent-sdk": "^0.3.173",
|
|
24
|
-
"@supabase/supabase-js": "^2.45.0"
|
|
24
|
+
"@supabase/supabase-js": "^2.45.0"
|
|
25
|
+
},
|
|
26
|
+
"optionalDependencies": {
|
|
25
27
|
"node-pty": "^1.2.0-beta.13"
|
|
26
28
|
}
|
|
27
29
|
}
|