teapot-coding-agent 0.36.10 → 0.37.0
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/agent/mcp-registry.js +18 -2
- package/package.json +1 -1
- package/public/assets/index-C73aSEDD.js +33 -0
- package/public/assets/index-C73aSEDD.js.map +1 -0
- package/public/assets/index-De9yRQ8z.css +1 -0
- package/public/assets/{shiki-B7WJz7Ie.js → shiki-u60SktGf.js} +2 -2
- package/public/assets/shiki-u60SktGf.js.map +1 -0
- package/public/index.html +2 -2
- package/public/assets/index-BgdJufa_.js +0 -31
- package/public/assets/index-BgdJufa_.js.map +0 -1
- package/public/assets/index-DtUaInbZ.css +0 -1
- package/public/assets/shiki-B7WJz7Ie.js.map +0 -1
|
@@ -291,10 +291,26 @@ export class McpRegistry {
|
|
|
291
291
|
await this.finishFlow(name, pending);
|
|
292
292
|
}
|
|
293
293
|
catch (e) {
|
|
294
|
-
|
|
294
|
+
/**
|
|
295
|
+
* Report the CAUSE, not just the message.
|
|
296
|
+
*
|
|
297
|
+
* `UnauthorizedError` defaults its message to the bare string "Unauthorized" when the SDK
|
|
298
|
+
* constructs it without one (measured in the SDK source: `super(message ?? "Unauthorized")`).
|
|
299
|
+
* That is what the panel was showing, and it says nothing about which step failed — the
|
|
300
|
+
* exchange, the reconnect after it, or the original 401. The class name and any `cause`
|
|
301
|
+
* are the difference between "try again" and a diagnosis.
|
|
302
|
+
*/
|
|
303
|
+
const err = e;
|
|
304
|
+
const name = err.constructor?.name ?? "Error";
|
|
305
|
+
const cause = err.cause instanceof Error ? err.cause.message : String(err.cause ?? "");
|
|
306
|
+
const detail = [err.message, cause && cause !== err.message ? `(${cause})` : ""]
|
|
307
|
+
.filter(Boolean)
|
|
308
|
+
.join(" ");
|
|
309
|
+
const message = `${name}: ${detail}`;
|
|
310
|
+
auth.markError(message);
|
|
295
311
|
if (st.status === "authorizing")
|
|
296
312
|
st.status = "error";
|
|
297
|
-
st.lastError =
|
|
313
|
+
st.lastError = message;
|
|
298
314
|
await this.finishFlow(name, pending);
|
|
299
315
|
}
|
|
300
316
|
})();
|