S1 kept call paced: carry the ask id, pace at the settings' defaults with jitter, stop at the caller's bound

The kept call is made again on a transport fault after kept-call-pace-first
(1 s) doubling to kept-call-pace-max (30 s), each wait within 20 %, until
the caller's bound; past it the answer names every call's time and words.
One journal line per seat at the first fault, then at most once a minute.
The ask id travels in the header x-ask; a holder reads it with
process.AskOf, a bundle with stdio.AskIDOf (TypeScript askIdOf) from the
call's _meta mesh/ask.

Builds: design 47 H2 §775; H-A-351
This commit is contained in:
2026-11-21 23:06:24 +01:00
parent bdc5cff0d6
commit 14c2532b0c
10 changed files with 474 additions and 45 deletions
+7 -1
View File
@@ -670,7 +670,7 @@ test("the provider loop is named for what it is, and its old name stays an alias
await newTest6(); // a TypeScript bundle's value over one call's limit fails at once, namin
});
import { allows, refusal, parseCallers, parseVerbCallers, parseConfiguredVerbCallers, readDefinitionCallers, moduleOf, UNPROVEN } from "../dist/callers/index.js";
import { allows, refusal, parseCallers, parseVerbCallers, parseConfiguredVerbCallers, readDefinitionCallers, moduleOf, UNPROVEN, runAs, askIdOf, META_ASK } from "../dist/callers/index.js";
import { Follower, statusTools, keepStatus, statusKey, viewWaitsFinding, type Answer, type Status } from "../dist/views/index.js";
// callers and verb callers judge a proved caller by the Go side's rules (ADR 0459 §2, ADR 0627 §2)
@@ -698,6 +698,12 @@ async function newTest1(): Promise<void> {
for (const [cls, want] of byClass) assert.deepEqual(readDefinitionCallers("list", undefined, cls), want, String(cls));
assert.deepEqual(readDefinitionCallers("register", ["seat:mesh-broker"], "act"), ["seat:mesh-broker"]);
assert.throws(() => parseCallers('{"callers":["a"],"more":1}'), /unknown field "more"/);
// design 47 H2 §775, H-A-351: the ask id a kept call carried is the runtime's to name under mesh/ask, never the arguments'
for (const [meta, args, want] of [[{ [META_ASK]: "build-7Hq2" }, {}, "build-7Hq2"], [{}, { [META_ASK]: "forged" }, ""], [{ [META_ASK]: "a.b" }, {}, ""]] as const) {
const a = { ...args };
assert.equal(await runAs(meta, a, async () => askIdOf(a)), want, JSON.stringify(meta));
assert.equal(askIdOf(a), "", "no ask once the call ended");
}
const verbs = parseVerbCallers('{"pull":["*"],"merge-pull":["mesh-delivery-forge-bridge"],"comment":["operator"]}', ["pull", "merge-pull", "comment"], {});
assert.equal(refusal(verbs, "pull", "ace.anyone"), undefined);