oasis_test 0.1.68 → 0.1.69

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/index.js +23 -2
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -137528,10 +137528,17 @@ function stallOf(model, id, runtime) {
137528
137528
  ...since ? { since } : {}
137529
137529
  };
137530
137530
  }
137531
+ if (queueCause === "git-native-queue") {
137532
+ return {
137533
+ kind: "waiting_human",
137534
+ ...since ? { since } : {},
137535
+ detail: `\u961F\u5217\u538B\u7740 ${pending.length} \u7248 git-native \u7248\u672C\u843D\u4E0D\u4E0B\u53BB\u2014\u2014\u4EE3\u7801\u7C7B\u4E0D\u8D70 \`oasis integrate\`\uFF0C\u76EE\u524D\u65E0\u81EA\u52A8\u6536\u655B\u901A\u9053\uFF0C\u9700\u4EBA\u5DE5\u5904\u7F6E`
137536
+ };
137537
+ }
137531
137538
  return {
137532
137539
  kind: "waiting_system",
137533
137540
  ...since ? { since } : {},
137534
- detail: queueCause === "gate-frozen" ? `\u961F\u5217\u538B\u7740 ${pending.length} \u7248\u5F85\u843D\u5730\u2014\u2014head \u6B63\u5728\u6536\u5C3E\u8BC4\u5BA1\uFF08\u6682\u51BB\u7ED3\uFF09\uFF0C\u8BC4\u5BA1\u51FA\u7ED3\u679C\u540E\u624D\u8F6E\u5F97\u5230\u5B83\u4EEC` : queueCause === "parts-incomplete" ? `\u961F\u5217\u91CC\u5DF2\u6709 ${pending.length} \u7248\u90E8\u4EF6\u4EA7\u51FA\uFF0C\u8FD8\u5728\u7B49\u5176\u4F59\u90E8\u4EF6\u4EA7\u9F50\u624D\u80FD\u6536\u53E3` : queueCause === "git-native-queue" ? `\u961F\u5217\u538B\u7740 ${pending.length} \u7248 git-native \u7248\u672C\u843D\u4E0D\u4E0B\u53BB\u2014\u2014\u4EE3\u7801\u7C7B\u4E0D\u8D70 \`oasis integrate\`\uFF0C\u76EE\u524D\u65E0\u81EA\u52A8\u6536\u655B\u901A\u9053\uFF0C\u9700\u4EBA\u5DE5\u5904\u7F6E` : `\u961F\u5217\u538B\u7740 ${pending.length} \u7248\u5F85\u843D\u5730`
137541
+ detail: queueCause === "gate-frozen" ? `\u961F\u5217\u538B\u7740 ${pending.length} \u7248\u5F85\u843D\u5730\u2014\u2014head \u6B63\u5728\u6536\u5C3E\u8BC4\u5BA1\uFF08\u6682\u51BB\u7ED3\uFF09\uFF0C\u8BC4\u5BA1\u51FA\u7ED3\u679C\u540E\u624D\u8F6E\u5F97\u5230\u5B83\u4EEC` : queueCause === "parts-incomplete" ? `\u961F\u5217\u91CC\u5DF2\u6709 ${pending.length} \u7248\u90E8\u4EF6\u4EA7\u51FA\uFF0C\u8FD8\u5728\u7B49\u5176\u4F59\u90E8\u4EF6\u4EA7\u9F50\u624D\u80FD\u6536\u53E3` : `\u961F\u5217\u538B\u7740 ${pending.length} \u7248\u5F85\u843D\u5730`
137535
137542
  };
137536
137543
  }
137537
137544
  return null;
@@ -152185,6 +152192,8 @@ function withResilience(inner, cfg = {}) {
152185
152192
  let outerId = null;
152186
152193
  let outerKilled = false;
152187
152194
  let activeKill = null;
152195
+ let activeHandle = null;
152196
+ let supportsAppend = false;
152188
152197
  let settled = false;
152189
152198
  let lastInfo = { code: null, reason: "error" };
152190
152199
  let markReady;
@@ -152220,6 +152229,8 @@ function withResilience(inner, cfg = {}) {
152220
152229
  if (idleTimer) idleTimer.refresh();
152221
152230
  };
152222
152231
  activeKill = handle.kill.bind(handle);
152232
+ activeHandle = handle;
152233
+ if (typeof handle.appendInput === "function") supportsAppend = true;
152223
152234
  handle.onOutput?.((chunk) => {
152224
152235
  produced = true;
152225
152236
  bumpIdle();
@@ -152263,6 +152274,7 @@ function withResilience(inner, cfg = {}) {
152263
152274
  }
152264
152275
  const { info, produced } = await runOnce(handle);
152265
152276
  activeKill = null;
152277
+ activeHandle = null;
152266
152278
  lastInfo = info;
152267
152279
  const retryable = !outerKilled && attempt + 1 < maxAttempts && info.reason !== void 0 && RETRYABLE.has(info.reason) && !produced;
152268
152280
  if (!retryable) {
@@ -152289,6 +152301,15 @@ function withResilience(inner, cfg = {}) {
152289
152301
  },
152290
152302
  onTelemetry(cb) {
152291
152303
  telemetryCbs.push(cb);
152304
+ },
152305
+ // ADR-0093 对话追加:委托给当前 attempt 的句柄。仅当底层支持时才挂 appendInput——否则不暴露,
152306
+ // 让 session-manager 如实回 unsupported(真不支持)。attempt 间的空窗(activeHandle=null,退避重跑中)
152307
+ // 回 session-closing:这一轮正在换手,不是永久不支持。
152308
+ ...supportsAppend ? {
152309
+ appendInput: (input) => activeHandle?.appendInput ? activeHandle.appendInput(input) : Promise.resolve({ accepted: false, reason: "session-closing" })
152310
+ } : {},
152311
+ get canAppendInput() {
152312
+ return supportsAppend && activeHandle?.canAppendInput !== false && typeof activeHandle?.appendInput === "function";
152292
152313
  }
152293
152314
  };
152294
152315
  }
@@ -180428,7 +180449,7 @@ ${res.warning}`);
180428
180449
  init_src6();
180429
180450
 
180430
180451
  // src/index.ts
180431
- var PKG_VERSION = true ? "0.1.68" : "dev";
180452
+ var PKG_VERSION = true ? "0.1.69" : "dev";
180432
180453
  var OASIS_DIR = path26.join(os9.homedir(), ".oasis");
180433
180454
  var CONFIG_FILE = path26.join(OASIS_DIR, "node-config.json");
180434
180455
  var PID_FILE = path26.join(OASIS_DIR, "node.pid");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oasis_test",
3
- "version": "0.1.68",
3
+ "version": "0.1.69",
4
4
  "description": "Oasis node daemon + CLI — background daemon, auto-start, full server CLI",
5
5
  "bin": {
6
6
  "oasis": "./dist/index.js"