@timo972/cc-router 0.13.0-rc.0 → 0.13.0-rc.1

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/CHANGELOG.md CHANGED
@@ -38,6 +38,12 @@ This project follows [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
38
38
 
39
39
  ### Fixed
40
40
 
41
+ - Pressing `n` (and now `l`) in the dashboard no longer kills the process
42
+ before the sign-in prompt can take input. Ink unrefs stdin when it
43
+ unmounts and nothing ref'd it again, so with no other work pending the
44
+ process exited while inquirer was still waiting — reported as
45
+ `User force closed the prompt with 0 null`. The dashboard now refs stdin
46
+ for the duration of the interactive flow.
41
47
  - Re-authenticating an account replaces its credentials only. Previously the
42
48
  replacement was built from the freshly collected record, so a disabled
43
49
  account came back enabled and custom session/weekly caps reset to 100 —
@@ -126,6 +126,14 @@ async function dashboardLoop(port) {
126
126
  process.stdin.resume();
127
127
  if (pendingIntent.kind === "quit")
128
128
  return;
129
+ // Ink unref()s stdin when it unmounts, and neither resume() nor
130
+ // readline ref it again. With nothing else keeping the event loop
131
+ // alive, the process exits while inquirer is still waiting for a key —
132
+ // inquirer reports it as "User force closed the prompt with 0 null" and
133
+ // the sign-in never runs. Ref it for the interactive flow; the next
134
+ // dashboard mount takes ownership again, and the quit path above never
135
+ // reaches this line, so a plain quit still exits.
136
+ process.stdin.ref();
129
137
  if (pendingIntent.kind === "addAccount") {
130
138
  // Intent: addAccount — run the OAuth flow, then POST the resulting
131
139
  // tokens to the server we're connected to (local or remote).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@timo972/cc-router",
3
- "version": "0.13.0-rc.0",
3
+ "version": "0.13.0-rc.1",
4
4
  "description": "Cache-aware session router for Claude Max OAuth tokens — use multiple Claude Max accounts with Claude Code",
5
5
  "type": "module",
6
6
  "bin": {