@kenkaiiii/ggcoder 5.49.2 → 5.49.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/app-sidecar.js +16 -0
- package/dist/app-sidecar.js.map +1 -1
- package/dist/core/agent-session-pre-init-arming.test.d.ts +2 -0
- package/dist/core/agent-session-pre-init-arming.test.d.ts.map +1 -0
- package/dist/core/agent-session-pre-init-arming.test.js +60 -0
- package/dist/core/agent-session-pre-init-arming.test.js.map +1 -0
- package/dist/core/agent-session.d.ts +7 -1
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +9 -1
- package/dist/core/agent-session.js.map +1 -1
- package/package.json +4 -4
package/dist/app-sidecar.js
CHANGED
|
@@ -3976,6 +3976,14 @@ async function createSession(deps, opts) {
|
|
|
3976
3976
|
json(res, 400, { error: "invalid JSON body" });
|
|
3977
3977
|
return;
|
|
3978
3978
|
}
|
|
3979
|
+
// Same lock as POST /model, for the same reason: this retargets Ken's
|
|
3980
|
+
// chat session AND the autopilot reviewer, and `switchModel` on a
|
|
3981
|
+
// session mid-turn races the stream it is already consuming. The
|
|
3982
|
+
// footer picker is disabled to match; this is the enforcement.
|
|
3983
|
+
if (running || kenRunning || autopilotReviewing) {
|
|
3984
|
+
json(res, 409, { error: "cannot switch Ken's model while running" });
|
|
3985
|
+
return;
|
|
3986
|
+
}
|
|
3979
3987
|
if (modelId === null) {
|
|
3980
3988
|
// Clear the pin → follow GG Coder again, syncing both sessions back.
|
|
3981
3989
|
kenModelOverride = null;
|
|
@@ -4092,6 +4100,14 @@ async function createSession(deps, opts) {
|
|
|
4092
4100
|
return;
|
|
4093
4101
|
}
|
|
4094
4102
|
if (method === "POST" && url === "/thinking") {
|
|
4103
|
+
// The in-flight request already carries its reasoning config, so a
|
|
4104
|
+
// mid-run cycle cannot affect the turn the user is watching — it just
|
|
4105
|
+
// persists a level the footer then reports for a run that never used it.
|
|
4106
|
+
// Locked like POST /model; the footer button is disabled to match.
|
|
4107
|
+
if (running) {
|
|
4108
|
+
json(res, 409, { error: "cannot change reasoning level while running" });
|
|
4109
|
+
return;
|
|
4110
|
+
}
|
|
4095
4111
|
const st = session.getState();
|
|
4096
4112
|
const next = getNextThinkingLevel(st.provider, st.model, session.getThinkingLevel());
|
|
4097
4113
|
session.setThinkingLevel(next);
|