claude-use 11.44.1 → 11.44.2
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 +29 -4
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
package/dist/cli.cjs
CHANGED
|
@@ -34701,7 +34701,7 @@ var init_package = __esm({
|
|
|
34701
34701
|
"package.json"() {
|
|
34702
34702
|
package_default = {
|
|
34703
34703
|
name: "claude-use",
|
|
34704
|
-
version: "11.44.
|
|
34704
|
+
version: "11.44.2",
|
|
34705
34705
|
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.",
|
|
34706
34706
|
license: "MIT",
|
|
34707
34707
|
author: "Joseph Mearman <joseph@mearman.co.uk>",
|
|
@@ -34986,7 +34986,7 @@ function parseProviderPath(path65) {
|
|
|
34986
34986
|
}
|
|
34987
34987
|
return { provider: decodeURIComponent(tail.slice(0, slash)), rest: tail.slice(slash) };
|
|
34988
34988
|
}
|
|
34989
|
-
var HEADROOM_SESSION_HEADER, INTERNAL_HEADER_NAMES, IDENTITY_HEADER, SESSION_HEADER, PROVIDER_HEADER, HEADROOM_FLAG_HEADER, ROUTE_BY_NAME_HEADER, PROJECT_ID_HEADER, CLIENT_SESSION_HEADER, HEADROOM_BASE_URL_HEADER, AUTH_HEADER, HOP_SECRET_HEADER, HOP_ID_HEADER, PROVIDER_PATH_PREFIX;
|
|
34989
|
+
var HEADROOM_SESSION_HEADER, INTERNAL_HEADER_NAMES, IDENTITY_HEADER, SESSION_HEADER, PROVIDER_HEADER, HEADROOM_FLAG_HEADER, ROUTE_BY_NAME_HEADER, PROJECT_ID_HEADER, CLIENT_SESSION_HEADER, HEADROOM_BASE_URL_HEADER, AUTH_HEADER, HOP_SECRET_HEADER, HOP_ID_HEADER, MODEL_CHOICE_HEADER, PROVIDER_PATH_PREFIX;
|
|
34990
34990
|
var init_route = __esm({
|
|
34991
34991
|
"src/frontdoor/route.ts"() {
|
|
34992
34992
|
"use strict";
|
|
@@ -35015,6 +35015,7 @@ var init_route = __esm({
|
|
|
35015
35015
|
AUTH_HEADER = "x-agent-shim-auth";
|
|
35016
35016
|
HOP_SECRET_HEADER = "x-agent-shim-hop";
|
|
35017
35017
|
HOP_ID_HEADER = "x-agent-shim-hop-id";
|
|
35018
|
+
MODEL_CHOICE_HEADER = "x-agent-shim-model-choice";
|
|
35018
35019
|
PROVIDER_PATH_PREFIX = "/providers/";
|
|
35019
35020
|
}
|
|
35020
35021
|
});
|
|
@@ -116916,6 +116917,8 @@ function createDoorPipelines(deps) {
|
|
|
116916
116917
|
direct: {
|
|
116917
116918
|
resolveRoute: deps.resolveRoute,
|
|
116918
116919
|
responseObservers: [],
|
|
116920
|
+
// The direct pipeline's responses are consumed by this door's own headroom hop, never by a client, so the noted model choice rides the head home as MODEL_CHOICE_HEADER (see `exposeModelChoiceOnHead`) instead of dying with the observers this pipeline deliberately runs none of.
|
|
116921
|
+
exposeModelChoiceOnHead: true,
|
|
116919
116922
|
admit: admitHop(deps.hopSecret, deps.custody),
|
|
116920
116923
|
headroomDecision: deps.headroomDecision,
|
|
116921
116924
|
now: deps.now,
|
|
@@ -130264,6 +130267,22 @@ async function collectBody(body) {
|
|
|
130264
130267
|
});
|
|
130265
130268
|
});
|
|
130266
130269
|
}
|
|
130270
|
+
function parseModelChoiceHeader(value2) {
|
|
130271
|
+
if (value2 === void 0) return void 0;
|
|
130272
|
+
let parsed;
|
|
130273
|
+
try {
|
|
130274
|
+
parsed = JSON.parse(value2);
|
|
130275
|
+
} catch {
|
|
130276
|
+
return void 0;
|
|
130277
|
+
}
|
|
130278
|
+
if (typeof parsed !== "object" || parsed === null || !("requested" in parsed) || !("providers" in parsed) || typeof parsed.requested !== "string" || !Array.isArray(parsed.providers)) return void 0;
|
|
130279
|
+
const providers = [];
|
|
130280
|
+
for (const name of parsed.providers) {
|
|
130281
|
+
if (typeof name !== "string") return void 0;
|
|
130282
|
+
providers.push(name);
|
|
130283
|
+
}
|
|
130284
|
+
return { requested: parsed.requested, providers };
|
|
130285
|
+
}
|
|
130267
130286
|
async function forwardThroughHeadroom(request7, response, target) {
|
|
130268
130287
|
const collected = await collectBody(request7.body);
|
|
130269
130288
|
if (collected.kind === "failed") {
|
|
@@ -130289,7 +130308,12 @@ async function hopOnce(request7, response, target, body, mayRetry) {
|
|
|
130289
130308
|
const { socketPath, headers } = target;
|
|
130290
130309
|
return await new Promise((resolve2) => {
|
|
130291
130310
|
const onUpstreamResponse = (upstreamResponse) => {
|
|
130292
|
-
|
|
130311
|
+
const { [MODEL_CHOICE_HEADER]: choiceHeader, ...head } = responseHeaders(upstreamResponse.headers);
|
|
130312
|
+
const choice = parseModelChoiceHeader(choiceHeader);
|
|
130313
|
+
if (choice !== void 0) {
|
|
130314
|
+
response.noteModelChoice?.(choice);
|
|
130315
|
+
}
|
|
130316
|
+
response.start(upstreamResponse.statusCode ?? HTTP_BAD_GATEWAY2, head);
|
|
130293
130317
|
response.flush();
|
|
130294
130318
|
const stream = async () => {
|
|
130295
130319
|
try {
|
|
@@ -130415,6 +130439,7 @@ function createRoutedResponse(response, context) {
|
|
|
130415
130439
|
return headersSent;
|
|
130416
130440
|
},
|
|
130417
130441
|
start: (status, headers) => {
|
|
130442
|
+
const head = deps.exposeModelChoiceOnHead === true && request7.modelChoice.value !== void 0 ? { ...headers, [MODEL_CHOICE_HEADER]: JSON.stringify(request7.modelChoice.value) } : headers;
|
|
130418
130443
|
for (const observe of deps.responseObservers) {
|
|
130419
130444
|
try {
|
|
130420
130445
|
const body = observe({ session, route, method: request7.method, path: request7.path, servedPath: context.servedPath, receivedAt: request7.receivedAt, viaHeadroom: request7.viaHeadroom, lineage: request7.thread.lineage, modelChoice: request7.modelChoice.value, status, headers });
|
|
@@ -130425,7 +130450,7 @@ function createRoutedResponse(response, context) {
|
|
|
130425
130450
|
deps.log(`front door: response observer threw for ${route}: ${describeThrown(error63)}`);
|
|
130426
130451
|
}
|
|
130427
130452
|
}
|
|
130428
|
-
response.writeHead(status,
|
|
130453
|
+
response.writeHead(status, head);
|
|
130429
130454
|
headersSent = true;
|
|
130430
130455
|
},
|
|
130431
130456
|
noteModelChoice: (choice) => {
|
package/dist/index.cjs
CHANGED
|
@@ -3151,7 +3151,7 @@ var init_package = __esm({
|
|
|
3151
3151
|
"package.json"() {
|
|
3152
3152
|
package_default = {
|
|
3153
3153
|
name: "claude-use",
|
|
3154
|
-
version: "11.44.
|
|
3154
|
+
version: "11.44.2",
|
|
3155
3155
|
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.",
|
|
3156
3156
|
license: "MIT",
|
|
3157
3157
|
author: "Joseph Mearman <joseph@mearman.co.uk>",
|
package/dist/index.mjs
CHANGED
|
@@ -3127,7 +3127,7 @@ var init_package = __esm({
|
|
|
3127
3127
|
"package.json"() {
|
|
3128
3128
|
package_default = {
|
|
3129
3129
|
name: "claude-use",
|
|
3130
|
-
version: "11.44.
|
|
3130
|
+
version: "11.44.2",
|
|
3131
3131
|
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.",
|
|
3132
3132
|
license: "MIT",
|
|
3133
3133
|
author: "Joseph Mearman <joseph@mearman.co.uk>",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claude-use",
|
|
3
|
-
"version": "11.44.
|
|
3
|
+
"version": "11.44.2",
|
|
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>",
|