@roomi-fields/grillhouse 0.28.0 → 0.28.1

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.
@@ -5,5 +5,5 @@
5
5
  "author": {
6
6
  "name": "Romain Peyrichou"
7
7
  },
8
- "version": "0.28.0"
8
+ "version": "0.28.1"
9
9
  }
@@ -142,11 +142,15 @@ circuit ne lit pas, tombé à la relecture après 25 min de passes finales).
142
142
  engendré se réécrit par sa commande, puis le circuit rejoue seulement ce qui en dépend. Une passe
143
143
  finale dont un rouge est celui d'une référence, mêlé ou non à d'autres, régénère les références
144
144
  qu'il nomme (4.2), puis rejoue la passe finale restreinte à ce que la régénération change ; les
145
- autres rouges restent, chacun à son propriétaire. Des contrôles du plan verts hors des rouges de
146
- références les régénèrent aussitôt, comme make refait un fichier engendré avant ce qui le lit :
147
- la passe finale due joue alors une fois, sur l'arbre régénéré, sans régénérer de nouveau une
148
- référence régénérée sur ce même arbre (BP 320.3.9 : le plafond des mots, rouge aux contrôles,
149
- laissé à une passe finale qui rejouait les mêmes tests sur le même arbre, 6,1 min). Les références sont celles que le projet déclare
145
+ autres rouges restent, chacun à son propriétaire. Des contrôles du plan où rougit une référence,
146
+ mêlée ou non à d'autres rouges, la régénèrent avant qu'aucun rouge n'aille au développeur, comme
147
+ Bazel construit une genrule avant les tests qui la lisent : mêlés à d'autres rouges, les contrôles
148
+ du plan rejouent sur l'arbre régénéré, qui juge un test lisant la référence (BP 320.6.5 : un test
149
+ qui lit le hachage que déclarent les `turbo.json`, rouge à côté de leur garde, envoyé à un
150
+ développeur qui n'avait rien à livrer, puis ne pouvait pas les écrire) ; seuls, la passe finale
151
+ due joue une fois, sur l'arbre régénéré. Aucune ne régénère de nouveau une référence régénérée
152
+ sur ce même arbre (BP 320.3.9 : le plafond des mots, rouge aux contrôles, laissé à une passe
153
+ finale qui rejouait les mêmes tests sur le même arbre, 6,1 min). Les références sont celles que le projet déclare
150
154
  (`grillhouse.references`) et celles du cadre, dans chaque projet (`referencesDuCadre` de
151
155
  `circuit.mjs`, les fichiers que le module du langage engendre, `fichiersEngendres`) : l'index des
152
156
  interfaces, les `turbo.json` des paquets et les rapports d'API, chacun
@@ -285,6 +289,18 @@ commande, vaut `comportement` : le circuit entier. Ainsi un geste sans comportem
285
289
  ni testwriter ni développeur (BP 320.16 : 38 outils déplacés par mv, 117 commentaires ; 320.40.1 :
286
290
  une variable inutilisée, 4 séances ; si61.8 : un seuil 77 → 95, 2 séances « aucun code à livrer »).
287
291
 
