Merge remote-tracking branch 'origin/lane/b'
# Conflicts: # THREADS.md
This commit is contained in:
commit
a0ca7a2cbb
26
THREADS.md
26
THREADS.md
@ -10899,3 +10899,29 @@ anchors are your GLB), but the tooling is now waiting, not TODO.
|
||||
the standing risk is real and worth stating: **anything main.js does between `onCommit` and
|
||||
`attach` is invisible to the suite.** If a third thing ever needs to ride that seam, extract it
|
||||
then.
|
||||
[B] 2026-07-25 — ✅ **CLOSING: 535/0/0 (522 baseline + 13), pushed. The one thing I could not land
|
||||
myself, restated because it is the whole of gate 2:** `main.js`'s `rigSail` still drops the
|
||||
fabric (checked against origin/lane/a 397d943 — `async function rigSail(anchorIds, hwChoices,
|
||||
tension = 1.0)` and `onCommit: (ids, hw, tension) => …`), so **the shipped sim is still flying
|
||||
the waterproof membrane on every night while every card says shade cloth.** My side of the seam
|
||||
is landed and proven in `dev_rigging.html`; the two-line pickup is in my gate-2 entry above.
|
||||
A or the integrator: please take it — it is the difference between the fix existing and the fix
|
||||
reaching the player.
|
||||
|
||||
**Count delta, per file, for the integrator's sum:** sail.selftest +6 (3 knife/failCorner,
|
||||
3 clock), rigging.selftest +4 (3 inherit, 1 commit-clock), balance.test +3 (2 gate 2, 1 gate 3),
|
||||
sweep.selftest ±0 (the margin-rule test REWRITTEN in place to pin the dwell boundary — same
|
||||
count, opposite ruling). Node-verified standalone: sail 53/53, rigging 33/33, sweep 4/4.
|
||||
|
||||
**Two asserts mutation-checked, both directions:** drop `session.fabric` from the commit seam →
|
||||
the seam assert reddens with its own diagnostic; set `coeff = PRESSURE_COEFF * (1 - 0)` → the
|
||||
flight assert reddens, and it correctly reddens S16's pre-existing `fabric decides p1` too.
|
||||
|
||||
**Still open, filed not fixed (each with its mechanism named):** `balance.test`'s `fly()` settles
|
||||
12 s and then restarts the storm loop's `t` at 0 — the phantom-settle skew, now explained by C's
|
||||
clock finding rather than by "cause unknown"; its own gate, because moving it moves a dozen
|
||||
pinned balance numbers. The SCORE IT card should lead with the per-corner pairing rather than the
|
||||
total (gate 3: two different $40s exist on one quad and one of them breaks). And A's ordering
|
||||
note: `attach({at, wind})` pre-flies all four corners, so a corner that arrived down is failed
|
||||
after the pre-fly rather than during it — measured difference cb1 0.80 vs 0.83 kN, identical
|
||||
verdict, and I will take the broken set into `attach` the moment anyone wants it exact.
|
||||
|
||||
@ -541,8 +541,18 @@ export class RiggingSession {
|
||||
this.picks = ring.map((a) => byId.get(a.id));
|
||||
}
|
||||
|
||||
/** Hand the finished rig to the sim. Mirrors contracts.js sailRig.attach(). */
|
||||
commit(rig) {
|
||||
/**
|
||||
* Hand the finished rig to the sim. Mirrors contracts.js sailRig.attach().
|
||||
*
|
||||
* `opts` is forwarded to `attach` untouched, which exists for exactly one
|
||||
* reason (SPRINT18, Lane C's finding): an emergency callout's storm is already
|
||||
* 30 seconds old, and `attach({at, wind})` is what stops the cloth flying the
|
||||
* wrong sixty seconds of it. Without this the only way to seed the clock would
|
||||
* be a SECOND call after commit — a step a caller can forget, on the one night
|
||||
* where forgetting it silently understates every load by 4x. The session's
|
||||
* public-moves discipline and a correct clock should not be a choice.
|
||||
*/
|
||||
commit(rig, opts = undefined) {
|
||||
if (!this.canStart) throw new Error(`sail needs ${MAX_CORNERS} corners, have ${this.picks.length}`);
|
||||
// gate 2, the promise the sprint doc names ("enforces the budget cap at
|
||||
// commit"): by now the refusals above have made these states unreachable
|
||||
@ -570,7 +580,7 @@ export class RiggingSession {
|
||||
// shade cloth + C's 0.40 downdraft drop p1 to 1.08 kN, under a $5
|
||||
// carabiner's rating, which is the $10 that closes the $90 -> $80 gap.)
|
||||
if (rig.setFabric) rig.setFabric(this.fabric);
|
||||
return rig.attach(this.picks.map((p) => p.anchorId), this.picks.map((p) => p.hw), this.tension);
|
||||
return rig.attach(this.picks.map((p) => p.anchorId), this.picks.map((p) => p.hw), this.tension, opts);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -605,6 +605,25 @@ test('gate 1: ⚠️ the refund cannot pay you for a stranger\'s steel — the k
|
||||
return `inherited steel refunds $0; the $${RATED.cost} the player bought refunds, and only that`;
|
||||
});
|
||||
|
||||
test('gate 1: commit carries the mid-storm clock through to the sail', () => {
|
||||
// The emergency flow is inherit -> commit -> put the dead corner down -> roll.
|
||||
// If commit cannot pass `at`, seeding the clock becomes a separate call on the
|
||||
// one night where forgetting it understates every load ~4x (C's finding).
|
||||
const s = session();
|
||||
assert(s.inherit(INHERITED).ok, 'inherit refused');
|
||||
const rig = s.commit(new SailRig({ anchors: ANCHORS, gridN: 10 }), { at: 30 });
|
||||
assert(rig.t === 30,
|
||||
`commit({at:30}) left the cloth at t=${rig.t}. It is now flying the storm's FIRST sixty seconds ` +
|
||||
'under a sky flying its last sixty, and nothing about that is visible from outside');
|
||||
assert(rig.clockSkew === 0, `a freshly seeded commit already reads ${rig.clockSkew}s of skew`);
|
||||
// and the ordinary night is untouched — no opts, clock at 0
|
||||
const plain = session();
|
||||
for (const id of ['h1', 'h3', 'p1', 'p2']) plain.rig(id);
|
||||
assert(plain.commit(new SailRig({ anchors: ANCHORS, gridN: 10 })).t === 0,
|
||||
'an ordinary commit no longer starts its storm at 0');
|
||||
return 'commit(rig, {at:30}) seeds the cloth to 30s; a plain commit still starts at 0';
|
||||
});
|
||||
|
||||
test('gate 1: an inherited rig still obeys the client, and refuses a rig it cannot build', () => {
|
||||
const s = session();
|
||||
s.setConstraints([HOUSE_BAN]);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user