claude-use 9.4.1 → 9.4.3

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/dist/cli.cjs CHANGED
@@ -33224,7 +33224,7 @@ var init_package = __esm({
33224
33224
  "package.json"() {
33225
33225
  package_default = {
33226
33226
  name: "claude-use",
33227
- version: "9.4.1",
33227
+ version: "9.4.3",
33228
33228
  description: "A profile manager and launcher for Claude Code that lets one person run multiple logins from one machine while controlling what gets shared between them.",
33229
33229
  license: "MIT",
33230
33230
  author: "Joseph Mearman <joseph@mearman.co.uk>",
@@ -106542,8 +106542,12 @@ var SourcePortRange = class {
106542
106542
  }
106543
106543
  };
106544
106544
  var DOOR_SOURCE_PORT_START = 47900;
106545
- var DOOR_SOURCE_PORT_END = 47919;
106545
+ var DOOR_SOURCE_PORT_COUNT = 1e3;
106546
+ var DOOR_SOURCE_PORT_END = DOOR_SOURCE_PORT_START + DOOR_SOURCE_PORT_COUNT - 1;
106546
106547
  var DOOR_SOURCE_PORTS = new SourcePortRange(DOOR_SOURCE_PORT_START, DOOR_SOURCE_PORT_END);
106548
+ var POOLED_SOCKET_IDLE_MS = 3e4;
106549
+ var POOLED_SOCKETS_KEPT_IDLE = 2;
106550
+ var POOLING = { keepAlive: true, timeout: POOLED_SOCKET_IDLE_MS, maxFreeSockets: POOLED_SOCKETS_KEPT_IDLE };
106547
106551
  var realAddressLookup = (host, _options, callback) => {
106548
106552
  if (net2.isIP(host) !== 0) {
106549
106553
  callback(null, [{ address: host, family: net2.isIP(host) }]);
@@ -106598,7 +106602,7 @@ function requestServername(options, fallback) {
106598
106602
  }
106599
106603
  var ExemptHttpAgent = class extends http3.Agent {
106600
106604
  constructor(ports = DOOR_SOURCE_PORTS) {
106601
- super();
106605
+ super(POOLING);
106602
106606
  this.ports = ports;
106603
106607
  }
106604
106608
  ports;
@@ -106616,7 +106620,7 @@ var ExemptHttpAgent = class extends http3.Agent {
106616
106620
  };
106617
106621
  var ExemptTlsAgent = class extends https3.Agent {
106618
106622
  constructor(ports = DOOR_SOURCE_PORTS) {
106619
- super();
106623
+ super(POOLING);
106620
106624
  this.ports = ports;
106621
106625
  }
106622
106626
  ports;
@@ -117416,6 +117420,7 @@ function createRcStreamHub(deps) {
117416
117420
  };
117417
117421
  const runLoop = async (attachment) => {
117418
117422
  let retriedUnauthorized = false;
117423
+ let refusedAuthorization;
117419
117424
  for (; ; ) {
117420
117425
  if (attachment.isStopped()) {
117421
117426
  return;
@@ -117431,6 +117436,11 @@ function createRcStreamHub(deps) {
117431
117436
  }
117432
117437
  return;
117433
117438
  }
117439
+ if (refusedAuthorization !== void 0 && credential.authorization === refusedAuthorization) {
117440
+ await deps.sleep(deps.backoffMs);
117441
+ continue;
117442
+ }
117443
+ refusedAuthorization = void 0;
117434
117444
  let outcome;
117435
117445
  try {
117436
117446
  outcome = await attempt(attachment, credential);
@@ -117457,7 +117467,8 @@ function createRcStreamHub(deps) {
117457
117467
  retriedUnauthorized = true;
117458
117468
  continue;
117459
117469
  }
117460
- deps.log?.(`rc stream ${attachment.sessionId}: the client read stream refused the observed Authorization bearer past one retry; backing off`);
117470
+ deps.log?.(`rc stream ${attachment.sessionId}: the client read stream refused the observed Authorization bearer past one retry; waiting for a fresh one`);
117471
+ refusedAuthorization = credential.authorization;
117461
117472
  await deps.sleep(deps.backoffMs);
117462
117473
  retriedUnauthorized = false;
117463
117474
  }
package/dist/index.cjs CHANGED
@@ -2649,7 +2649,7 @@ var init_package = __esm({
2649
2649
  "package.json"() {
2650
2650
  package_default = {
2651
2651
  name: "claude-use",
2652
- version: "9.4.1",
2652
+ version: "9.4.3",
2653
2653
  description: "A profile manager and launcher for Claude Code that lets one person run multiple logins from one machine while controlling what gets shared between them.",
2654
2654
  license: "MIT",
2655
2655
  author: "Joseph Mearman <joseph@mearman.co.uk>",
@@ -10198,8 +10198,12 @@ var SourcePortRange = class {
10198
10198
  }
10199
10199
  };
10200
10200
  var DOOR_SOURCE_PORT_START = 47900;
10201
- var DOOR_SOURCE_PORT_END = 47919;
10201
+ var DOOR_SOURCE_PORT_COUNT = 1e3;
10202
+ var DOOR_SOURCE_PORT_END = DOOR_SOURCE_PORT_START + DOOR_SOURCE_PORT_COUNT - 1;
10202
10203
  var DOOR_SOURCE_PORTS = new SourcePortRange(DOOR_SOURCE_PORT_START, DOOR_SOURCE_PORT_END);
10204
+ var POOLED_SOCKET_IDLE_MS = 3e4;
10205
+ var POOLED_SOCKETS_KEPT_IDLE = 2;
10206
+ var POOLING = { keepAlive: true, timeout: POOLED_SOCKET_IDLE_MS, maxFreeSockets: POOLED_SOCKETS_KEPT_IDLE };
10203
10207
  var realAddressLookup = (host, _options, callback) => {
10204
10208
  if (net2.isIP(host) !== 0) {
10205
10209
  callback(null, [{ address: host, family: net2.isIP(host) }]);
@@ -10254,7 +10258,7 @@ function requestServername(options, fallback) {
10254
10258
  }
10255
10259
  var ExemptHttpAgent = class extends http.Agent {
10256
10260
  constructor(ports = DOOR_SOURCE_PORTS) {
10257
- super();
10261
+ super(POOLING);
10258
10262
  this.ports = ports;
10259
10263
  }
10260
10264
  ports;
@@ -10272,7 +10276,7 @@ var ExemptHttpAgent = class extends http.Agent {
10272
10276
  };
10273
10277
  var ExemptTlsAgent = class extends https2.Agent {
10274
10278
  constructor(ports = DOOR_SOURCE_PORTS) {
10275
- super();
10279
+ super(POOLING);
10276
10280
  this.ports = ports;
10277
10281
  }
10278
10282
  ports;
@@ -13607,6 +13611,7 @@ function createRcStreamHub(deps) {
13607
13611
  };
13608
13612
  const runLoop = async (attachment) => {
13609
13613
  let retriedUnauthorized = false;
13614
+ let refusedAuthorization;
13610
13615
  for (; ; ) {
13611
13616
  if (attachment.isStopped()) {
13612
13617
  return;
@@ -13622,6 +13627,11 @@ function createRcStreamHub(deps) {
13622
13627
  }
13623
13628
  return;
13624
13629
  }
13630
+ if (refusedAuthorization !== void 0 && credential.authorization === refusedAuthorization) {
13631
+ await deps.sleep(deps.backoffMs);
13632
+ continue;
13633
+ }
13634
+ refusedAuthorization = void 0;
13625
13635
  let outcome;
13626
13636
  try {
13627
13637
  outcome = await attempt(attachment, credential);
@@ -13648,7 +13658,8 @@ function createRcStreamHub(deps) {
13648
13658
  retriedUnauthorized = true;
13649
13659
  continue;
13650
13660
  }
13651
- deps.log?.(`rc stream ${attachment.sessionId}: the client read stream refused the observed Authorization bearer past one retry; backing off`);
13661
+ deps.log?.(`rc stream ${attachment.sessionId}: the client read stream refused the observed Authorization bearer past one retry; waiting for a fresh one`);
13662
+ refusedAuthorization = credential.authorization;
13652
13663
  await deps.sleep(deps.backoffMs);
13653
13664
  retriedUnauthorized = false;
13654
13665
  }
package/dist/index.mjs CHANGED
@@ -2625,7 +2625,7 @@ var init_package = __esm({
2625
2625
  "package.json"() {
2626
2626
  package_default = {
2627
2627
  name: "claude-use",
2628
- version: "9.4.1",
2628
+ version: "9.4.3",
2629
2629
  description: "A profile manager and launcher for Claude Code that lets one person run multiple logins from one machine while controlling what gets shared between them.",
2630
2630
  license: "MIT",
2631
2631
  author: "Joseph Mearman <joseph@mearman.co.uk>",
@@ -9873,8 +9873,12 @@ var SourcePortRange = class {
9873
9873
  }
9874
9874
  };
9875
9875
  var DOOR_SOURCE_PORT_START = 47900;
9876
- var DOOR_SOURCE_PORT_END = 47919;
9876
+ var DOOR_SOURCE_PORT_COUNT = 1e3;
9877
+ var DOOR_SOURCE_PORT_END = DOOR_SOURCE_PORT_START + DOOR_SOURCE_PORT_COUNT - 1;
9877
9878
  var DOOR_SOURCE_PORTS = new SourcePortRange(DOOR_SOURCE_PORT_START, DOOR_SOURCE_PORT_END);
9879
+ var POOLED_SOCKET_IDLE_MS = 3e4;
9880
+ var POOLED_SOCKETS_KEPT_IDLE = 2;
9881
+ var POOLING = { keepAlive: true, timeout: POOLED_SOCKET_IDLE_MS, maxFreeSockets: POOLED_SOCKETS_KEPT_IDLE };
9878
9882
  var realAddressLookup = (host, _options, callback) => {
9879
9883
  if (net2.isIP(host) !== 0) {
9880
9884
  callback(null, [{ address: host, family: net2.isIP(host) }]);
@@ -9929,7 +9933,7 @@ function requestServername(options, fallback) {
9929
9933
  }
9930
9934
  var ExemptHttpAgent = class extends http.Agent {
9931
9935
  constructor(ports = DOOR_SOURCE_PORTS) {
9932
- super();
9936
+ super(POOLING);
9933
9937
  this.ports = ports;
9934
9938
  }
9935
9939
  ports;
@@ -9947,7 +9951,7 @@ var ExemptHttpAgent = class extends http.Agent {
9947
9951
  };
9948
9952
  var ExemptTlsAgent = class extends https2.Agent {
9949
9953
  constructor(ports = DOOR_SOURCE_PORTS) {
9950
- super();
9954
+ super(POOLING);
9951
9955
  this.ports = ports;
9952
9956
  }
9953
9957
  ports;
@@ -13282,6 +13286,7 @@ function createRcStreamHub(deps) {
13282
13286
  };
13283
13287
  const runLoop = async (attachment) => {
13284
13288
  let retriedUnauthorized = false;
13289
+ let refusedAuthorization;
13285
13290
  for (; ; ) {
13286
13291
  if (attachment.isStopped()) {
13287
13292
  return;
@@ -13297,6 +13302,11 @@ function createRcStreamHub(deps) {
13297
13302
  }
13298
13303
  return;
13299
13304
  }
13305
+ if (refusedAuthorization !== void 0 && credential.authorization === refusedAuthorization) {
13306
+ await deps.sleep(deps.backoffMs);
13307
+ continue;
13308
+ }
13309
+ refusedAuthorization = void 0;
13300
13310
  let outcome;
13301
13311
  try {
13302
13312
  outcome = await attempt(attachment, credential);
@@ -13323,7 +13333,8 @@ function createRcStreamHub(deps) {
13323
13333
  retriedUnauthorized = true;
13324
13334
  continue;
13325
13335
  }
13326
- deps.log?.(`rc stream ${attachment.sessionId}: the client read stream refused the observed Authorization bearer past one retry; backing off`);
13336
+ deps.log?.(`rc stream ${attachment.sessionId}: the client read stream refused the observed Authorization bearer past one retry; waiting for a fresh one`);
13337
+ refusedAuthorization = credential.authorization;
13327
13338
  await deps.sleep(deps.backoffMs);
13328
13339
  retriedUnauthorized = false;
13329
13340
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-use",
3
- "version": "9.4.1",
3
+ "version": "9.4.3",
4
4
  "description": "A profile manager and launcher for Claude Code that lets one person run multiple logins from one machine while controlling what gets shared between them.",
5
5
  "license": "MIT",
6
6
  "author": "Joseph Mearman <joseph@mearman.co.uk>",