292
+ **Le plan fixe les noms publiés** : comme l'approbation d'un propriétaire de code (CODEOWNERS)
293
+ porte sur ce qu'il a relu, la fiche du plan porte les noms qu'un composant publie à un autre et
294
+ que le lot ajoute aux lignes « Consommateurs » de l'INTERFACE du fournisseur (`noms_publies` de
295
+ `resultats.mjs` : le fournisseur, chaque consommateur, ses noms). Le circuit les écrit dans la
296
+ description (« ## Noms publiés », après la sorte), réécrite à chaque plan depuis la dernière fiche
297
+ (une liste vide l'efface ; une fiche sans le champ garde la section que la description porte,
298
+ celle qu'un superviseur a écrite à la main comprise), et la garde des consommateurs (`consommateurs-arbitres.mjs`), qui lit cette section, laisse entrer
299
+ ces lignes sans arbitrage ; un nom que le plan ne publie pas reste refusé. Ainsi le développeur
300
+ écrit les lignes que le plan fixe sans arrêt ni geste du superviseur (BP 320.14.2.10, 320.28,
301
+ 320.6.5 : un critère seul nommait les noms, la garde refusait le lot, et le superviseur écrivait
302
+ la section à la main avant une nouvelle séance).
303
+
288
304
  **Un circuit par ticket** : comme une demande de fusion (un auteur, une série de tests et de
289
305
  code, une CI sur l'ensemble, une revue), le circuit lance un seul testwriter et un seul
290
306
  développeur pour tout le ticket, chacun dans l'enveloppe de tous les paquets du plan, puis la
@@ -1,7 +1,7 @@
1
1
  import { atom, read, update } from 'claude-code'
2
2
  import type { EngineInterface, Register } from 'claude-code'
3
3
 
4
- import type { Etat, Fiche, Ligne, Tableau } from '../types'
4
+ import type { Etat, Fiche, Ligne, Lu, Tableau } from '../types'
5
5
 
6
6
  // The board of a Grillhouse project, in the pane (/grillhouse) on its three levels. The frame's
7
7
  // command of the project (`node_modules/.bin/grillhouse tableau`, the package
@@ -13,7 +13,10 @@ import type { Etat, Fiche, Ligne, Tableau } from '../types'
13
13
  // the SDK without a display): the board comes with the terminal's prompt, or with a surface that
14
14
  // attaches, as the desktop app's Code tab does (`activer`). In a Grillhouse project, every
15
15
  // session, an agent's copy included, has a Bash command that starts with cd refused, with the
16
- // form to take (`env -C`, `git -C`).
16
+ // form to take (`env -C`, `git -C`). A session that coordinates several projects adds them to its
17
+ // pane (`/grillhouse ajouter <chemin>`, `/grillhouse retirer <chemin>`), as a multi-root workspace
18
+ // of VS Code lists its folders: the list is kept for the session's folder in the mod's store, each
19
+ // project's board is measured in its folder, and the pane fuses them (`fusionner`).
17
20
  const PANE = 'grillhouse'
18
21
  // The frame's command, which the project's `npm install` links, and its package.
19
22
  const GRILLHOUSE = 'node_modules/.bin/grillhouse'
@@ -62,6 +65,7 @@ const etat = atom({ plugin: 'grillhouse', key: 'etat' } as const, {
62
65
  vue: 'tableau',
63
66
  groupe: null,
64
67
  texte: null,
68
+ projets: [],
65
69
  } as Etat)
66
70
 
67
71
  export const k = (n: number) =>
@@ -195,6 +199,111 @@ export const aMesurer = (s: Etat, maintenant: number) =>
195
199
  export const couleur = (ton: Ligne['ton']) =>
196
200
  ton === 'alerte' ? 'red' : ton === 'attention' ? 'yellow' : ton === 'actif' ? 'cyan' : undefined
197
201
 
202
+ // The key of the mod's store that keeps the projects a session in <dossier> shows beside its own.
203
+ export const cleProjets = (dossier: string) => `projets:${dossier}`
204
+
205
+ // The folder <chemin> names from the session's folder <dossier>: absolute, `~/` under the home
206
+ // <maison>, or relative; its `.` and `..` resolved, no slash at its end.
207
+ export function dossierDe(chemin: string, dossier: string, maison = ''): string {
208
+ const brut = chemin.startsWith('/')
209
+ ? chemin
210
+ : chemin === '~' || chemin.startsWith('~/')
211
+ ? `${maison}${chemin.slice(1)}`
212
+ : `${dossier}/${chemin}`
213
+ const parts: string[] = []
214
+ for (const p of brut.split('/')) {
215
+ if (!p || p === '.') continue
216
+ if (p === '..') parts.pop()
217
+ else parts.push(p)
218
+ }
219
+ return `/${parts.join('/')}`
220
+ }
221
+
222
+ // A project's label in a fused board: its ticket prefix, else its folder's name.
223
+ const nomDu = (dossier: string) => dossier.split('/').filter(Boolean).pop() ?? dossier
224
+ const etiquetteDe = (l: Lu) => l.tableau?.prefixe || nomDu(l.dossier)
225
+
226
+ // The width of the step's column in a fused board, « 3 Code », « ? Question ».
227
+ const ETAPE = 13
228
+ // A ticket line's step in words: « ? Question » stopped on a question, « ■ Arrêté » after the
229
+ // steps, else its number and title.
230
+ const libelleDEtape = (l: Ligne) =>
231
+ l.question ? '? Question' : l.etape?.numero ? `${l.etape.numero} ${l.etape.titre}` : '■ Arrêté'
232
+ // The rank a ticket line sorts by in a fused board, the maquette's order: the steps from the last
233
+ // to the first, a step after its sub-steps (« 4 » is « 4.0 »), then the questions, then the
234
+ // circuits stopped after the steps.
235
+ const rangDe = (l: Ligne): number[] =>
236
+ l.question ? [1] : l.etape?.numero ? [0, ...l.etape.numero.split('.').map(n => -Number(n))] : [2]
237
+ const comparer = (a: number[], b: number[]) => {
238
+ for (let i = 0; i < Math.max(a.length, b.length); i++) {
239
+ const d = (a[i] ?? 0) - (b[i] ?? 0)
240
+ if (d) return d
241
+ }
242
+ return 0
243
+ }
244
+ const couperA = (x: string, n: number) => (x.length > n ? `${x.slice(0, n - 1)}…` : x)
245
+
246
+ // The boards of several projects fused into one, the owner's maquette (grillhouse-erp): the tickets
247
+ // at a step of each project in one list sorted by step, each line « <étape> [<projet>] <id> —
248
+ // <sujet> », then each project's chantiers prefixed by its label; the states' view of each project
249
+ // under its label; every card, and the folder of each ticket's project (`dossiers`); a footer
250
+ // (`pied`) that sums up each project, « osc 2▶ · SH 1▶ 3 en attente · OSD 0 », and names each
251
+ // project whose board does not read with its fault.
252
+ export function fusionner(lus: Lu[]): Tableau {
253
+ const lisibles = lus.flatMap(l => (l.tableau && !l.erreur ? [{ ...l, tableau: l.tableau }] : []))
254
+ const fautifs = lus.filter(l => !l.tableau || l.erreur)
255
+ const large = Math.max(0, ...lisibles.map(l => etiquetteDe(l).length + 2))
256
+ const prefixe = (l: Lu) => `[${etiquetteDe(l)}]`.padEnd(large)
257
+ const tickets = lisibles.flatMap(lu =>
258
+ lu.tableau.lignes
259
+ .filter(l => l.section === 'agents' && l.ticket && l.etape)
260
+ .map(l => ({
261
+ ...l,
262
+ texte: `${couperA(libelleDEtape(l), ETAPE).padEnd(ETAPE)} ${prefixe(lu)} ${l.ticket} — ${lu.tableau.fiches[l.ticket ?? '']?.titre ?? ''}`,
263
+ })),
264
+ )
265
+ tickets.sort((a, b) => comparer(rangDe(a), rangDe(b)))
266
+ const chantiers = lisibles.flatMap(lu =>
267
+ lu.tableau.lignes
268
+ .filter(l => l.chantier && l.ticket)
269
+ .map(l => ({ ...l, texte: `[${etiquetteDe(lu)}] ${l.texte}` })),
270
+ )
271
+ const vueEtats: Ligne[] = lisibles.flatMap((lu, i) => [
272
+ ...(i ? [{ texte: '', section: 'etats' as const }] : []),
273
+ { texte: etiquetteDe(lu), ton: 'titre' as const, section: 'etats' as const },
274
+ ...(lu.tableau.vueEtats ?? []),
275
+ ])
276
+ // The summaries share a line while they fit the pane's width, then go on to the next.
277
+ const pied: Ligne[] = []
278
+ for (const lu of lisibles) {
279
+ const c = lu.tableau.global?.compteurs
280
+ const resume = [
281
+ etiquetteDe(lu),
282
+ ...(c?.enCours ? [`${c.enCours}▶`] : []),
283
+ ...(c?.enAttente ? [`${c.enAttente} en attente`] : []),
284
+ ...(!c?.enCours && !c?.enAttente ? ['0'] : []),
285
+ ].join(' ')
286
+ const avant = pied[pied.length - 1]
287
+ if (avant && avant.texte.length + 3 + resume.length <= COLONNES) avant.texte += ` · ${resume}`
288
+ else pied.push({ texte: resume, ton: 'discret', section: 'agents' })
289
+ }
290
+ for (const lu of fautifs) {
291
+ const faute = (lu.erreur ?? '').split('\n')[0]?.trim() || 'le tableau ne se lit pas'
292
+ pied.push({ texte: `⚠ ${nomDu(lu.dossier)} : ${faute}`, ton: 'alerte', section: 'agents' })
293
+ }
294
+ const dossiers: Record<string, string> = {}
295
+ for (const lu of lisibles) for (const id of Object.keys(lu.tableau.fiches)) dossiers[id] ??= lu.dossier
296
+ return {
297
+ lignes: [...tickets, ...(chantiers.length ? [{ texte: '', section: 'chantier' as const }, ...chantiers] : [])],
298
+ vueEtats,
299
+ groupes: {},
300
+ fiches: Object.assign({}, ...lisibles.map(l => l.tableau.fiches)) as Tableau['fiches'],
301
+ dernier: lisibles.map(l => l.tableau.dernier).find(Boolean) ?? null,
302
+ pied,
303
+ dossiers,
304
+ }
305
+ }
306
+
198
307
  // The session's project, whether it is a Grillhouse project, whether the board applies to it, and
199
308
  // whether the board is on.
200
309
  let cwd = ''
@@ -265,29 +374,41 @@ async function bientot($: EngineInterface) {
265
374
  await rafraichir($)
266
375
  }
267
376
 
268
- async function mesurer($: EngineInterface) {
269
- if (!actif) return
270
- const r = await $.process.run([GRILLHOUSE, 'tableau'], { cwd, timeoutMs: 20_000 })
271
- if (r.exitCode !== 0) {
272
- await update($, etat, s => ({ ...s, erreur: r.stderr.slice(0, 300) }))
273
- return
274
- }
275
- // A board past what a process returns (4 MiB) or that does not parse is said, never thrown.
276
- let tableau: Tableau
377
+ // The board of the project in <dossier>, or the fault that keeps it out. A board past what a
378
+ // process returns (4 MiB) or that does not parse is said, never thrown.
379
+ async function lire($: EngineInterface, dossier: string): Promise<Lu> {
380
+ const r = await $.process.run([GRILLHOUSE, 'tableau'], { cwd: dossier, timeoutMs: 20_000 })
381
+ if (r.exitCode !== 0) return { dossier, tableau: null, erreur: r.stderr.slice(0, 300) }
277
382
  try {
278
383
  if (r.isStdoutTruncated) throw new Error('la sortie de grillhouse tableau dépasse 4 Mio')
279
- tableau = JSON.parse(r.stdout) as Tableau
384
+ return { dossier, tableau: JSON.parse(r.stdout) as Tableau, erreur: null }
280
385
  } catch (err) {
281
- await update($, etat, s => ({ ...s, erreur: `Tableau illisible : ${(err as Error).message}`.slice(0, 300) }))
386
+ return { dossier, tableau: null, erreur: `Tableau illisible : ${(err as Error).message}`.slice(0, 300) }
387
+ }
388
+ }
389
+
390
+ // The session's board alone, a fault keeping the last board read; with other projects, every
391
+ // board, read side by side, fused.
392
+ async function mesurer($: EngineInterface) {
393
+ if (!actif) return
394
+ const { projets } = await read($, etat)
395
+ if (projets.length) {
396
+ const lus = await Promise.all([cwd, ...projets].map(d => lire($, d)))
397
+ await update($, etat, s => ({ ...s, tableau: fusionner(lus), erreur: null, lu: Date.now() }))
282
398
  return
283
399
  }
284
- await update($, etat, s => ({ ...s, tableau, erreur: null, lu: Date.now() }))
400
+ const { tableau, erreur } = await lire($, cwd)
401
+ await update($, etat, s => (tableau ? { ...s, tableau, erreur: null, lu: Date.now() } : { ...s, erreur }))
285
402
  }
286
403
 
287
- // The whole text of a ticket, read from Beads when the card fills the pane: the board carries
288
- // only each card's start.
289
- async function lireTexte($: EngineInterface, id: string) {
290
- const r = await $.process.run(['bd', 'show', id, '--json'], { cwd, timeoutMs: 20_000 })
404
+ // The folder of the project the ticket <id> belongs to: its own in a fused board, else the
405
+ // session's.
406
+ const dossierDu = (t: Tableau | null, id: string) => t?.dossiers?.[id] ?? cwd
407
+
408
+ // The whole text of a ticket, read from Beads in its project when the card fills the pane: the
409
+ // board carries only each card's start.
410
+ async function lireTexte($: EngineInterface, id: string, dossier: string) {
411
+ const r = await $.process.run(['bd', 'show', id, '--json'], { cwd: dossier, timeoutMs: 20_000 })
291
412
  let contenu = ''
292
413
  try {
293
414
  const lu = JSON.parse(r.stdout) as { description?: string }[] | { description?: string }
@@ -301,13 +422,52 @@ async function lireTexte($: EngineInterface, id: string) {
301
422
  // The status a chantier's switch gives it: in progress → open, anything else → in progress.
302
423
  export const bascule = (statut: string | undefined) => (statut === 'in_progress' ? 'open' : 'in_progress')
303
424
 
304
- // Switches a chantier on or off in Beads, then measures the board again.
305
- async function basculer($: EngineInterface, id: string, statut: string | undefined) {
306
- const r = await $.process.run(['bd', 'update', id, '--status', bascule(statut)], { cwd, timeoutMs: 20_000 })
425
+ // Switches a chantier on or off in Beads, in its project, then measures the board again.
426
+ async function basculer($: EngineInterface, id: string, statut: string | undefined, dossier: string) {
427
+ const r = await $.process.run(['bd', 'update', id, '--status', bascule(statut)], {
428
+ cwd: dossier,
429
+ timeoutMs: 20_000,
430
+ })
307
431
  if (r.exitCode !== 0) await $.ui.toast(`Le chantier n'a pas basculé : ${r.stderr.slice(0, 200)}`)
308
432
  await rafraichir($)
309
433
  }
310
434
 
435
+ // The projects the store keeps for the session's folder; none when it holds nothing readable.
436
+ async function lireLaListe($: EngineInterface): Promise<string[]> {
437
+ try {
438
+ const v = await $.store.get(cleProjets(cwd))
439
+ return Array.isArray(v) ? v.filter((x): x is string => typeof x === 'string') : []
440
+ } catch {
441
+ return []
442
+ }
443
+ }
444
+
445
+ // Adds a project to the pane or removes it, by its path; a path that is not a Grillhouse project
446
+ // is refused by its name. The list is kept for the session's folder, and the board measured again.
447
+ async function changerLaListe($: EngineInterface, geste: 'ajouter' | 'retirer', chemin: string): Promise<string> {
448
+ if (!chemin) return `Usage : /grillhouse ${geste} <chemin>.`
449
+ const maison = chemin.startsWith('~') ? ((await $.env.get('HOME')) ?? '') : ''
450
+ const dossier = dossierDe(chemin, cwd, maison)
451
+ const { projets } = await read($, etat)
452
+ let liste: string[]
453
+ if (geste === 'ajouter') {
454
+ if (dossier === cwd || projets.includes(dossier)) return `${dossier} est déjà au tableau.`
455
+ const pkg = `${dossier}/package.json`
456
+ const texte = (await $.fs.exists(pkg)) ? String(await $.fs.read(pkg)) : null
457
+ if (!declareLePaquet(texte)) {
458
+ return `Refusé : ${dossier} n'est pas un projet Grillhouse (son package.json ne déclare pas ${PAQUET}).`
459
+ }
460
+ liste = [...projets, dossier]
461
+ } else {
462
+ if (!projets.includes(dossier)) return `${dossier} n'est pas au tableau.`
463
+ liste = projets.filter(p => p !== dossier)
464
+ }
465
+ await $.store.set(cleProjets(cwd), liste)
466
+ await update($, etat, s => ({ ...s, projets: liste }))
467
+ void rafraichir($)
468
+ return geste === 'ajouter' ? `Projet ajouté au tableau : ${dossier}.` : `Projet retiré du tableau : ${dossier}.`
469
+ }
470
+
311
471
  // The board applies to a Grillhouse project outside an agent's copy (`eligible`), once someone can
312
472
  // see it: a person at the terminal's prompt from the start (`isInteractive`), or a surface that
313
473
  // attaches later — the desktop app's Code tab, whose session starts headless, as the SDK's does,
@@ -320,6 +480,7 @@ async function activer($: EngineInterface) {
320
480
  await $.command.register({
321
481
  name: 'grillhouse',
322
482
  description: 'Ouvre le tableau Grillhouse : le projet, les agents, le chantier en cours',
483
+ argumentHint: '[ajouter|retirer <chemin>]',
323
484
  })
324
485
  void rafraichir($)
325
486
  $.clock.every(PERIODE, () => void rafraichir($))
@@ -340,6 +501,10 @@ export const register: Register = on => {
340
501
  const texte = (await $.fs.exists(pkg)) ? String(await $.fs.read(pkg)) : null
341
502
  projet = declareLePaquet(texte)
342
503
  eligible = projet && !cwd.includes('/.claude/worktrees/')
504
+ if (eligible) {
505
+ const garde = await lireLaListe($)
506
+ if (garde.length) await update($, etat, s => ({ ...s, projets: garde }))
507
+ }
343
508
  if (e.isInteractive) await activer($)
344
509
  return started
345
510
  })
@@ -352,7 +517,11 @@ export const register: Register = on => {
352
517
 
353
518
  // The command answers at once and the board is measured behind it: a measure takes seconds on a
354
519
  // large project, and a hook past its budget (10 s) is skipped, its command answered by the engine.
520
+ // `ajouter <chemin>` and `retirer <chemin>` change the projects the pane shows.
355
521
  on('command.run', { command: 'grillhouse' }, async ($, e) => {
522
+ const [geste = '', ...reste] = (e.args ?? '').trim().split(/\s+/)
523
+ if (geste === 'ajouter' || geste === 'retirer') return { text: await changerLaListe($, geste, reste.join(' ')) }
524
+ if (geste) return { text: 'Usage : /grillhouse, /grillhouse ajouter <chemin>, /grillhouse retirer <chemin>.' }
356
525
  void rafraichir($)
357
526
  // A narrow column docked beside the transcript; a short block when seated above the prompt.
358
527
  await $.ui.open({ id: PANE, title: 'Grillhouse', columns: COLONNES, rows: 12 })
@@ -407,7 +576,9 @@ export const register: Register = on => {
407
576
  // Focused, the card shows the chosen ticket; otherwise the one that moved last.
408
577
  const montre = e.props.isFocused ? choisi : (t.dernier ?? choisi)
409
578
  const fiche = montre ? t.fiches[montre] : undefined
410
- const rangs = Math.max(1, e.props.scroll.bodyRows - FICHE - 1)
579
+ // A fused board's footer stands between the list and the rule.
580
+ const pied = t.pied ?? []
581
+ const rangs = Math.max(1, e.props.scroll.bodyRows - FICHE - 1 - pied.length)
411
582
  cadre = { rangs, focus: e.props.isFocused }
412
583
  const liste = placer(s, rangs, e.props.isFocused)
413
584
  const ici = liste.findIndex(x => x.cle === element)
@@ -453,7 +624,7 @@ export const register: Register = on => {
453
624
  plain
454
625
  hotkey="g"
455
626
  onPress={() => {
456
- if (!grand && montre) void lireTexte($, montre)
627
+ if (!grand && montre) void lireTexte($, montre, dossierDu(t, montre))
457
628
  ligneTexte = 0
458
629
  void update($, etat, s => ({ ...s, grand: !s.grand }))
459
630
  }}
@@ -462,7 +633,12 @@ export const register: Register = on => {
462
633
  </Button>
463
634
  ) : null}
464
635
  {chantier && fiche ? (
465
- <Button key="h" plain hotkey="h" onPress={() => void basculer($, chantier, t.fiches[chantier]?.statut)}>
636
+ <Button
637
+ key="h"
638
+ plain
639
+ hotkey="h"
640
+ onPress={() => void basculer($, chantier, t.fiches[chantier]?.statut, dossierDu(t, chantier))}
641
+ >
466
642
  <Text dimColor>{`· h : ${fiche.statut === 'in_progress' ? 'désactiver' : 'activer'} `}</Text>
467
643
  </Button>
468
644
  ) : null}
@@ -565,6 +741,11 @@ export const register: Register = on => {
565
741
  )
566
742
  })}
567
743
  </Box>
744
+ {pied.map((l, i) => (
745
+ <Text key={`pied:${i}`} dimColor={l.ton === 'discret'} color={couleur(l.ton)} wrap="truncate-end">
746
+ {l.texte}
747
+ </Text>
748
+ ))}
568
749
  {regle('tout le texte')}
569
750
  <Box flexDirection="column" height={FICHE} flexShrink={0}>
570
751
  {carte(fiche)}
package/package.json CHANGED
@@ -1,7 +1,17 @@
1
1
  {
2
2
  "name": "@roomi-fields/grillhouse",
3
- "version": "0.28.0",
3
+ "version": "0.28.1",
4
4
  "description": "Roomi's Grillhouse: the frame's scripts, called by one command, grillhouse <sous-commande>",
5
+ "keywords": [
6
+ "claude-code",
7
+ "elephant-goldfish-model",
8
+ "spec-driven-development",
9
+ "ai-agents",
10
+ "multi-agent",
11
+ "agentic-coding",
12
+ "code-review",
13
+ "tdd"
14
+ ],
5
15
  "license": "MIT",
6
16
  "type": "module",
7
17
  "repository": {
@@ -90,6 +90,15 @@
90
90
  // passes (`plan`, its fingerprint: its title and its criteria); a plan that passed, its title
91
91
  // and criteria unchanged since, passes with no session, whatever else of its description
92
92
  // changed.
93
+ // - The sheet of the plan names what a component publishes to another (`noms_publies`: the
94
+ // provider, each consumer, its names), which the circuit writes in the description (« ## Noms
95
+ // publiés », after the sort), written again at each plan from the explorateur's last sheet (an
96
+ // empty list erases it, a sheet without the field keeps the section the description holds), as
97
+ // a code owner's approval covers what it reviewed: the guard of the consumers
98
+ // (scripts/langages/typescript/consommateurs-arbitres.mjs) reads that section, and a lot that
99
+ // adds those names to the provider's « Consommateurs » lines passes it with no arbitrage
100
+ // (grillhouse-la3, BPScript 320.14.2.10: a criterion alone named them, the guard refused the
101
+ // lot, and the supervisor wrote the section by hand before a new session).
93
102
  // - The sheet of the plan says the sort of the ticket (`sorte`, read by `sorteDuPlan` of
94
103
  // scripts/resultats.mjs, from the explorateur's last sheet of the plan), which the circuit
95
104
  // writes in the description (« ## Sorte », after the criteria) and at the ticket with the plan:
@@ -323,11 +332,15 @@
323
332
  // final pass, as `--update-snapshots` leaves every failure but the snapshots to its owner; its
324
333
  // finding without a file, or on a file the reference covers, stays the regeneration's (BPScript
325
334
  // 320.10: a word of library written in 030-binder, sent to no developpeur). Checks of the
326
- // plan green but for reds of references call for it too, before the final pass, as make
327
- // remakes a generated file before what reads it: the final pass that is due then plays once, on
328
- // the regenerated tree, and does not regenerate again a reference regenerated on that same tree
329
- // (BPScript 320.3.9: the ceiling of the words, red at the checks, left to the final pass, which
330
- // played the same tests again on the same tree for 6.1 min before regenerating). The circuit
335
+ // plan with a red of a reference, mixed with other reds or not, call for it too, before any red
336
+ // goes to the developpeur, as Bazel builds a genrule before the tests that read it: beside
337
+ // other reds, the checks of the plan play again on the regenerated tree, which judges a test
338
+ // that reads the reference (BPScript 320.6.5: a test that reads the hash the turbo.json declare,
339
+ // red beside their guard, went to a developpeur who had nothing to deliver, then could not write
340
+ // them); alone, the final pass that is due plays once, on the regenerated tree. Neither
341
+ // regenerates again a reference regenerated on that same tree (BPScript 320.3.9: the ceiling of
342
+ // the words, red at the checks, left to the final pass, which played the same tests again on
343
+ // the same tree for 6.1 min before regenerating). The circuit
331
344
  // keeps the copy as a lot, runs the command of each reference concerned on the whole copy (the
332
345
  // debt lowered from the notes of the pass, its guards not played again), out of the envelope,
333
346
  // under the lock of the machine, its output added to the log, then, as make remakes the targets
@@ -348,9 +361,9 @@
348
361
  // the regeneration, a question for the supervisor that carries each deviation (the command and
349
362
  // its code, the file), as the comment at the ticket does; the state keeps the references to regenerate and the reds of the
350
363
  // pass before (`aRegenerer`), for a regeneration resumed. A command of the project that refuses
351
- // (no real failure), its only deviation, after a final pass that carries reds of the plan,
364
+ // (no real failure), its only deviation, after a pass (the checks of the plan or the final pass) that carries reds of the plan,
352
365
  // judges the lot, as a ceiling refuses a lot beyond it: the copy restored, those reds go to the
353
- // developpeur with the end of its output, within his sessions, then the final pass again.
366
+ // developpeur with the end of its output, within his sessions, then that pass again.
354
367
  // - The proof, the checks and the final pass are heavy passes: each holds the lock of the machine
355
368
  // (scripts/verrou-de-machine.mjs), shared by every repository of the machine, and waits, the
356
369
  // wait written to the log, while another measure holds it; the wait bounded, the pass is at 75,
@@ -1969,18 +1982,19 @@ function referencesDesRouges(ctx, lieux, aElaguer = false) {
1969
1982
  // another one has just written runs after it, once for each reference whose writing calls for it;
1970
1983
  // then the copy kept again on that lot. `{ texte, regenerees, fichiers, restreinte }`: the report,
1971
1984
  // the names of the references changed, the files changed, and the range of the final pass that
1972
- // follows (null when nothing changed: no pass plays again, and the reds stand); with
1973
- // <avantLaPasse>, the regeneration the checks of the plan call for, the final pass that is due
1974
- // follows, whole or since the last review. A file a reference writes follows from the lot, as
1985
+ // follows (null when nothing changed: no pass plays again, and the reds stand); <suite>, the
1986
+ // regeneration the checks of the plan call for: `controles`, beside other reds, the checks of the
1987
+ // plan follow, on the regenerated tree; `passe`, without, the final pass that is due follows,
1988
+ // whole or since the last review; null after a final pass. A file a reference writes follows from the lot, as
1975
1989
  // the output of a genrule, without a word of the plan, and the reviewer reads its difference; a
1976
1990
  // file changed that none of the references run declares, or a command that fails (a reference of
1977
1991
  // the project at another code than 0, one of the frame on a real failure alone) restores the copy
1978
1992
  // as it was and stops at « references », each deviation in its question. With <refusAuLot>, the
1979
- // final pass that called for it carries reds of the plan: a command of the project that refuses
1993
+ // pass that called for it (the checks of the plan or the final pass) carries reds of the plan: a command of the project that refuses
1980
1994
  // (another code than 0, no real failure), its only deviation, judges the lot, as a ceiling that
1981
1995
  // never rises refuses a lot beyond it; the copy restored, `{ refus }` gives the report of each
1982
1996
  // refusal with the end of its output, for the developpeur (BPScript 320.10).
1983
- function regenerer(ctx, noms, notes = [], avantLaPasse = false, refusAuLot = false) {
1997
+ function regenerer(ctx, noms, notes = [], suite = null, refusAuLot = false) {
1984
1998
  // The notes of the debt, in a file of the run, which the command that lowers it reads.
1985
1999
  const fichierDesNotes = path.join(ctx.base.dossier, 'dette-a-abaisser.json');
1986
2000
  const toutes = lesReferences(ctx).map(r =>
@@ -2063,7 +2077,13 @@ function regenerer(ctx, noms, notes = [], avantLaPasse = false, refusAuLot = fal
2063
2077
  }
2064
2078
  if (!fichiers.length) {
2065
2079
  return {
2066
- texte: `La régénération (${refs.map(r => `${r.nom}, \`${r.commande}\``).join(' ; ')}) ne change aucun fichier : ${avantLaPasse ? 'la passe finale juge le lot tel quel' : 'aucune passe ne rejoue, et les rouges de la passe finale restent, chacun à son propriétaire'}.`,
2080
+ texte: `La régénération (${refs.map(r => `${r.nom}, \`${r.commande}\``).join(' ; ')}) ne change aucun fichier : ${
2081
+ suite === 'passe'
2082
+ ? 'la passe finale juge le lot tel quel'
2083
+ : suite === 'controles'
2084
+ ? 'les contrôles ne rejouent pas, et leurs rouges restent, chacun à son propriétaire'
2085
+ : 'aucune passe ne rejoue, et les rouges de la passe finale restent, chacun à son propriétaire'
2086
+ }.`,
2067
2087
  regenerees: [],
2068
2088
  fichiers,
2069
2089
  restreinte: null,
@@ -2071,7 +2091,13 @@ function regenerer(ctx, noms, notes = [], avantLaPasse = false, refusAuLot = fal
2071
2091
  }
2072
2092
  return {
2073
2093
  texte: [
2074
- `Les références régénérées sur la copie entière : ${regenerees.map(r => r.nom).join(', ')} ; le lot porte leurs fichiers, puis la passe finale${avantLaPasse ? '' : " restreinte à ce qu'elles changent"}.`,
2094
+ `Les références régénérées sur la copie entière : ${regenerees.map(r => r.nom).join(', ')} ; le lot porte leurs fichiers, puis ${
2095
+ suite === 'controles'
2096
+ ? "les contrôles du plan, sur l'arbre régénéré"
2097
+ : suite === 'passe'
2098
+ ? 'la passe finale'
2099
+ : "la passe finale restreinte à ce qu'elles changent"
2100
+ }.`,
2075
2101
  '',
2076
2102
  ...regenerees.map(r => `- ${r.nom} (\`${r.commande}\`) : ${siens(r).join(', ')}`),
2077
2103
  '',
@@ -2301,25 +2327,26 @@ export function arretDuTestwriterSaute(ctx, texte) {
2301
2327
  );
2302
2328
  }
2303
2329
 
2304
- // The sheet of the plan that says the sort among the explorateur's sheets of the plan <plans>, in
2305
- // their order (`{ fiche, reponse }` entries): the last one, or, when it is his answer to the
2306
- // questionneur (`reponse`) and says none, the plan it answers, so that the sort survives the
2307
- // answer; null without a sheet of the plan.
2308
- export function ficheDeLaSorte(plans) {
2330
+ // The sheet of the plan that says its field <champ> (`sorte`, `noms_publies`) among the
2331
+ // explorateur's sheets of the plan <plans>, in their order (`{ fiche, reponse }` entries): the last
2332
+ // one, or, when it is his answer to the questionneur (`reponse`) and says none, the plan it
2333
+ // answers, so that the field survives the answer; null without a sheet of the plan.
2334
+ export function ficheDuPlan(plans, champ) {
2309
2335
  const derniere = plans.at(-1);
2310
2336
  if (!derniere) return null;
2311
- if (derniere.reponse && !('sorte' in derniere.fiche) && plans.length > 1) {
2337
+ if (derniere.reponse && !(champ in derniere.fiche) && plans.length > 1) {
2312
2338
  return plans.at(-2).fiche;
2313
2339
  }
2314
2340
  return derniere.fiche;
2315
2341
  }
2316
2342
 
2317
2343
  // The sort of the ticket its plan says (`sorteDuPlan` of scripts/resultats.mjs): the sheet of the
2318
- // plan that says it (`ficheDeLaSorte`), comportement without one (grillhouse-sos).
2344
+ // plan that says it (`ficheDuPlan`), comportement without one (grillhouse-sos).
2319
2345
  const sorteDuTicket = ctx =>
2320
2346
  sorteDuPlan(
2321
- ficheDeLaSorte(
2322
- lesFiches(ctx).filter(e => e.role === EXPLORATEUR && Array.isArray(e.fiche?.criteres))
2347
+ ficheDuPlan(
2348
+ lesFiches(ctx).filter(e => e.role === EXPLORATEUR && Array.isArray(e.fiche?.criteres)),
2349
+ 'sorte'
2323
2350
  )
2324
2351
  );
2325
2352
 
@@ -3196,10 +3223,10 @@ const ligneDeCommande = c =>
3196
3223
  // verifier`, what the integration plays (4.1), restricted by <restreinte> (`{ avant, apres }`, two
3197
3224
  // lots kept) to the packages that changed from one to the other and their dependents, with the
3198
3225
  // root's tasks, the guards (`--filter=...[<avant>...<apres>] --filter=//`). After a regeneration,
3199
- // <reportes> (`{ rouges, rejouee }`) carries the reds of the final pass before it: each one in a
3200
- // package the pass restricted to the regeneration does not play again stands, as a CI keeps the
3201
- // verdict of a job it does not run again; when the regeneration changes nothing (`rejouee`
3202
- // false), no command plays, and they all stand. `{ rouge, aRepasser, arbitrer, auDeveloppeur,
3226
+ // <reportes> (`{ rouges, rejouee }`) carries the reds of the pass before it, the final pass or the
3227
+ // checks of the plan: each one in a package the pass after the regeneration does not play again
3228
+ // stands, as a CI keeps the verdict of a job it does not run again; when the regeneration changes
3229
+ // nothing (`rejouee` false), no command plays, and they all stand. `{ rouge, aRepasser, arbitrer, auDeveloppeur,
3203
3230
  // texte, complet, resume, horsTitre, lieux, tous, notes, avertissements }`: `texte` the report for
3204
3231
  // the developpeur, his reds first; `complet` every red, for a stop, and the warnings;
3205
3232
  // `avertissements` the section of the warnings and notes of the guards, which are no reds, for the
@@ -3208,7 +3235,7 @@ const ligneDeCommande = c =>
3208
3235
  // when every red of the plan is a finding to settle; `lieux` the place of each red, `{ fichier,
3209
3236
  // gardes, dansLePlan }`, its file (null for a red without one), the names its finding carries
3210
3237
  // (none for a test or a task), and whether a path of the plan holds it; `references`, out of the final pass, the references whose reds the checks saw,
3211
- // which their regeneration lifts before the final pass; `tous` every red as it was read; `notes`,
3238
+ // which their regeneration lifts before the checks judge the lot again, or before the final pass; `tous` every red as it was read; `notes`,
3212
3239
  // at the final pass, each key of the debt a guard wrote inscribed above what it finds, `{ garde,
3213
3240
  // fichier, regle, trouve }`.
3214
3241
  function controles(ctx, finale, restreinte = null, reportes = null) {
@@ -3248,7 +3275,7 @@ function controles(ctx, finale, restreinte = null, reportes = null) {
3248
3275
  ),
3249
3276
  ];
3250
3277
  // Out of the final pass, the reds of the plan are the developpeur's; a red of a reference goes to
3251
- // its regeneration (4.2), before the final pass; the others (the root, a red no file situates, a
3278
+ // its regeneration (4.2), before any red goes to him; the others (the root, a red no file situates, a
3252
3279
  // package out of the plan) wait for the final pass.
3253
3280
  const lieu = r => ({
3254
3281
  fichier: r.fichier ?? null,
@@ -3271,18 +3298,14 @@ function controles(ctx, finale, restreinte = null, reportes = null) {
3271
3298
  ? `rouge : ${rouges.length} rouge(s) — ${
3272
3299
  commandes.length
3273
3300
  ? enEchec.map(nommer).join(' ; ')
3274
- : "ceux de la passe finale d'avant, que la régénération ne change pas"
3301
+ : `ceux ${finale ? "de la passe finale d'avant" : "des contrôles d'avant"}, que la régénération ne change pas`
3275
3302
  }`
3276
3303
  : aRepasser.length
3277
3304
  ? `à repasser : ${aRepasser.map(nommer).join(' ; ')}`
3278
- : `verts : ${commandes.length ? resultats.map(ligneDeCommande).join(' ; ') : "la passe finale d'avant"}${
3305
+ : `verts : ${commandes.length ? resultats.map(ligneDeCommande).join(' ; ') : finale ? "la passe finale d'avant" : "les contrôles d'avant"}${
3279
3306
  laisses.length
3280
3307
  ? ` ; laissés à la passe finale, ${laisses.length} rouge(s) hors du plan`
3281
3308
  : ''
3282
- }${
3283
- references.length
3284
- ? ` ; des rouges sont ceux de références, à leur régénération avant la passe finale (${references.map(r => r.nom).join(', ')})`
3285
- : ''
3286
3309
  }`;
3287
3310
  // Where the checks played: the final pass out of the envelope, on the whole copy or restricted
3288
3311
  // to what changed since the last review; the checks of the plan, its tests and packages, its
@@ -3716,8 +3739,9 @@ async function derouler(ctx, debut) {
3716
3739
  const passeFinale = finale;
3717
3740
  // The final pass: after a regeneration of the references, restricted to what it changed,
3718
3741
  // the reds of the pass before it carried (none plays when it changed nothing); else whole,
3719
- // or restricted to what changed since the last review.
3720
- const regeneration = passeFinale ? (ctx.regeneration ?? null) : null;
3742
+ // or restricted to what changed since the last review. The checks of the plan after a
3743
+ // regeneration that changed nothing: none plays, the reds of the checks before standing.
3744
+ const regeneration = ctx.regeneration ?? null;
3721
3745
  ctx.regeneration = null;
3722
3746
  const passe = !passeFinale
3723
3747
  ? { arbre: null, restreinte: null }
@@ -3762,7 +3786,53 @@ async function derouler(ctx, debut) {
3762
3786
  r => !dejaRegenerees.includes(r.nom)
3763
3787
  )
3764
3788
  : [];
3765
- if (aRegenerer.length) {
3789
+ // The checks of the plan with a red of a reference, mixed with others or not: its
3790
+ // regeneration before any red goes to the developpeur, as Bazel builds a genrule before the
3791
+ // tests that read it, but for a reference regenerated on this same tree; mixed with other
3792
+ // reds, the checks of the plan play again on the regenerated tree, which judges a test
3793
+ // that reads the reference; alone, the final pass that is due (BPScript 320.6.5: a test
3794
+ // that reads the turbo.json, red beside their guard, sent to the developpeur, who could not
3795
+ // write them).
3796
+ const regenereesAuxControles =
3797
+ !passeFinale && k.references.length && ctx.regenereSur?.arbre === arbreDeLaCopie(ctx)
3798
+ ? ctx.regenereSur.noms
3799
+ : [];
3800
+ const avantLesControles = passeFinale
3801
+ ? []
3802
+ : k.references.filter(r => !regenereesAuxControles.includes(r.nom));
3803
+ if (avantLesControles.length) {
3804
+ const noms = avantLesControles.map(r => r.nom);
3805
+ const meles = k.rouge || k.aRepasser;
3806
+ geste(ctx, 'regeneration');
3807
+ const phrase = `${k.resume} ; des rouges sont ceux de références (${noms.join(', ')}) : à leur régénération, puis ${meles ? 'les contrôles du plan' : 'la passe finale'}.`;
3808
+ ecrireRapport(
3809
+ ctx,
3810
+ 'controles',
3811
+ phrase,
3812
+ resultat(meles ? 'rouge' : 'vert'),
3813
+ meles ? `${k.texte}${k.avertissements}` : `${phrase}${k.avertissements}`
3814
+ );
3815
+ // Mixed, the developpeur who had nothing to deliver, for the checks of the plan that
3816
+ // follow; green, the final pass, its sessions counted apart, which a developpeur with
3817
+ // nothing to deliver before green checks does not concern.
3818
+ if (meles) {
3819
+ ctx.rienALivrer = rien;
3820
+ } else {
3821
+ ctx.renvoiAuTestwriter = null;
3822
+ tentative = 0;
3823
+ }
3824
+ // The report of the reds of the plan, which go to the developpeur when a command of the
3825
+ // project refuses the lot, as at the final pass (BPScript 320.10).
3826
+ ctx.aRegenerer = {
3827
+ noms,
3828
+ notes: [],
3829
+ suite: meles ? 'controles' : 'passe',
3830
+ rouges: meles ? k.tous : [],
3831
+ auDeveloppeur: meles && k.auDeveloppeur && !k.arbitrer ? k.texte : null,
3832
+ };
3833
+ etape = REFERENCES;
3834
+ finale = true;
3835
+ } else if (aRegenerer.length) {
3766
3836
  const noms = aRegenerer.map(r => r.nom);
3767
3837
  geste(ctx, 'regeneration');
3768
3838
  ecrireRapport(
@@ -3821,27 +3891,6 @@ async function derouler(ctx, debut) {
3821
3891
  arreter('controles', null);
3822
3892
  } else if (k.aRepasser) {
3823
3893
  arreter('a-repasser', null);
3824
- } else if (!passeFinale && k.references.length) {
3825
- // The checks green but for reds of references: their regeneration, then the final pass,
3826
- // which plays once, on the regenerated tree, as make remakes a generated file before
3827
- // what reads it.
3828
- geste(ctx, 'regeneration');
3829
- ecrireRapport(
3830
- ctx,
3831
- 'controles',
3832
- `${k.resume}.`,
3833
- resultat('vert'),
3834
- `${k.resume}.${k.avertissements}`
3835
- );
3836
- ctx.renvoiAuTestwriter = null;
3837
- ctx.aRegenerer = {
3838
- noms: k.references.map(r => r.nom),
3839
- notes: [],
3840
- avantLaPasse: true,
3841
- };
3842
- etape = REFERENCES;
3843
- tentative = 0;
3844
- finale = true;
3845
3894
  } else {
3846
3895
  ecrireRapport(
3847
3896
  ctx,
@@ -3873,7 +3922,8 @@ async function derouler(ctx, debut) {
3873
3922
  }
3874
3923
  } else if (etape === REFERENCES) {
3875
3924
  // The references to regenerate and the reds of the pass before, kept in the state from
3876
- // the final pass that called for them, so that a regeneration resumed knows them.
3925
+ // the pass that called for them (the checks of the plan, `suite`, or the final pass), so
3926
+ // that a regeneration resumed knows them.
3877
3927
  const a = ctx.aRegenerer;
3878
3928
  if (!a) {
3879
3929
  throw new Arret(
@@ -3882,10 +3932,11 @@ async function derouler(ctx, debut) {
3882
3932
  );
3883
3933
  }
3884
3934
  // A command of the project that refuses beside reds of the plan, within the developpeur's
3885
- // sessions: the copy restored, those reds go to him with its output, the final pass after.
3935
+ // sessions: the copy restored, those reds go to him with its output, then the pass that
3936
+ // called for the regeneration, the checks of the plan or the final pass.
3886
3937
  const suivante = tentative + 1;
3887
3938
  const auLot = Boolean(a.auDeveloppeur) && suivante <= SEANCES_DEVELOPPEUR;
3888
- const g = regenerer(ctx, a.noms, a.notes, Boolean(a.avantLaPasse), auLot);
3939
+ const g = regenerer(ctx, a.noms, a.notes, a.suite ?? null, auLot);
3889
3940
  if (g.refus) {
3890
3941
  const texte = [
3891
3942
  `La régénération des références refuse le lot ; la copie est rendue telle qu'avant elle, et les rouges du plan vont au développeur (séance ${suivante}).`,
@@ -3895,29 +3946,37 @@ async function derouler(ctx, debut) {
3895
3946
  ecrireRapport(ctx, 'references', texte, { regenerees: [], fichiers: [] });
3896
3947
  rapport = `${texte}\n\n${a.auDeveloppeur}`;
3897
3948
  ctx.aRegenerer = null;
3949
+ ctx.rienALivrer = null;
3898
3950
  etape = CODE;
3899
3951
  tentative = suivante;
3900
- finale = true;
3952
+ finale = a.suite !== 'controles';
3901
3953
  continue;
3902
3954
  }
3903
3955
  ecrireRapport(ctx, 'references', g.texte, {
3904
3956
  regenerees: g.regenerees,
3905
3957
  fichiers: g.fichiers,
3906
3958
  });
3907
- // After the checks, the final pass that is due, on the regenerated tree, which does not
3908
- // regenerate again the references just regenerated on it; after a final pass, the pass
3909
- // restricted to what the regeneration changed, with the reds of the pass before.
3910
- ctx.regenereSur = a.avantLaPasse ? { arbre: arbreDeLaCopie(ctx), noms: a.noms } : null;
3911
- ctx.regeneration = a.avantLaPasse
3912
- ? null
3913
- : {
3914
- restreinte: g.restreinte,
3915
- entiere: a.entiere,
3916
- reportes: { rouges: a.rouges, rejouee: g.fichiers.length > 0 },
3917
- };
3959
+ // After the checks, the pass that judges the regenerated tree, which does not regenerate
3960
+ // again the references just regenerated on it: beside other reds, the checks of the plan
3961
+ // again (none plays when the regeneration changed nothing, the reds of the checks before
3962
+ // standing); without, the final pass that is due. After a final pass, the pass restricted
3963
+ // to what the regeneration changed, with the reds of the pass before.
3964
+ ctx.regenereSur = a.suite ? { arbre: arbreDeLaCopie(ctx), noms: a.noms } : null;
3965
+ ctx.regeneration =
3966
+ a.suite === 'passe'
3967
+ ? null
3968
+ : a.suite === 'controles'
3969
+ ? g.fichiers.length
3970
+ ? null
3971
+ : { reportes: { rouges: a.rouges, rejouee: false } }
3972
+ : {
3973
+ restreinte: g.restreinte,
3974
+ entiere: a.entiere,
3975
+ reportes: { rouges: a.rouges, rejouee: g.fichiers.length > 0 },
3976
+ };
3918
3977
  ctx.aRegenerer = null;
3919
3978
  etape = CONTROLES;
3920
- finale = true;
3979
+ finale = a.suite !== 'controles';
3921
3980
  } else if (etape === RELECTURE) {
3922
3981
  const v = await relire(ctx);
3923
3982
  // A question for the owner: nothing is committed nor relaunched before his answer.
@@ -4254,6 +4313,19 @@ const planPasse = (ctx, empreinte) =>
4254
4313
  const QUESTIONS_OUVERTES = '## Questions ouvertes';
4255
4314
  // The heading of the section of the sort of the ticket in a plan's description (grillhouse-sos).
4256
4315
  const SORTE = '## Sorte';
4316
+ // The heading of the section of the names the plan publishes in its description, the one that
4317
+ // scripts/langages/typescript/consommateurs-arbitres.mjs reads (grillhouse-la3).
4318
+ const NOMS_PUBLIES = '## Noms publiés';
4319
+
4320
+ // The names <noms> a plan publishes (`noms_publies`), one line each, as the guard of the consumers
4321
+ // reads them: the provider, the consumer and each name between backquotes.
4322
+ const lignesDesNoms = noms =>
4323
+ noms
4324
+ .map(
4325
+ n =>
4326
+ `- \`${n.fournisseur}\` publie à \`${n.consommateur}\` : ${n.noms.map(x => `\`${x}\``).join(', ')}`
4327
+ )
4328
+ .join('\n');
4257
4329
 
4258
4330
  // The sort <sorte> (`sorteDuPlan`) in words: its kind, then its reason.
4259
4331
  const texteDeLaSorte = sorte =>
@@ -4286,14 +4358,19 @@ function numerotee(ligne) {
4286
4358
  // The ticket's description <description> as it was before the plan, with the criteria the plan adds
4287
4359
  // <criteres> in its section of criteria (a section « ## Critères » at its end without one), the sort
4288
4360
  // of the ticket <sorte> in its section after it, its reason and the command of a mechanical ticket
4289
- // (absent when the sheet says none), and its open questions <questions> in their section after
4290
- // them, absent without one; the rest of it as it was. The criteria already written stay as they
4291
- // are, the decision of the owner: each criterion the plan adds follows them, numbered after them.
4292
- // Written again from the description before the plan, the description holds the criteria and the
4293
- // sort of the explorateur's last sheet alone.
4294
- export function decrireLePlan(description, criteres, questions, sorte = null) {
4361
+ // (absent when the sheet says none), the names the plan publishes <noms> in their section after it
4362
+ // (an empty list erases the section; a sheet without them, <noms> undefined, keeps the section the
4363
+ // description holds, a supervisor's by hand included), and its open questions <questions> in their
4364
+ // section after them, absent without one; the rest of it as it was. The criteria already written
4365
+ // stay as they are, the decision of the owner: each criterion the plan adds follows them, numbered
4366
+ // after them. Written again from the description before the plan, the description holds the
4367
+ // criteria, the sort and the names of the explorateur's last sheet alone.
4368
+ export function decrireLePlan(description, criteres, questions, sorte = null, noms = undefined) {
4295
4369
  const gardees = sectionsDe(description).filter(
4296
- s => s.tete !== QUESTIONS_OUVERTES && s.tete !== SORTE
4370
+ s =>
4371
+ s.tete !== QUESTIONS_OUVERTES &&
4372
+ s.tete !== SORTE &&
4373
+ (noms === undefined || s.tete !== NOMS_PUBLIES)
4297
4374
  );
4298
4375
  let i = gardees.findIndex(deCriteres);
4299
4376
  if (i < 0) {
@@ -4324,6 +4401,7 @@ export function decrireLePlan(description, criteres, questions, sorte = null) {
4324
4401
  },
4325
4402
  ]
4326
4403
  : []),
4404
+ ...(noms?.length ? [{ tete: NOMS_PUBLIES, lignes: ['', lignesDesNoms(noms), ''] }] : []),
4327
4405
  ...(questions.length
4328
4406
  ? [{ tete: QUESTIONS_OUVERTES, lignes: ['', lignesOuvertes(questions), ''] }]
4329
4407
  : []),
@@ -4464,7 +4542,13 @@ async function lePlan(ctx) {
4464
4542
  ecrireLePlan(
4465
4543
  ctx,
4466
4544
  plan.paquets.map(ctx.resoudre),
4467
- decrireLePlan(t.description, plan.criteres, plan.questions, sorteEcrite(plan))
4545
+ decrireLePlan(
4546
+ t.description,
4547
+ plan.criteres,
4548
+ plan.questions,
4549
+ sorteEcrite(plan),
4550
+ plan.noms_publies
4551
+ )
4468
4552
  );
4469
4553
  const ouvertesDuPlan = plan.questions.length ? `\n${lignesOuvertes(plan.questions)}` : 'aucune';
4470
4554
  dire(
@@ -4522,7 +4606,7 @@ async function lePlan(ctx) {
4522
4606
  {
4523
4607
  ...explorateur,
4524
4608
  premiere: 'reprend',
4525
- // The answer, apart from the plan it answers (`ficheDeLaSorte`).
4609
+ // The answer, apart from the plan it answers (`ficheDuPlan`).
4526
4610
  avec: { reponse: true },
4527
4611
  // A line of `reponses` by question put, asked again once; after it, a question without
4528
4612
  // its line stays open.
@@ -4545,6 +4629,7 @@ async function lePlan(ctx) {
4545
4629
  .map(question => ({ question, piece: 'question du questionneur, sans réponse' })),
4546
4630
  ];
4547
4631
  if (posees.length) {
4632
+ const plans = [{ fiche: premier }, { fiche: plan, reponse: true }];
4548
4633
  ecrireLePlan(
4549
4634
  ctx,
4550
4635
  plan.paquets.map(ctx.resoudre),
@@ -4552,7 +4637,8 @@ async function lePlan(ctx) {
4552
4637
  t.description,
4553
4638
  plan.criteres,
4554
4639
  ouvertes,
4555
- sorteEcrite(ficheDeLaSorte([{ fiche: premier }, { fiche: plan, reponse: true }]))
4640
+ sorteEcrite(ficheDuPlan(plans, 'sorte')),
4641
+ ficheDuPlan(plans, 'noms_publies').noms_publies
4556
4642
  )
4557
4643
  );
4558
4644
  }
@@ -208,10 +208,10 @@ export const GESTES = [
208
208
  {
209
209
  genre: 'regeneration',
210
210
  geste:
211
- 'à la régénération des références (4.2), puis la passe finale : celle qui est due, après les contrôles ; restreinte à ce qu’elle change, après une passe finale',
211
+ 'à la régénération des références (4.2), puis la passe qui juge l’arbre régénéré : après les contrôles, les contrôles du plan encore quand d’autres rouges s’y mêlent, sinon la passe finale qui est due ; après une passe finale, la passe finale restreinte à ce qu’elle change',
212
212
  regle:
213
- 'un rouge de la passe finale est celui d’une référence, même mêlé à d’autres, ou les contrôles du plan sont verts hors des rouges de références : une que le projet déclare (`grillhouse.references`), ou un fichier que le cadre engendre (l’index des interfaces, les fichiers que le module du langage engendre) ; ou la passe abaisse la dette des gardes (`dette.mjs --abaisser`, depuis ses notes)',
214
- cas: 'BP 320.9 : 292 min autour des références, dont 163 min d’attente pour régénérer à la main l’index des interfaces, le plafond et l’empreinte, des rouges de références mêlés à d’autres ; BP 320.3.9 : le plafond rouge aux contrôles, laissé à une passe finale qui rejoue les mêmes tests sur le même arbre (6,1 min)',
213
+ 'un rouge des contrôles du plan ou de la passe finale est celui d’une référence, même mêlé à d’autres : une que le projet déclare (`grillhouse.references`), ou un fichier que le cadre engendre (l’index des interfaces, les fichiers que le module du langage engendre) ; ou la passe abaisse la dette des gardes (`dette.mjs --abaisser`, depuis ses notes)',
214
+ cas: 'BP 320.9 : 292 min autour des références, dont 163 min d’attente pour régénérer à la main l’index des interfaces, le plafond et l’empreinte, des rouges de références mêlés à d’autres ; BP 320.3.9 : le plafond rouge aux contrôles, laissé à une passe finale qui rejoue les mêmes tests sur le même arbre (6,1 min) ; BP 320.6.5 : un test qui lit les références des paquets, rouge à côté de leur garde, envoyé au développeur, qui n’a rien à livrer puis ne peut pas les écrire',
215
215
  },
216
216
  {
217
217
  genre: 'rien-a-livrer',
@@ -76,6 +76,12 @@
76
76
  // - `ecartes` (`composant`, `raison`): the components of the survey the plan does not touch,
77
77
  // which the circuit writes at the ticket; each other component of the survey the circuit
78
78
  // plays is in the packages (explorateur);
79
+ // - `noms_publies` (`fournisseur`, `consommateur`, `noms`): the names a component publishes to
80
+ // another, which the lot adds to the provider's « Consommateurs » lines; as a code owner's
81
+ // approval covers what it reviewed, the circuit writes them in the description (« ## Noms
82
+ // publiés »), which scripts/langages/typescript/consommateurs-arbitres.mjs reads (BP
83
+ // 320.14.2.10: a criterion alone named them, the guard refused the lot) (grillhouse-la3)
84
+ // (explorateur);
79
85
  // - `reponses` (`numero` of the question, `reponse` CHANGE or GARDE, `texte`): the explorateur's
80
86
  // one answer to the questionneur, which the circuit writes at the ticket; a question without
81
87
  // an answer stays open (explorateur);
@@ -244,6 +250,22 @@ const FICHES = {
244
250
  ),
245
251
  'Les composants du relevé que le plan ne touche pas, chacun avec sa raison ; chaque autre composant du relevé est dans tes paquets.'
246
252
  ),
253
+ noms_publies: liste(
254
+ objet(
255
+ {
256
+ fournisseur: texte('Le composant qui publie, comme le titre le nomme.'),
257
+ consommateur: texte(
258
+ 'Le composant qui les lit, comme sa ligne « Consommateurs » de l’INTERFACE du fournisseur le nomme.'
259
+ ),
260
+ noms: liste(
261
+ texte('Un nom publié, tel que la ligne « Consommateurs » l’écrit.'),
262
+ 'Les noms que le lot ajoute à la ligne de ce consommateur.'
263
+ ),
264
+ },
265
+ ['fournisseur', 'consommateur', 'noms']
266
+ ),
267
+ 'Les noms qu’un composant publie à un autre et que le lot ajoute aux lignes « Consommateurs » de l’INTERFACE du fournisseur, un par consommateur ; le circuit les écrit dans « ## Noms publiés », que la garde des consommateurs lit. Une liste vide efface la section ; sans le champ, le circuit garde celle que la description porte.'
268
+ ),
247
269
  questions: liste(
248
270
  objet(
249
271
  {
@@ -1145,7 +1145,9 @@ const couperAvant = (gauche, suite, droite, largeur) => {
1145
1145
  // The board's lines, `largeur` columns wide, each with its tone (titre, alerte, attention, actif,
1146
1146
  // discret, or none), its section (`section`: agents, chantier or faits, in that order) and, for a
1147
1147
  // ticket's line, its id (`ticket`), which the pane makes selectable; an epic's line is marked
1148
- // `chantier`. The head belongs to agents, the first section; a blank line belongs to the section
1148
+ // `chantier`. A ticket's line in AGENTS names the step it stands under (`etape`: its `numero`,
1149
+ // null after the steps, and `titre`) and, stopped on a question, who must answer it (`question`):
1150
+ // the pane that fuses several projects' boards sorts their tickets by it. The head belongs to agents, the first section; a blank line belongs to the section
1149
1151
  // of the title after it. A chantier's « sans go » and « reporté » groups, its « à valider » group
1150
1152
  // past SEUIL_REPLI tickets, and the other chantiers beside one in progress fold to their title and
1151
1153
  // count: the folded title carries its group's key (`groupe`), and `groupes` receives, under that
@@ -1267,7 +1269,9 @@ export function lignes(t, nom, largeur = LARGEUR, groupes = {}) {
1267
1269
  ...[...(t.circuits ?? []), ...montres].map(x => String(x.numero).length)
1268
1270
  );
1269
1271
  const numero = n => String(n).padEnd(colonne);
1270
- const ligneDuCircuit = c => {
1272
+ // The step a ticket's line stands under, as data: its number (null after the steps) and title.
1273
+ const etapeDuBloc = b => ({ numero: b.numero, titre: b.titre });
1274
+ const ligneDuCircuit = (c, b, qui) => {
1271
1275
  const droite = conso(t.parTicket?.[c.id]?.travail ?? 0, t.parTicket?.[c.id]?.jetons ?? 0);
1272
1276
  const etape = etapeDe(c);
1273
1277
  const boucles = (etape ? bouclesDe(etape) : [])
@@ -1288,6 +1292,8 @@ export function lignes(t, nom, largeur = LARGEUR, groupes = {}) {
1288
1292
  texte: couperAvant(`${tete}${c.sujet}`, suite, droite, largeur),
1289
1293
  ton: temoin?.fige ? 'alerte' : c.vivant ? 'actif' : 'attention',
1290
1294
  ticket: c.id,
1295
+ etape: etapeDuBloc(b),
1296
+ ...(qui ? { question: qui } : {}),
1291
1297
  ...(temoin ? { avancement: true } : {}),
1292
1298
  });
1293
1299
  };
@@ -1316,14 +1322,15 @@ export function lignes(t, nom, largeur = LARGEUR, groupes = {}) {
1316
1322
  const tickets = (b, retrait) => {
1317
1323
  const { circuits, enQuestions, enCours, attend } = contenus.get(b);
1318
1324
  for (const c of circuits) {
1319
- ligneDuCircuit(c);
1325
+ ligneDuCircuit(c, b);
1320
1326
  }
1321
1327
  for (const x of enCours) {
1322
- L(
1323
- cadre(`▶ ${numero(x.numero)} ${x.sujet}`, conso(x.travail, x.jetons), largeur),
1324
- 'actif',
1325
- x.id
1326
- );
1328
+ poser({
1329
+ texte: cadre(`▶ ${numero(x.numero)} ${x.sujet}`, conso(x.travail, x.jetons), largeur),
1330
+ ton: 'actif',
1331
+ ticket: x.id,
1332
+ etape: etapeDuBloc(b),
1333
+ });
1327
1334
  }
1328
1335
  const attente = x => ({
1329
1336
  texte: cadre(
@@ -1333,12 +1340,13 @@ export function lignes(t, nom, largeur = LARGEUR, groupes = {}) {
1333
1340
  ),
1334
1341
  ton: 'discret',
1335
1342
  ticket: x.id,
1343
+ etape: etapeDuBloc(b),
1336
1344
  });
1337
1345
  poser(...attend.map(attente));
1338
1346
  for (const [qui, l] of enQuestions) {
1339
1347
  L(cadre(`${retrait}⤷ Question · ${qui}`, '', largeur), 'titre');
1340
1348
  for (const c of l) {
1341
- ligneDuCircuit(c);
1349
+ ligneDuCircuit(c, b, qui);
1342
1350
  }
1343
1351
  }
1344
1352
  };
@@ -1668,7 +1676,8 @@ const bdJson = (racine, ...args) => {
1668
1676
  }
1669
1677
  };
1670
1678
 
1671
- // The board of the repository at <racine>.
1679
+ // The board of the repository at <racine>, with its ticket prefix (`prefixe`), which labels its
1680
+ // lines in a pane that fuses several projects.
1672
1681
  export function tableau(racine, { home = os.homedir(), maintenant = Date.now() } = {}) {
1673
1682
  let prefix = '';
1674
1683
  try {
@@ -1773,6 +1782,7 @@ export function tableau(racine, { home = os.homedir(), maintenant = Date.now() }
1773
1782
  }
1774
1783
  return {
1775
1784
  ...t,
1785
+ prefixe: prefix,
1776
1786
  lignes: l,
1777
1787
  vueEtats: vue,
1778
1788
  groupes,
@@ -145,6 +145,9 @@ son adresse) : le circuit la consigne fermée sous ton ticket, et tu continues.
145
145
  projet déclare, un plafond par exemple. Leur rouge n'est pas le tien : ta séance ne s'arrête pas sur elles,
146
146
  et ta fiche finit FAIT sur ta part. Exemple : en 320.8 de BPScript, un développeur aux tests
147
147
  verts s'est arrêté sur le plafond des mots, la dette et l'index, que 4.2 a régénérés ensuite.
148
+ Le circuit les régénère avant de te rendre tes rouges : un test qui les lit, sous « Tes rouges »,
149
+ a déjà été jugé sur elles régénérées. Exemple : en 320.6.5 de BPScript, un test qui lisait les
150
+ `turbo.json` périmés est allé au développeur, qui ne pouvait pas les écrire.
148
151
  Un constat de leur garde sur ton code reste le tien, sous « Tes rouges », comme le refus de leur
149
152
  commande qu'il cause : un plafond ne monte jamais. Exemple : en 320.10 de BPScript, le mot
150
153
  « door » écrit dans 030-binder dépassait le plafond des mots. Ainsi le geste mécanique reste au
@@ -84,6 +84,14 @@ change, et ceux qu'il peut casser.
84
84
  rien à changer, par exemple) ; le circuit l'écrit au ticket. Le circuit rejoue le relevé sur
85
85
  mon plan : un composant qui n'est ni dans `paquets` ni dans `ecartes` rend ma fiche non
86
86
  conforme ;
87
+ - `noms_publies` : quand le lot ajoute un nom à une ligne « Consommateurs » de l'INTERFACE d'un
88
+ fournisseur (un composant publie un nom neuf à un autre, ou un consommateur lit un nom de
89
+ plus), une entrée par consommateur : le `fournisseur`, le `consommateur` comme sa ligne le
90
+ nomme, et ses `noms` tels que la ligne les écrit. Le circuit les écrit dans
91
+ « ## Noms publiés » de la description, réécrite à chaque plan, et la garde des consommateurs
92
+ laisse entrer ces lignes sans arbitrage ; un nom qu'un critère seul nomme reste refusé. Je
93
+ reprends ceux que la section porte déjà. Une liste vide efface la section ; sans le champ,
94
+ le circuit garde la section que la description porte ;
87
95
  - `questions` : seulement ce que je ne sais pas trancher, ou ce qui revient au responsable. Ce
88
96
  que je sais trancher et recommande, je l'applique au plan (écarter un paquet qui n'a rien à
89
97
  changer, par exemple) et je le dis dans ma fiche. Chaque question : chacune avec ses options, ma recommandation et sa
@@ -99,7 +107,8 @@ change, et ceux qu'il peut casser.
99
107
  3. **La réponse.** Le circuit reprend ma séance avec les questions du questionneur, numérotées. Je
100
108
  réponds une seule fois, à chacune : CHANGE, et ce que le plan devient, ou GARDE, et pourquoi il
101
109
  reste tel quel. Ma fiche porte aussi le plan tel qu'il devient, ses `questions` ouvertes
102
- et sa `sorte` comprises ; sans `sorte`, le circuit garde celle de mon plan. Chaque question posée a sa ligne dans mes `reponses`, même quand je réponds par des
110
+ et sa `sorte` comprises ; sans `sorte`, le circuit garde celle de mon plan, et sans
111
+ `noms_publies`, ceux de mon plan. Chaque question posée a sa ligne dans mes `reponses`, même quand je réponds par des
103
112
  critères ajoutés : une fiche sans elle est refusée, et le circuit me la redemande une fois avec
104
113
  les numéros qui manquent ; après, une question sans ligne reste ouverte. _Fini quand_ chaque
105
114
  question a sa ligne.
@@ -392,7 +392,8 @@ Le circuit du ticket fait chaque commit après le verdict `ACCEPTÉ` du relecteu
392
392
  d'ensemble : le sens des dépendances que fixe `docs/ARCHITECTURE.md`, le cycle qu'elle créerait,
393
393
  et le composant dont l'élément est la fonction ; un verdict « tranché » nomme la ligne à ajouter
394
394
  (`- <consommateur> : <éléments>`) à l'interface du fournisseur. Le plan du ticket (son titre, sa
395
- section « Architecture », sa section « Noms publiés ») qui nomme le consommateur et chaque élément que le lot ajoute à sa ligne, mot
395
+ section « Architecture », sa section « Noms publiés », que le circuit écrit depuis les
396
+ `noms_publies` de la fiche du plan) qui nomme le consommateur et chaque élément que le lot ajoute à sa ligne, mot
396
397
  pour mot, l'a déjà tranchée : la ligne entre sans arbitrage. Ainsi une dépendance que le ticket
397
398
  fixe ne repasse pas par une question.
398
399
  - **La réponse du responsable s'écrit au ticket** : sous le titre « ## Réponse du responsable —
@@ -66,7 +66,7 @@ LA DERNIÈRE PASSATION de ton rôle (pour un développeur qui n'en a pas encore,
66
66
 
67
67
  Le circuit joue la preuve du rouge après le testwriter, sur les seuls tests du lot (sans eux, sur les paquets du plan entiers), et les contrôles après le développeur : les tests du lot, les paquets du plan, les gardes dans l'enveloppe du plan, dont seuls comptent les constats sur ses fichiers ; puis la passe finale, `npm run verifier`, qui juge le reste.
68
68
 
69
- LES RÉFÉRENCES QUE LE CIRCUIT RÉGÉNÈRE à l'étape 4.2, sur la copie entière, après la passe finale : ce que leur commande écrit dans ces fichiers, le circuit l'écrit, et leur rouge (un plafond, la dette, l'index) n'arrête pas ta séance ; un constat de leur garde sur ton code, sous « Tes rouges », reste le tien :
69
+ LES RÉFÉRENCES QUE LE CIRCUIT RÉGÉNÈRE à l'étape 4.2, sur la copie entière, dès que les contrôles ou la passe finale voient leur rouge, avant de te rendre tes rouges : ce que leur commande écrit dans ces fichiers, le circuit l'écrit, un test qui les lit se juge sur elles régénérées, et leur rouge (un plafond, la dette, l'index) n'arrête pas ta séance ; un constat de leur garde sur ton code, sous « Tes rouges », reste le tien :
70
70
 
71
71
  {{references}}
72
72
 
@@ -208,7 +208,7 @@ LES NOTES DU TICKET :
208
208
 
209
209
  {{notes}}
210
210
 
211
- Tu relèves les composants que le ticket touche (`npx grillhouse composants-affectes {{ticket}}`) et le code qu'il change, par l'index. Ta fiche, que le circuit lit seule, finit ta séance : le plan, ses `criteres`, ceux que tu ajoutes (chacun un comportement que ses tests mesurent, sans son numéro ; le circuit garde tels quels les critères écrits au ticket, la décision du responsable, et écrit les tiens après eux ; changer ou retirer un critère écrit est une question ouverte), ses `paquets` à toucher (le fournisseur d'abord, chacun comme le titre le nomme : le nom de son paquet, ou son chemin), ses `ecartes` (chaque composant du relevé que le plan ne touche pas, avec sa raison ; le circuit rejoue le relevé, et un composant ni dans tes `paquets` ni dans tes `ecartes` rend ta fiche non conforme) et ses `questions` ouvertes (ce que tu ne tranches pas, chacune avec son `motif`, pourquoi elle monte : `langage`, `architecture` ou `écart à la référence`, ce qui revient au responsable, ou `sans réponse`, tu n'as pas la réponse ; et sa `piece`), et sa `sorte` avec sa `raison` (`mécanique` pour un geste sans comportement neuf, avec la `commande` qui le fait, à la racine de la copie : le circuit saute alors le testwriter, la preuve du rouge et le développeur ; `comportement` sinon, `inchangé` quand le lot ne change aucun comportement que ses tests mesurent ; un doute va au circuit, `comportement`). Une question que tu sais trancher, tu la tranches dans le plan. Chaque séance du ticket n'écrit que les paquets du plan.
211
+ Tu relèves les composants que le ticket touche (`npx grillhouse composants-affectes {{ticket}}`) et le code qu'il change, par l'index. Ta fiche, que le circuit lit seule, finit ta séance : le plan, ses `criteres`, ceux que tu ajoutes (chacun un comportement que ses tests mesurent, sans son numéro ; le circuit garde tels quels les critères écrits au ticket, la décision du responsable, et écrit les tiens après eux ; changer ou retirer un critère écrit est une question ouverte), ses `paquets` à toucher (le fournisseur d'abord, chacun comme le titre le nomme : le nom de son paquet, ou son chemin), ses `ecartes` (chaque composant du relevé que le plan ne touche pas, avec sa raison ; le circuit rejoue le relevé, et un composant ni dans tes `paquets` ni dans tes `ecartes` rend ta fiche non conforme) et ses `questions` ouvertes (ce que tu ne tranches pas, chacune avec son `motif`, pourquoi elle monte : `langage`, `architecture` ou `écart à la référence`, ce qui revient au responsable, ou `sans réponse`, tu n'as pas la réponse ; et sa `piece`), et sa `sorte` avec sa `raison` (`mécanique` pour un geste sans comportement neuf, avec la `commande` qui le fait, à la racine de la copie : le circuit saute alors le testwriter, la preuve du rouge et le développeur ; `comportement` sinon, `inchangé` quand le lot ne change aucun comportement que ses tests mesurent ; un doute va au circuit, `comportement`), et ses `noms_publies` (quand le lot ajoute un nom à une ligne « Consommateurs » de l'INTERFACE d'un fournisseur : une entrée par consommateur, le `fournisseur`, le `consommateur` comme sa ligne le nomme et ses `noms` ; le circuit les écrit dans « ## Noms publiés » de la description, réécrite à chaque plan, que la garde des consommateurs lit : un nom qu'un critère seul nomme y reste refusé ; reprends ceux que la section porte déjà ; une liste vide efface la section, et sans le champ le circuit garde celle que la description porte). Une question que tu sais trancher, tu la tranches dans le plan. Chaque séance du ticket n'écrit que les paquets du plan.
212
212
 
213
213
  Tu n'écris rien : ni fichier, ni ticket. Le circuit écrit le plan au ticket : les paquets au titre, les critères et les questions ouvertes dans la description. Puis le questionneur le lit une seule fois.
214
214
  ```
@@ -224,7 +224,7 @@ SES QUESTIONS, numérotées :
224
224
 
225
225
  {{questions}}
226
226
 
227
- Tu réponds une seule fois, à chaque question : dans tes `reponses`, son `numero`, CHANGE avec ce que le plan devient, ou GARDE avec pourquoi il reste tel quel. Ta fiche porte aussi le plan tel qu'il devient : ses `criteres`, ceux que tu ajoutes aux critères écrits au ticket, ses `paquets`, ses `ecartes`, ses `questions` ouvertes, celles que tu ne tranches pas, et sa `sorte` avec sa `raison`, celle de ton plan ou celle que ta réponse lui donne ; sans elle, le circuit garde la sorte de ton plan. Chaque question posée a sa ligne dans tes `reponses`, même quand tu y réponds par des critères ajoutés : une fiche sans elle est refusée et te revient une fois, avec les numéros qui manquent ; après, une question sans ligne reste ouverte. Ce qui reste ouvert monte au superviseur ; le reste, le circuit l'écrit au ticket, et passe aux tests.
227
+ Tu réponds une seule fois, à chaque question : dans tes `reponses`, son `numero`, CHANGE avec ce que le plan devient, ou GARDE avec pourquoi il reste tel quel. Ta fiche porte aussi le plan tel qu'il devient : ses `criteres`, ceux que tu ajoutes aux critères écrits au ticket, ses `paquets`, ses `ecartes`, ses `questions` ouvertes, celles que tu ne tranches pas, et sa `sorte` avec sa `raison`, celle de ton plan ou celle que ta réponse lui donne ; sans elle, le circuit garde la sorte de ton plan ; et ses `noms_publies`, sans lesquels le circuit garde ceux de ton plan. Chaque question posée a sa ligne dans tes `reponses`, même quand tu y réponds par des critères ajoutés : une fiche sans elle est refusée et te revient une fois, avec les numéros qui manquent ; après, une question sans ligne reste ouverte. Ce qui reste ouvert monte au superviseur ; le reste, le circuit l'écrit au ticket, et passe aux tests.
228
228
  ```
229
229
 
230
230
  ## Explorateur, sur le tri des découvertes (rempli par le circuit)
@@ -176,7 +176,8 @@ passation. Ainsi chaque test est rejoué quand ce qu'il lit change, et seulement
176
176
  RÉFÉRENCES QUE LE CIRCUIT RÉGÉNÈRE » se réécrivent à l'étape 4.2, sur la copie entière : l'index
177
177
  des interfaces, les `turbo.json`, les rapports d'API, la dette des gardes, et celles que le projet
178
178
  déclare, un plafond par exemple. Leur rouge n'est pas le tien : ta séance ne s'arrête pas sur elles,
179
- et ta fiche finit FAIT sur ta part. Ainsi le geste mécanique reste au circuit (BP 320.8 : un
179
+ et ta fiche finit FAIT sur ta part. Un test qui lit une référence se juge, aux contrôles, sur elle
180
+ régénérée (BP 320.6.5 : un test qui lisait les `turbo.json`). Ainsi le geste mécanique reste au circuit (BP 320.8 : un
180
181
  développeur aux tests verts arrêté sur le plafond des mots, la dette et l'index).
181
182
 
182
183
  **Un budget de temps vit dans son fichier** : un test qui mesure une durée s'écrit dans un fichier
package/types/index.d.ts CHANGED
@@ -1,7 +1,8 @@
1
1
  export type Ton = 'titre' | 'alerte' | 'attention' | 'actif' | 'discret'
2
2
  // `ticket`: the id of the ticket a line names, which makes the line selectable. `chantier`: the line is an epic's, which the pane switches on or off. `section`: the board's
3
3
  // section the line belongs to. `groupe`: the key of the folded group the line stands for, which `o`
4
- // opens.
4
+ // opens. `etape`: the step a ticket's line of AGENTS stands under (its `numero`, null after the
5
+ // steps); `question`: who must answer the question its circuit stopped on.
5
6
  export type Section = 'agents' | 'chantier' | 'faits' | 'etats'
6
7
  export type Ligne = {
7
8
  texte: string
@@ -11,6 +12,8 @@ export type Ligne = {
11
12
  section: Section
12
13
  groupe?: string
13
14
  avancement?: boolean
15
+ etape?: { numero: string | null; titre: string }
16
+ question?: string
14
17
  }
15
18
  export type Fiche = {
16
19
  numero: string
@@ -23,18 +26,28 @@ export type Fiche = {
23
26
  }
24
27
  // What the mod reads of `grillhouse tableau`: the board's lines, laid out there, the states' view
25
28
  // (`vueEtats`: each state, its meaning, its tickets), each folded group whole (`groupes`), their
26
- // cards, and the ticket that moved last.
29
+ // cards, the ticket that moved last, the project's ticket prefix (`prefixe`) and its counters
30
+ // (`global.compteurs`). A board fused from several projects' adds its footer (`pied`: a summary of
31
+ // each project, a line per project whose board does not read) and the folder of each ticket's
32
+ // project (`dossiers`).
27
33
  export type Tableau = {
28
34
  lignes: Ligne[]
29
35
  vueEtats?: Ligne[]
30
36
  groupes?: Record<string, Ligne[]>
31
37
  fiches: Record<string, Fiche>
32
38
  dernier?: string | null
39
+ prefixe?: string
40
+ global?: { compteurs: { enCours: number; enAttente: number } }
41
+ pied?: Ligne[]
42
+ dossiers?: Record<string, string>
33
43
  }
44
+ // A project's board as the pane read it in its folder: the board, or the fault that kept it out.
45
+ export type Lu = { dossier: string; tableau: Tableau | null; erreur: string | null }
34
46
  // `choisi`: the ticket whose card the pane shows; `element`: the line the keyboard is on; `grand`:
35
47
  // the card fills the pane; `vue`: the lines shown, the board's, the states' view or one folded
36
48
  // group's (`groupe`, its key); `texte`: the
37
- // whole text of the ticket the filled card shows, read from Beads.
49
+ // whole text of the ticket the filled card shows, read from Beads; `projets`: the folders of the
50
+ // projects the pane shows beside the session's, kept for the session's folder.
38
51
  export type Etat = {
39
52
  tableau: Tableau | null
40
53
  erreur: string | null
@@ -45,6 +58,7 @@ export type Etat = {
45
58
  vue: 'tableau' | 'etats' | 'groupe'
46
59
  groupe: string | null
47
60
  texte: { id: string; contenu: string } | null
61
+ projets: string[]
48
62
  }
49
63
 
50
64
  declare module 'claude-code' {