agent-shim 7.12.0 → 7.12.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.
Files changed (2) hide show
  1. package/dist/cli.cjs +8 -3
  2. package/package.json +1 -1
package/dist/cli.cjs CHANGED
@@ -60985,7 +60985,7 @@ function registerIdentityCommand(program2, deps) {
60985
60985
  // package.json
60986
60986
  var package_default = {
60987
60987
  name: "agent-shim",
60988
- version: "7.12.0",
60988
+ version: "7.12.1",
60989
60989
  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.",
60990
60990
  license: "MIT",
60991
60991
  author: "Joseph Mearman <joseph@mearman.co.uk>",
@@ -65213,7 +65213,10 @@ async function forwardThroughHeadroom(request6, response, target) {
65213
65213
  if (!request6.signal.aborted) {
65214
65214
  response.end();
65215
65215
  }
65216
- } catch {
65216
+ } catch (error62) {
65217
+ if (!request6.signal.aborted) {
65218
+ target.log(`front door: headroom hop to 127.0.0.1:${String(port)} ended mid-stream (${request6.method} ${new URL(request6.url, "http://127.0.0.1").pathname}): ${error62 instanceof Error ? error62.message : String(error62)}`);
65219
+ }
65217
65220
  response.destroy();
65218
65221
  }
65219
65222
  resolve(void 0);
@@ -65222,7 +65225,9 @@ async function forwardThroughHeadroom(request6, response, target) {
65222
65225
  };
65223
65226
  const hop = http3.request({ host: "127.0.0.1", port, method: request6.method, path: request6.url, headers, agent: HOP_AGENT }, onUpstreamResponse);
65224
65227
  hop.on("error", (error62) => {
65225
- target.log(`front door: headroom hop to 127.0.0.1:${String(port)} failed: ${error62.message}`);
65228
+ const phase = response.headersSent ? "mid-stream" : "before the response started";
65229
+ const code = "code" in error62 && typeof error62.code === "string" ? ` ${error62.code}` : "";
65230
+ target.log(`front door: headroom hop to 127.0.0.1:${String(port)} failed (${request6.method} ${new URL(request6.url, "http://127.0.0.1").pathname}, ${phase}): ${error62.message}${code}`);
65226
65231
  if (!response.headersSent) {
65227
65232
  response.start(HTTP_BAD_GATEWAY2, { "Content-Type": "application/json" });
65228
65233
  void response.write(JSON.stringify({ type: "error", error: { type: "api_error", message: `agent-shim front door: the headroom daemon is unreachable (${error62.message})` } })).then(() => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agent-shim",
3
- "version": "7.12.0",
3
+ "version": "7.12.1",
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>",