@roomi-fields/grillhouse 0.49.0 → 0.49.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.
- package/.claude-plugin/plugin.json +1 -1
- package/CHANGELOG.md +22 -0
- package/cadre/templates/projet/.github/workflows/ci.yml +5 -0
- package/cadre/templates/projet/.github/workflows/nuit.yml +6 -4
- package/cadre/templates/projet/CLAUDE.md +1 -1
- package/charte.md +11 -0
- package/dist/temporal/acte.d.ts +9 -0
- package/dist/temporal/acte.js +43 -20
- package/dist/temporal/acte.js.map +1 -1
- package/docs/ARCHITECTURE.md +32 -10
- package/package.json +1 -1
- package/scripts/droits.mjs +7 -4
- package/scripts/enveloppe/enveloppe.mjs +52 -5
- package/scripts/flux-de-la-nuit.mjs +38 -0
- package/scripts/jointure.d.ts +3 -0
- package/scripts/langages/typescript/consommateurs-arbitres.mjs +15 -3
- package/scripts/langages/typescript/tests-de-nuit.mjs +8 -2
- package/scripts/langages/typescript/tests-du-poste.mjs +58 -20
- package/scripts/nuit.sh +41 -10
- package/scripts/repli-de-la-nuit.mjs +105 -34
- package/scripts/services-du-noyau.mjs +1 -0
- package/scripts/tableau.mjs +6 -5
- package/scripts/ticket.mjs +3 -0
- package/scripts/transitions.mjs +15 -4
- package/skills/architecte/SKILL.md +203 -0
- package/skills/architecte/references/exemple-d-architecture.md +159 -0
- package/skills/pitmaster/SKILL.md +3 -0
- package/skills/redacteur/references/documents-d-un-composant.md +2 -1
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,28 @@ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.49.1] - 2026-11-24
|
|
10
|
+
|
|
11
|
+
- **A test of the board no longer reads the Temporal server of the workstation** (grillhouse-3uv.218): the tests that run the board script read the circuits and the night of the workstation, so a silent or slow Temporal server changed their output. They now give the board its own matter, and the script and the tests share one function for the output of the command (`--texte` or JSON). No behaviour of the board changes. **Action for projects**: none.
|
|
12
|
+
|
|
13
|
+
- **A long output of an act no longer comes out altered, and a second sending of the red to a skipped testwriter stops the circuit** (grillhouse-3uv.217): in BPScript (0.49.0) the developpeur sent his red to the testwriter some twenty times in a row under a plan « comportement inchangé » (40 sessions). The act's output was decoded chunk by chunk, so a character of several bytes cut between two chunks of the pipe (near the 64 Ko mark of a 95 Ko red) became replacement characters; the red carried to the next run differed from the one compared, and the guard of the second sending never fired. The output is now decoded as a stream (the acts and the calls of Beads), and the guard no longer depends on the exact equality of a long text: under a plan that skips the testwriter, the second sending stops the circuit « sans-livraison » whatever the output. **Action for projects**: none.
|
|
14
|
+
|
|
15
|
+
- **The architecture document of the frame, its target, enters the repository** (grillhouse-3uv.216): decided by the owner (2026-11-23), who validated the text written by an architect agent. `docs/ARCHITECTURE.md` at the root, 15 lines until now, is replaced by the head document of the target architecture of the frame (components, flows, decisions, the building blocks to come); the common charter names it under « Ce qui décide ». The guards read it as the present state, so the table of components keeps the form they require: the line of the plugin, not yet a package, carries no language, and section 9 says the gap. No behaviour of the code changes. **Action for projects**: none.
|
|
16
|
+
|
|
17
|
+
- **A package of test material leaves the guard of the consumers' arbitrage** (grillhouse-3uv.207): in BPScript (0.48.0) the guard stopped three tickets at 3 Code (« sans-livraison ») because the testwriter added names to the Consommateurs line of 990-corpus, names born with the tests that no plan could announce. The guard no longer judges the interface of a package of the test material (one that exports `./test-fixtures`); a production code that reads it stays refused by the guard of the consumers, and the interface of delivered code is arbitrated as before. **Action for projects**: none.
|
|
18
|
+
|
|
19
|
+
- **The job fusion of the CI plays the preparation of the project** (grillhouse-3uv.210): in OSD (0.49.0, OSD-bpi) the job `fusion` of `ci.yml` was red in a project that declares `grillhouse.outils` (« la clé grillhouse.outils.KNOBKRAFT nomme … qui n'existe pas »): the jobs gardes and tranches played `npm run --if-present ci:preparer`, the job fusion did not, and its command requires the tools like every command of the frame. The job now plays the step after `npm ci` and before the merge, in the template and in the flow of Grillhouse; the architecture and the charter of the template say « chaque job ». **Action for projects**: `npx grillhouse maj` carries the step to a `ci.yml` that bears the frame's mark.
|
|
20
|
+
|
|
21
|
+
- **The night of the poste plays the measures of time that the project's flow does not** (grillhouse-3uv.213): in BPScript (0.49.0, flow of the template since 2026-11-23, 24 measure files), no one played the measures: the night read the word `pc2` of the flow and played `tests-de-nuit --du-poste`, which played the tests tagged `@poste` alone, while the template says « no measure of time plays here ». The night now decides on what the flow plays, read from its commands (`scripts/flux-de-la-nuit.mjs`: a command `tests-de-nuit --mesures`), not on a word: `--du-poste` plays the `@poste` tests, then the measures, unless the flow declares the job that plays them, as the flow of Grillhouse does; then the verdict of that job counts, and the poste plays them only when it was interrupted or never came. The last green is set only when the measures were played and are green, by the poste or by that job. The fallback (`scripts/repli-de-la-nuit.mjs`) took the latest run of the flow without looking at its commit: it now reads the run of the commit the night plays (a run of another commit counts for none; with none, every tranche and the measures play on the poste) and the state of the job `mesures`. The template header of `nuit.yml`, the comment of `nuit.sh` and the architecture say the same. **Action for projects**: none; the next night of the poste plays the measures. A project with a flow of its own that plays them adds a command `tests-de-nuit --mesures` to a job.
|
|
22
|
+
|
|
23
|
+
- **The user's own charter stays out of the role sessions** (grillhouse-3uv.214): `scripts/droits.mjs` launched each role with `--setting-sources project,local` and said the user's CLAUDE.md stayed out, but Claude Code loads `~/.claude/CLAUDE.md` whatever the sources, and the envelope mounted it read-only: 48 transcripts out of 48 carried it, with rules made for the user's own session (commit and push on their own). The envelope no longer mounts it, and the settings of every role exclude it (`claudeMdExcludes`), for the sessions out of the envelope too; the project's charter and the common charter it imports stay loaded. **Action for projects**: none.
|
|
24
|
+
|
|
25
|
+
- **The index of the code enters the envelope of the roles that have it** (grillhouse-3uv.212): the codegraph server, which the charter prescribes and the rights give to the roles that write, did not start in the envelope (947 transcripts of sessions under envelope out of 957 carry « codegraph … ENOENT … Executable not found in $PATH »): the home showed only claude, node, bd, dolt and git's configuration. The envelope of a role whose rights hold the index (`ROLES[role].index`) now mounts read-only `~/.local/bin/codegraph` and `~/.codegraph` (`cheminsDeLIndex`, `scripts/enveloppe/enveloppe.mjs`), and a role without the index receives neither; a program the poste lacks is named in the journal (`⚠ la séance part sans codegraph`). The rtfm server starts already: it comes with its plugin, which the envelope mounts. **Action for projects**: none.
|
|
26
|
+
|
|
27
|
+
- **The frame carries the skill of the architect, and the charter two rules that send a tension to it** (grillhouse-3uv.211): decided by the owner at the grill of grillhouse-2dh (2026-11-23). The plugin has a new skill, `grillhouse:architecte` (`mods/grillhouse/skills/architecte/SKILL.md`), for three works: to instruct a tension between a ticket and the architecture for the owner (the existing, the options, their trade-offs, a recommendation), to survey what the documents say against what the code does, and to bring a prescriptive document (`ARCHITECTURE.md`, `CADRE.md`, `INTERFACE.md`) into conformity after a decision. It carries an accomplished architecture document as an example (`references/exemple-d-architecture.md`, a copy of the architecture of osc-bridge). The common charter receives two rules after « Tous les agents jugent sur le plan »: « Une tension avec l'architecture monte, elle ne se résout pas dans le ticket » (the creator of a ticket, or the explorateur at the plan, who finds no paragraph or one the work contradicts stops and goes up to the supervisor, who loads the skill, instructs the decision and brings it to the owner) and « Un document prescriptif change sur décision seule » (after the decision an architect agent brings the document into conformity and the owner reads the lot; the reviewer returns any other lot that changes a prescriptive document). The supervisor's skill names the new skill. No behaviour of the code changes: neither the alert « en file sans architecture » nor the instructions of the explorateur and of the reviewer, which follow when the architecture document of the frame is written again. **Action for projects**: none; the skill and the rules arrive with the plugin at the update to the version that carries them.
|
|
28
|
+
|
|
29
|
+
- **The two reds of the night of 2026-11-23 on PC2 after grillhouse-3uv.204, both in the tests** (grillhouse-3uv.208): the night of Grillhouse on PC2 (run 45142235840, on 00daa8e3) was red in 2 tests out of 1 254. (A) `tests/unit/dossiers-d-essai.nuit.test.ts` plays by their name five night tests of the envelope, one of which bears `@poste` (claude logged in, the control groups of the user's session), and bore `@equipee` alone: the night of an equipped runner played it. As a tag of Bazel goes with the target to whoever plays it, a night test that names another night test of the repository, its name written whole in a string of its code, now carries what that test requires: the guard `tests-du-poste` reads the name and counts the mark of the poste, or of equipment, of the test named (a name built at run time is not read); `dossiers-d-essai.nuit.test.ts` and `machine.enveloppe-reelle.nuit.spec.ts` bear `@poste`, and the night of the poste keeps them. Same guard, same rules, no migration: no project of the frame has a night test that names another. (B) `tests/temporal/tickets.nuit.spec.ts`, « la file survit à un arrêt du serveur », waited 90 s for a ticket that never started: the test killed its trial server while the circuit of the first ticket was still opening, and a Temporal server killed between the moment it records an activity as started and the arrival of its answer holds that activity until its timeout (90 s of heartbeat and 5 s for an act of the circuit, ten minutes for the measure of its pause). The test now stops its server at rest (`attendreLeRepos` of `tests/temporal/essai.ts`, the predicate `estAuRepos` of `tests/temporal/repos-d-essai.ts`: no workflow task and no activity pending), and the queue's own wake goes from 500 ms to 5 s so that the end of the first circuit, not a timer, wakes it after the restart. The night file played alone is green (14 tests, this one in 3.7 s). Known and unchanged in the product: a server killed at that instant delays a circuit by the same timeout, then the circuit goes on by itself. **Action for projects**: none.
|
|
30
|
+
|
|
9
31
|
## [0.49.0] - 2026-11-23
|
|
10
32
|
|
|
11
33
|
- **The group of the project is read in the main tree, and `grillhouse paquet` refuses a faulty key before it writes** (grillhouse-3uv.205): in SyntHub (SH-bxj, 0.48.0, 2026-11-23), `npx grillhouse paquet packages/gardes`, launched in a copy of work (`.claude/worktrees/paquet-gardes`), ended at 1 on « grillhouse.groupe[0] vaut "../osc-bridge", pas un chemin de projet existant » after it had written the skeleton, and a second launch was refused (« le dossier porte déjà son package.json »). The update read the key in the package.json of the directory it was launched in and resolved its relative paths from there (`lireDuGroupe` of `scripts/grillhouse-maj.mjs`): from a copy, `../osc-bridge` led under `.claude/worktrees/`; `grillhouse maj` launched in a copy failed the same way. The other readers of the key (the survey of the supervisor's session, the queue of the tickets) already receive the main tree. And `creerPaquet` wrote the skeleton before the update judged the key. As git reads its configuration in its common directory whatever the worktree, and as a command validates before it writes (`terraform plan` before `apply`, `cargo new`), the new `groupeDe(dir)` of `scripts/groupe-cles.mjs` reads the key in the package.json of the main tree of the repository (`arbrePrincipal`, as `grillhouse.outils`) and resolves its paths from that tree; the update reads the group through it and writes each `external_projects` relative to the main tree, and `grillhouse paquet` judges the key before its first file: a faulty key is a refusal (⛔, exit code 1, no stack trace), nothing written. **Action for projects**: none; a copy left half built by such a refusal under 0.48.0 is removed (or its package folder and the workspace entry reverted) before the command is played again.
|
|
@@ -182,6 +182,11 @@ jobs:
|
|
|
182
182
|
- name: Install dependencies
|
|
183
183
|
run: npm ci
|
|
184
184
|
|
|
185
|
+
# The project's preparation (system packages, toolchains), when its package.json has the
|
|
186
|
+
# script `ci:preparer`; the merge reads the project's tools (`grillhouse.outils`).
|
|
187
|
+
- name: Prepare the project
|
|
188
|
+
run: npm run --if-present ci:preparer
|
|
189
|
+
|
|
185
190
|
- name: Reports of the tranches
|
|
186
191
|
uses: actions/download-artifact@v4
|
|
187
192
|
with:
|
|
@@ -2,10 +2,12 @@
|
|
|
2
2
|
#
|
|
3
3
|
# The night of a shared machine: once a night, on the default branch, the project's night tests but
|
|
4
4
|
# those that bear the tag @poste (a night test that depends on the poste: its envelope, its tools,
|
|
5
|
-
# its session; the frame's guard `tests-du-poste` asks for the tag), on Node 26.
|
|
6
|
-
#
|
|
7
|
-
#
|
|
8
|
-
#
|
|
5
|
+
# its session; the frame's guard `tests-du-poste` asks for the tag), on Node 26. This flow declares
|
|
6
|
+
# no job that plays the measures of time (a command `tests-de-nuit --mesures`, which the night of
|
|
7
|
+
# the poste reads, scripts/flux-de-la-nuit.mjs): a shared machine does not measure a time (the
|
|
8
|
+
# frame's charter, « Une mesure de temps joue la nuit »), so the night of the poste plays them, on
|
|
9
|
+
# its dedicated cores, after the tests tagged @poste. A green run here is never the last green: the
|
|
10
|
+
# night of the poste alone keeps it, once the measures were played and are green.
|
|
9
11
|
name: Nuit
|
|
10
12
|
|
|
11
13
|
on:
|
|
@@ -40,7 +40,7 @@ interface publiée…>. Le cadre et l'architecture montent toujours (charte comm
|
|
|
40
40
|
- `npm test` (Turborepo : construction, puis tests ; une tâche dont rien n'a bougé est relue de son cache, `npm run test:forcer` rejoue) · `npm test -- <chemins>` (un lancement ciblé : chaque chemin écrit depuis la racine, joué dans son paquet, avec les constructions dont ses tests dépendent, relues du cache ; ses tests rejouent dès que bouge ce qu'ils importent ; un lancement qui ne joue aucun test échoue ; un test de nuit nommé est refusé, la nuit seule le joue ; une mesure de temps — un banc, un témoin de temps — se joue quand son propre fichier est nommé, sous la mesure du temps) · `npm run verifier` (après la construction, les gardes du cadre, celles du projet — son script `gardes` —, le typage de chaque paquet — son script `typecheck`, ses sources et ses tests —, la mise en forme et le lint de la racine — ses scripts `format:check` et `lint`, joués quand ils existent — et les tests, côte à côte, sur sa part de la machine, sans aucune mesure de temps, que joue la nuit seule : ce que jouent l'intégration, la file, la CI et la nuit ; mesuré contre le dernier vert, un paquet rejoué joue les tests que Vitest relie aux fichiers changés depuis, tous quand un changement sort de son graphe ; 0 vert, 1 rouge, un délai dépassé compris ; 75 quand l'attente de la part de la machine ou de place sous /tmp atteint sa borne, ou quand la veille de la mémoire coupe la passe avant que le système ne tue) · `npm run verifier -- --tout` (la passe complète, chaque test joué pour de vrai : ce que joue la nuit) · `npm run verifier -- --gardes` (les gardes, la mise en forme et le lint, même verdict : ce que joue le relecteur) · `npm run typecheck` · `npm run lint` · `npm run format:check`.
|
|
41
41
|
- La préparation de la CI : le script npm `ci:preparer` du `package.json` racine (facultatif ; les
|
|
42
42
|
flux du cadre le jouent, `npm run --if-present ci:preparer`, après `npm ci` et avant la
|
|
43
|
-
vérification, dans chaque job
|
|
43
|
+
vérification, dans chaque job, la fusion des rapports comprise : paquets système, chaîne de langage, variables
|
|
44
44
|
exportées par `$GITHUB_ENV`). Il est rejoué à chaque job et par version de Node : il est
|
|
45
45
|
idempotent, et porte lui-même les droits d'installation sur un exécuteur du projet. Le fichier de
|
|
46
46
|
CI reste au cadre ; un travail propre au projet (une image Docker, un déploiement) vit dans un flux
|
package/charte.md
CHANGED
|
@@ -82,6 +82,17 @@ n'attend que les vraies décisions.
|
|
|
82
82
|
ticket, comme une RFC amendée ; les commentaires restent l'historique. Ainsi chaque agent lit la
|
|
83
83
|
même décision.
|
|
84
84
|
|
|
85
|
+
**Une tension avec l'architecture monte, elle ne se résout pas dans le ticket** : le créateur du
|
|
86
|
+
ticket, ou l'explorateur au plan, qui ne trouve aucun paragraphe, ou en trouve un que le travail
|
|
87
|
+
contredit, s'arrête et monte au superviseur. Le superviseur charge la compétence `architecte`,
|
|
88
|
+
instruit la décision (l'existant, les options, leurs compromis) et la porte au responsable, qui
|
|
89
|
+
tranche. Ainsi aucun ticket ne décide de l'architecture.
|
|
90
|
+
|
|
91
|
+
**Un document prescriptif change sur décision seule** : après la décision du responsable, un agent
|
|
92
|
+
architecte met le document en conformité, et le responsable relit son lot ; le relecteur rend tout
|
|
93
|
+
autre lot qui modifie un document prescriptif. Ainsi le document reste la décision, et non la trace
|
|
94
|
+
du code.
|
|
95
|
+
|
|
85
96
|
**Un fait repris se relit à sa pièce** (fichier:ligne depuis la racine de la copie,
|
|
86
97
|
« $ commande » et sa sortie, ou « ticket, critère N » et « ticket, § <section> » pour ce que dit
|
|
87
98
|
le ticket) avant qu'un agent s'appuie dessus, et un fait transmis porte la
|
package/dist/temporal/acte.d.ts
CHANGED
|
@@ -27,5 +27,14 @@ export declare function cleDeLActivite(info: {
|
|
|
27
27
|
} | null;
|
|
28
28
|
activityId: string;
|
|
29
29
|
}): string | null;
|
|
30
|
+
/**
|
|
31
|
+
* A reader of the lines of a stream of bytes: <surLigne> receives each whole line, and a character
|
|
32
|
+
* of several bytes cut between two chunks is decoded whole (the decoder keeps the bytes of its
|
|
33
|
+
* start). `fin()` hands the last line, without its newline, if any.
|
|
34
|
+
*/
|
|
35
|
+
export declare function lecteurDeLignes(surLigne: (ligne: string) => void): {
|
|
36
|
+
ecrire: (morceau: Buffer) => void;
|
|
37
|
+
fin: () => void;
|
|
38
|
+
};
|
|
30
39
|
/** Plays the act <acte> on <entree> in the main tree <racine>: its outcome. */
|
|
31
40
|
export declare function jouer<T>(acte: string, entree: object, racine: string): Promise<T>;
|
package/dist/temporal/acte.js
CHANGED
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
// that fails is an error of the activity that is not tried again (`ApplicationFailure`, its
|
|
21
21
|
// message and its stack).
|
|
22
22
|
import { spawn } from 'node:child_process';
|
|
23
|
+
import { StringDecoder } from 'node:string_decoder';
|
|
23
24
|
import { fileURLToPath } from 'node:url';
|
|
24
25
|
import { Context } from '@temporalio/activity';
|
|
25
26
|
import { ApplicationFailure } from '@temporalio/common';
|
|
@@ -66,6 +67,32 @@ export function cleDeLActivite(info) {
|
|
|
66
67
|
const d = info.workflowExecution;
|
|
67
68
|
return d ? `${d.workflowId}:${d.runId}:${info.activityId}` : null;
|
|
68
69
|
}
|
|
70
|
+
/**
|
|
71
|
+
* A reader of the lines of a stream of bytes: <surLigne> receives each whole line, and a character
|
|
72
|
+
* of several bytes cut between two chunks is decoded whole (the decoder keeps the bytes of its
|
|
73
|
+
* start). `fin()` hands the last line, without its newline, if any.
|
|
74
|
+
*/
|
|
75
|
+
export function lecteurDeLignes(surLigne) {
|
|
76
|
+
const decodeur = new StringDecoder('utf8');
|
|
77
|
+
let reste = '';
|
|
78
|
+
const lire = (texte) => {
|
|
79
|
+
reste += texte;
|
|
80
|
+
const lignes = reste.split('\n');
|
|
81
|
+
reste = lignes.pop() ?? '';
|
|
82
|
+
lignes.forEach(surLigne);
|
|
83
|
+
};
|
|
84
|
+
return {
|
|
85
|
+
ecrire: morceau => lire(decodeur.write(morceau)),
|
|
86
|
+
fin: () => {
|
|
87
|
+
lire(decodeur.end());
|
|
88
|
+
if (reste) {
|
|
89
|
+
const derniere = reste;
|
|
90
|
+
reste = '';
|
|
91
|
+
surLigne(derniere);
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
};
|
|
95
|
+
}
|
|
69
96
|
/** Plays the act <acte> on <entree> in the main tree <racine>: its outcome. */
|
|
70
97
|
export async function jouer(acte, entree, racine) {
|
|
71
98
|
const contexte = Context.current();
|
|
@@ -84,29 +111,24 @@ export async function jouer(acte, entree, racine) {
|
|
|
84
111
|
const moi = { pid: enfant.pid, depart: departDe(enfant.pid) };
|
|
85
112
|
let vie = precedent;
|
|
86
113
|
let resultat = null;
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
const valeur = JSON.parse(m[2]);
|
|
98
|
-
if (m[1] === 'vie') {
|
|
99
|
-
// The end of a launch (null) keeps the group it named: what remains of it may run.
|
|
100
|
-
if (valeur !== null) {
|
|
101
|
-
vie = valeur;
|
|
102
|
-
}
|
|
103
|
-
contexte.heartbeat({ processus: moi, vie });
|
|
104
|
-
}
|
|
105
|
-
else {
|
|
106
|
-
resultat = { genre: m[1], valeur };
|
|
114
|
+
const lecteur = lecteurDeLignes(l => {
|
|
115
|
+
const m = /^(vie|resultat|erreur) (.*)$/.exec(l);
|
|
116
|
+
if (!m) {
|
|
117
|
+
return;
|
|
118
|
+
}
|
|
119
|
+
const valeur = JSON.parse(m[2]);
|
|
120
|
+
if (m[1] === 'vie') {
|
|
121
|
+
// The end of a launch (null) keeps the group it named: what remains of it may run.
|
|
122
|
+
if (valeur !== null) {
|
|
123
|
+
vie = valeur;
|
|
107
124
|
}
|
|
125
|
+
contexte.heartbeat({ processus: moi, vie });
|
|
126
|
+
}
|
|
127
|
+
else {
|
|
128
|
+
resultat = { genre: m[1], valeur };
|
|
108
129
|
}
|
|
109
130
|
});
|
|
131
|
+
enfant.stdout.on('data', (d) => lecteur.ecrire(d));
|
|
110
132
|
// An act dead before it reads its input says so by its exit, which the close gives.
|
|
111
133
|
enfant.stdin.on('error', () => { });
|
|
112
134
|
// Its last attempt: the one past which Temporal tries it no more (none under an unbounded policy,
|
|
@@ -124,6 +146,7 @@ export async function jouer(acte, entree, racine) {
|
|
|
124
146
|
contexte.cancellationSignal.addEventListener('abort', annuler);
|
|
125
147
|
try {
|
|
126
148
|
const code = await new Promise(ok => enfant.on('close', c => ok(c)));
|
|
149
|
+
lecteur.fin();
|
|
127
150
|
const r = resultat;
|
|
128
151
|
if (contexte.cancellationSignal.aborted) {
|
|
129
152
|
// What remains of the group ends before the activity fails.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acte.js","sourceRoot":"","sources":["../../src/temporal/acte.ts"],"names":[],"mappings":"AAAA,mGAAmG;AACnG,iGAAiG;AACjG,6DAA6D;AAC7D,2FAA2F;AAC3F,kGAAkG;AAClG,+FAA+F;AAC/F,iGAAiG;AACjG,mGAAmG;AACnG,gGAAgG;AAChG,4FAA4F;AAC5F,gGAAgG;AAChG,0GAA0G;AAC1G,0FAA0F;AAC1F,mGAAmG;AACnG,+FAA+F;AAC/F,mGAAmG;AACnG,kGAAkG;AAClG,4FAA4F;AAC5F,0EAA0E;AAC1E,4FAA4F;AAC5F,0BAA0B;AAC1B,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AACxD,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,wCAAwC,CAAC;AAEhG,gGAAgG;AAChG,MAAM,IAAI,GACR,OAAO,CAAC,GAAG,CAAC,0BAA0B;IACtC,aAAa,CAAC,IAAI,GAAG,CAAC,oCAAoC,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;AAChF,oDAAoD;AACpD,MAAM,YAAY,GAAG,KAAK,CAAC;AAC3B,mGAAmG;AACnG,qFAAqF;AACrF,MAAM,QAAQ,GAAG,MAAM,CAAC;AAQxB;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AAC,MAAM,CAAC,CAAC;QACtB,QAAQ,CAAC,kBAAkB,CAAC,mBAAmB,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;AACH,CAAC"}
|
package/docs/ARCHITECTURE.md
CHANGED
|
@@ -90,7 +90,16 @@ tant que rien ne change, et corriger un test ne rejoue que lui.
|
|
|
90
90
|
|
|
91
91
|
**Tout se lit, le plan s'écrit** : un agent de rôle travaille dans l'enveloppe de sa copie
|
|
92
92
|
(`packages/grillhouse/scripts/enveloppe/`, un bac à sable bubblewrap) ; il lit toute la copie,
|
|
93
|
-
index compris (`.codegraph`, `.rtfm`)
|
|
93
|
+
index compris (`.codegraph`, `.rtfm`) ; un rôle à qui ses droits donnent l'index reçoit en lecture
|
|
94
|
+
seule le programme codegraph (`~/.local/bin/codegraph`) et sa maison (`~/.codegraph`), comme un
|
|
95
|
+
bac à sable monte les outils que sa configuration donne au processus (`cheminsDeLIndex`), et le
|
|
96
|
+
journal nomme le programme que le poste n'a pas ; le serveur rtfm vient avec son greffon, déjà
|
|
97
|
+
monté. La charte personnelle de l'utilisateur (`~/.claude/CLAUDE.md`), faite pour sa propre
|
|
98
|
+
séance, n'entre dans aucune séance de rôle, sous enveloppe ou non (comme un travail de CI, qui ne
|
|
99
|
+
charge que la configuration du dépôt) : claude la charge quelles que soient ses sources de
|
|
100
|
+
réglages, si bien que l'enveloppe ne la monte pas et que les réglages de chaque rôle l'excluent
|
|
101
|
+
(`claudeMdExcludes`, `scripts/droits.mjs`) ; la charte du projet et celle qu'elle importe restent
|
|
102
|
+
chargées. Il n'écrit que les composants que le plan de son ticket
|
|
94
103
|
nomme (les paquets du titre), la base des tickets et les sorties du module de son langage (le
|
|
95
104
|
cache de Turborepo ; le `target/` et les magasins de cargo, sa maison `~/.cargo` et `~/.rustup`
|
|
96
105
|
en lecture) ; `.git` reste en lecture seule, et la matière de test partagée s'écrit par le seul
|
|
@@ -599,7 +608,10 @@ celle qu'un superviseur a écrite à la main comprise), et la garde des consomma
|
|
|
599
608
|
ces lignes sans arbitrage ; un nom que le plan ne publie pas reste refusé. Ainsi le développeur
|
|
600
609
|
écrit les lignes que le plan fixe sans arrêt ni geste du superviseur (BP 320.14.2.10, 320.28,
|
|
601
610
|
320.6.5 : un critère seul nommait les noms, la garde refusait le lot, et le superviseur écrivait
|
|
602
|
-
la section à la main avant une nouvelle séance).
|
|
611
|
+
la section à la main avant une nouvelle séance). L'interface d'un paquet de matière de test (qui exporte
|
|
612
|
+
`./test-fixtures`) sort de cette garde, comme une cible `testonly` de
|
|
613
|
+
Bazel sort des règles de dépendance du code livré : ses noms naissent à l'écriture des tests, aucun plan ne
|
|
614
|
+
les annonce ; la garde des consommateurs refuse toujours qu'un code de production la lise.
|
|
603
615
|
|
|
604
616
|
**Un circuit par ticket** : comme une demande de fusion (un auteur, une série de tests et de
|
|
605
617
|
code, une CI sur l'ensemble, une revue), le circuit lance un seul testwriter et un seul
|
|
@@ -1603,20 +1615,30 @@ le délai du repli. Le repli est mesuré par la nuit locale de PC3 (`scripts/nui
|
|
|
1603
1615
|
`scripts/repli-de-la-nuit.mjs`), non par le flux : à son heure, elle lit par `gh` le flux Nuit du
|
|
1604
1616
|
jour ; une tranche dont le job n'a pas démarré 60 minutes après l'heure du flux est annulée et jouée
|
|
1605
1617
|
sur PC3, sur sa part ; une tranche terminée sur PC2, verte ou rouge, n'est jamais rejouée ; une
|
|
1606
|
-
tranche partie puis interrompue compte pour non jouée et se rejoue en entier. Le
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1618
|
+
tranche partie puis interrompue compte pour non jouée et se rejoue en entier. Le flux lu est celui
|
|
1619
|
+
du commit que la nuit joue (`headSha`) : un passage d'un autre commit ne compte pour rien, et sans
|
|
1620
|
+
passage de ce commit PC3 joue toutes les tranches et les mesures. Le relevé dit quelles tranches ont
|
|
1621
|
+
joué où, et le verdict de la nuit au panneau comme le ticket de nuit rouge tiennent compte des deux
|
|
1622
|
+
parts, celle de PC2 et celle de PC3.
|
|
1623
|
+
**Les mesures de temps jouent sur le poste, sauf si le flux déclare le job qui les joue** : un flux
|
|
1624
|
+
partagé ne mesure pas (la charte, « Une mesure de temps joue la nuit »). La nuit du poste décide
|
|
1625
|
+
sur ce que le flux joue, lu de ses commandes (`scripts/flux-de-la-nuit.mjs` : une commande
|
|
1626
|
+
`tests-de-nuit --mesures`), non sur un mot du flux : le flux du gabarit n'en déclare aucune, la
|
|
1627
|
+
nuit du poste joue donc les mesures après les tests `@poste` (`tests-de-nuit --du-poste`), sur les
|
|
1628
|
+
cœurs de `grillhouse.mesure` ; le flux de Grillhouse a son job de mesures, dont le repli lit le
|
|
1629
|
+
verdict pour le commit de la nuit (vert, rouge, en cours, ou à rejouer sur PC3 s'il fut interrompu
|
|
1630
|
+
ou ne vint pas). Un vert du flux ne pose jamais le dernier vert : la nuit du poste seule le pose,
|
|
1631
|
+
et seulement quand les mesures ont été jouées et sont vertes, par le poste ou par ce job. Ainsi PC2
|
|
1632
|
+
joue la nuit, PC3 garde ce qui fait attendre un ticket et mesure ce que le flux ne mesure pas.
|
|
1611
1633
|
|
|
1612
1634
|
**Le cadre porte la CI d'un projet** (`templates/projet/.github/workflows/`,
|
|
1613
1635
|
`packages/grillhouse/scripts/workflows-du-cadre.mjs`) : `ci.yml`, la CI de main par paquets (les
|
|
1614
1636
|
gardes, les tranches, leur fusion ; il joue quand la file le déclenche après l'entrée d'un lot, au
|
|
1615
1637
|
plus une fois par heure, ou à la main, sans planification), et `nuit.yml`, les tests de nuit hors du
|
|
1616
1638
|
poste, tels que Grillhouse les joue chez lui. Le fichier de CI reste au cadre, le projet ne fournit
|
|
1617
|
-
que sa préparation (« Scripts to Rule Them All » de GitHub) : chaque job qui
|
|
1618
|
-
les
|
|
1619
|
-
`nuit.yml` ;
|
|
1639
|
+
que sa préparation (« Scripts to Rule Them All » de GitHub) : chaque job qui vérifie, teste ou fusionne
|
|
1640
|
+
les rapports (le job sans tests, les tranches et la fusion de `ci.yml`, `machine-vierge.yml`, les
|
|
1641
|
+
tranches de `nuit.yml` ; la fusion lit les outils du projet) joue, après `npm ci` et avant les binaires des langages,
|
|
1620
1642
|
`npm run --if-present ci:preparer`, le script du `package.json` racine du projet, qui peut exporter
|
|
1621
1643
|
des variables aux étapes suivantes (`$GITHUB_ENV`) ; sans lui, rien ne change. Le script est rejoué à
|
|
1622
1644
|
chaque job et par version de Node : il est idempotent, et porte lui-même les droits d'installation
|
package/package.json
CHANGED
package/scripts/droits.mjs
CHANGED
|
@@ -10,10 +10,12 @@
|
|
|
10
10
|
//
|
|
11
11
|
// prints the options of claude for that session, one per line (`optionsDuRole`):
|
|
12
12
|
//
|
|
13
|
-
// - `--setting-sources project,local`: the user's own configuration stays out (their
|
|
14
|
-
//
|
|
15
|
-
//
|
|
16
|
-
//
|
|
13
|
+
// - `--setting-sources project,local`: the user's own configuration stays out (their hooks, the
|
|
14
|
+
// skills of their account, their servers, their environment); the project's settings and
|
|
15
|
+
// charter, and the frame's plugin it enables (agents, skills, common charter, hooks), stay in.
|
|
16
|
+
// Claude Code loads the user's charter (`~/.claude/CLAUDE.md`) whatever the sources, so the
|
|
17
|
+
// settings of the role exclude it by its path (`claudeMdExcludes`), and the envelope does not
|
|
18
|
+
// mount it.
|
|
17
19
|
// - `--settings <json>` (the settings of the role, on the command line: no file the session could
|
|
18
20
|
// change): its permissions (`allow`, the commands its skill names, and the reading of its
|
|
19
21
|
// skill's files, references included, and of the METACADRE.md its skill names, in the frame's
|
|
@@ -360,6 +362,7 @@ function reglagesDuRole(role, { racine, copie = racine, ticket, home }) {
|
|
|
360
362
|
deny,
|
|
361
363
|
},
|
|
362
364
|
autoMemoryEnabled: false,
|
|
365
|
+
claudeMdExcludes: [path.join(home, '.claude', 'CLAUDE.md')],
|
|
363
366
|
disableBundledSkills: true,
|
|
364
367
|
skillOverrides: Object.fromEntries(autres.map(s => [s, 'off'])),
|
|
365
368
|
enabledPlugins: Object.fromEntries(
|
|
@@ -118,6 +118,7 @@ import {
|
|
|
118
118
|
import os from 'node:os';
|
|
119
119
|
import path from 'node:path';
|
|
120
120
|
import { pathToFileURL } from 'node:url';
|
|
121
|
+
import { ROLES } from '../droits.mjs';
|
|
121
122
|
import { langageDeLaCopie } from '../langages.mjs';
|
|
122
123
|
import { CODE_REFUS, CODE_USAGE } from './codes.mjs';
|
|
123
124
|
import {
|
|
@@ -206,11 +207,13 @@ export function preparerLesSorties({ copie, paquets, paquetsDeLaCopie, matieres,
|
|
|
206
207
|
}
|
|
207
208
|
// The machine's temporary directory: an empty one, proper to the session, replaces it.
|
|
208
209
|
const TEMPORAIRE = '/tmp';
|
|
209
|
-
// What stays read-only inside `~/.claude`: the configuration and what it loads.
|
|
210
|
+
// What stays read-only inside `~/.claude`: the configuration and what it loads. The user's own
|
|
211
|
+
// charter (`CLAUDE.md`) is not among it: it holds rules made for the user's session (commit and
|
|
212
|
+
// push on their own), and a role session never receives it; the settings of the role also exclude
|
|
213
|
+
// it (`claudeMdExcludes`, scripts/droits.mjs), for the sessions out of the envelope.
|
|
210
214
|
const CLAUDE_EN_LECTURE = [
|
|
211
215
|
'settings.json',
|
|
212
216
|
'settings.local.json',
|
|
213
|
-
'CLAUDE.md',
|
|
214
217
|
'keybindings.json',
|
|
215
218
|
'agents',
|
|
216
219
|
'commands',
|
|
@@ -221,9 +224,9 @@ const CLAUDE_EN_LECTURE = [
|
|
|
221
224
|
];
|
|
222
225
|
// What the home shows read-only besides `~/.claude`, as paths relative to it: claude's launcher
|
|
223
226
|
// and versions, node and its global tools (bd), the state of bd and of its dolt database, and the
|
|
224
|
-
// git configuration. The home shows nothing else
|
|
225
|
-
//
|
|
226
|
-
//
|
|
227
|
+
// git configuration. The home shows nothing else but the programs of the index for a role whose
|
|
228
|
+
// rights hold it (`cheminsDeLIndex`: codegraph); the indexes of the repository are in sight with
|
|
229
|
+
// it.
|
|
227
230
|
const MAISON_EN_LECTURE = [
|
|
228
231
|
'.local/bin/claude',
|
|
229
232
|
'.local/share/claude',
|
|
@@ -237,6 +240,39 @@ const MAISON_EN_LECTURE = [
|
|
|
237
240
|
'.config/git/attributes',
|
|
238
241
|
];
|
|
239
242
|
|
|
243
|
+
// The programs of the index, as paths of the home: the program that the `.mcp.json` of the project
|
|
244
|
+
// launches by its name (codegraph, found in `~/.local/bin`) and the home of its versions. rtfm
|
|
245
|
+
// needs none: its server comes with its plugin, which the envelope mounts (`plugins`).
|
|
246
|
+
const INDEX_DE_LA_MAISON = [{ nom: 'codegraph', programme: '.local/bin/codegraph', maison: '.codegraph' }];
|
|
247
|
+
|
|
248
|
+
/**
|
|
249
|
+
* The paths that the envelope of <role> mounts read-only for the index, as a sandbox mounts the
|
|
250
|
+
* tools its configuration gives a process: those of the programs of the index when the rights of
|
|
251
|
+
* the role hold it (`ROLES[role].index`), and the names of the programs the machine lacks, which
|
|
252
|
+
* the journal says. A role without the index gets nothing.
|
|
253
|
+
* @param {{ role?: string, maison: string, existe?: (p: string) => boolean }} o
|
|
254
|
+
* @returns {{ chemins: string[], manquants: string[] }}
|
|
255
|
+
*/
|
|
256
|
+
export function cheminsDeLIndex({ role, maison, existe = existsSync }) {
|
|
257
|
+
const r = { chemins: [], manquants: [] };
|
|
258
|
+
if (!role || !ROLES[role]?.index) {
|
|
259
|
+
return r;
|
|
260
|
+
}
|
|
261
|
+
for (const { nom, programme, maison: dossier } of INDEX_DE_LA_MAISON) {
|
|
262
|
+
const prog = path.join(maison, programme);
|
|
263
|
+
if (!existe(prog)) {
|
|
264
|
+
r.manquants.push(nom);
|
|
265
|
+
continue;
|
|
266
|
+
}
|
|
267
|
+
r.chemins.push(prog);
|
|
268
|
+
const home = path.join(maison, dossier);
|
|
269
|
+
if (existe(home)) {
|
|
270
|
+
r.chemins.push(home);
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
return r;
|
|
274
|
+
}
|
|
275
|
+
|
|
240
276
|
// The variables of a login session that the envelope passes on, as sudo's env_reset keeps them,
|
|
241
277
|
// claude's OAuth credential, the author of the session's comments at the ticket (`BEADS_ACTOR`,
|
|
242
278
|
// which the circuit sets to the session's role), the mark of the place the session holds
|
|
@@ -409,6 +445,7 @@ export function montagesDeLaSeance({
|
|
|
409
445
|
scratchpads,
|
|
410
446
|
sessions = [],
|
|
411
447
|
outils = {},
|
|
448
|
+
index = [],
|
|
412
449
|
publie = null,
|
|
413
450
|
}) {
|
|
414
451
|
const maison = path.dirname(claude);
|
|
@@ -420,6 +457,7 @@ export function montagesDeLaSeance({
|
|
|
420
457
|
...CLAUDE_EN_LECTURE.map(nom => ({ chemin: path.join(claude, nom), ecriture: false })),
|
|
421
458
|
{ chemin: projet, ecriture: true },
|
|
422
459
|
...MAISON_EN_LECTURE.map(rel => ({ chemin: path.join(maison, rel), ecriture: false })),
|
|
460
|
+
...index.map(chemin => ({ chemin, ecriture: false })),
|
|
423
461
|
...Object.values(outils).map(chemin => ({ chemin, ecriture: false })),
|
|
424
462
|
...(publie === null ? [] : [{ chemin: publie, ecriture: false }]),
|
|
425
463
|
];
|
|
@@ -905,6 +943,14 @@ function envelopper(argv) {
|
|
|
905
943
|
if (existsSync(`${claude}.json`)) {
|
|
906
944
|
copyFileSync(`${claude}.json`, etatJetable);
|
|
907
945
|
}
|
|
946
|
+
// The program of the index for a role whose rights hold it; one the machine lacks is named in
|
|
947
|
+
// the journal, the session starting without it.
|
|
948
|
+
const indexDeLaSeance = cheminsDeLIndex({ role, maison: os.homedir() });
|
|
949
|
+
for (const nom of indexDeLaSeance.manquants) {
|
|
950
|
+
process.stderr.write(
|
|
951
|
+
`⚠ la séance part sans ${nom} : les droits du rôle ${role} lui donnent l'index, le programme est introuvable sur le poste\n`
|
|
952
|
+
);
|
|
953
|
+
}
|
|
908
954
|
const montages = avecLiens(
|
|
909
955
|
montagesDeLaSeance({
|
|
910
956
|
cacheNpm,
|
|
@@ -914,6 +960,7 @@ function envelopper(argv) {
|
|
|
914
960
|
scratchpads,
|
|
915
961
|
sessions,
|
|
916
962
|
outils,
|
|
963
|
+
index: indexDeLaSeance.chemins,
|
|
917
964
|
publie,
|
|
918
965
|
}),
|
|
919
966
|
lienSurDisque
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
// What the Nuit flow of a project plays (`.github/workflows/nuit.yml`), read from the flow's own
|
|
2
|
+
// commands and never from a word of it: the night of the poste (scripts/nuit.sh) leaves the flow
|
|
3
|
+
// what the flow declares it plays, and plays the rest (the frame's charter, « Une mesure de temps
|
|
4
|
+
// joue la nuit »: the measures of time play on dedicated cores, which a shared flow lacks unless it
|
|
5
|
+
// declares a job that plays them).
|
|
6
|
+
import { existsSync, readFileSync } from 'node:fs';
|
|
7
|
+
import path from 'node:path';
|
|
8
|
+
import { fileURLToPath } from 'node:url';
|
|
9
|
+
|
|
10
|
+
/** The path of the Nuit flow in a copy. */
|
|
11
|
+
export const FLUX_DE_LA_NUIT = '.github/workflows/nuit.yml';
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Whether the flow written in <texte> plays the measures of time: one of its commands (a line that
|
|
15
|
+
* is not a comment) runs `tests-de-nuit` with `--mesures`.
|
|
16
|
+
* @param {string} texte
|
|
17
|
+
*/
|
|
18
|
+
export function leFluxJoueLesMesures(texte) {
|
|
19
|
+
return texte
|
|
20
|
+
.split('\n')
|
|
21
|
+
.filter(ligne => !ligne.trim().startsWith('#'))
|
|
22
|
+
.some(ligne => /\btests-de-nuit\b.*(?:^|\s)--mesures(?:\s|$)/.test(ligne));
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Whether the Nuit flow of the copy at <racine> plays the measures of time; false without a flow.
|
|
27
|
+
* @param {string} racine
|
|
28
|
+
*/
|
|
29
|
+
export function fluxDuProjetJoueLesMesures(racine) {
|
|
30
|
+
const f = path.join(racine, FLUX_DE_LA_NUIT);
|
|
31
|
+
return existsSync(f) && leFluxJoueLesMesures(readFileSync(f, 'utf8'));
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
// node flux-de-la-nuit.mjs mesures <copie> exit 0 when the flow of the copy plays the measures
|
|
35
|
+
if (process.argv[1] && fileURLToPath(import.meta.url) === path.resolve(process.argv[1])) {
|
|
36
|
+
const [commande, copie] = process.argv.slice(2);
|
|
37
|
+
process.exitCode = commande === 'mesures' && copie && fluxDuProjetJoueLesMesures(copie) ? 0 : 1;
|
|
38
|
+
}
|
package/scripts/jointure.d.ts
CHANGED
|
@@ -409,6 +409,9 @@ export function avecLeFichierDuPoste<T extends Record<string, string | undefined
|
|
|
409
409
|
env: T,
|
|
410
410
|
o: { fichier: string; ajouts?: Record<string, string>; lire?: (f: string) => string | null }
|
|
411
411
|
): T;
|
|
412
|
+
/** Whether the Nuit flow of the copy at <racine> plays the measures of time itself: one of its
|
|
413
|
+
* commands runs `tests-de-nuit --mesures`; false without a flow (scripts/flux-de-la-nuit.mjs). */
|
|
414
|
+
export function fluxDuProjetJoueLesMesures(racine: string): boolean;
|
|
412
415
|
/** The path of the command <nom> in the PATH of <env>, or null (scripts/commandes-du-path.mjs). */
|
|
413
416
|
export function trouverDansLePath(nom: string, env?: NodeJS.ProcessEnv): string | null;
|
|
414
417
|
/**
|
|
@@ -28,6 +28,12 @@
|
|
|
28
28
|
// section already gives that consumer were settled before. The plan fixed them before the lot,
|
|
29
29
|
// as a code owner's approval covers what it reviewed. The plan is read only for such a line; one
|
|
30
30
|
// that cannot be read refuses, as the comments do.
|
|
31
|
+
// - An interface of a package of the test material (`matieres` of ./consommateurs.mjs, a package
|
|
32
|
+
// that exports `./test-fixtures`) is not judged: the names
|
|
33
|
+
// the testwriter adds to its Consommateurs lines are born with the tests, so no plan can
|
|
34
|
+
// announce them, as Bazel's `testonly` targets leave the dependency rules of released code. A
|
|
35
|
+
// production code that reads such a package stays refused by the guard of the consumers
|
|
36
|
+
// (./consommateurs.mjs).
|
|
31
37
|
// - A refusal names `<INTERFACE.md> § Consommateurs`, the line and the names the plan misses; a
|
|
32
38
|
// refusal inscribed in the project's debt (`grillhouse-dette.json`, see `dette.mjs`) passes,
|
|
33
39
|
// keyed by the interface and `consommateur-sans-arbitrage`. Comments that cannot be read refuse,
|
|
@@ -38,7 +44,7 @@ import { spawnSync } from 'node:child_process';
|
|
|
38
44
|
import { existsSync, readFileSync } from 'node:fs';
|
|
39
45
|
import path from 'node:path';
|
|
40
46
|
import { pathToFileURL } from 'node:url';
|
|
41
|
-
import { lireLigne } from './consommateurs.mjs';
|
|
47
|
+
import { lireLigne, matieres } from './consommateurs.mjs';
|
|
42
48
|
import { trancher } from '../../dette.mjs';
|
|
43
49
|
import { arbitrageTranche, estArbitrage } from '../../services-du-noyau.mjs';
|
|
44
50
|
import { aVerifier, marques, mesureDe } from './interfaces-contre-code.mjs';
|
|
@@ -131,6 +137,7 @@ export function verifier(racine, env = process.env) {
|
|
|
131
137
|
return [];
|
|
132
138
|
}
|
|
133
139
|
const interfaces = [];
|
|
140
|
+
const dossiersMatiere = new Set(matieres(racine).map(m => path.resolve(m.dir)));
|
|
134
141
|
for (const c of aVerifier(racine, env)) {
|
|
135
142
|
const iface = path.join(c.dir, 'docs', 'INTERFACE.md');
|
|
136
143
|
if (!existsSync(iface)) {
|
|
@@ -142,6 +149,7 @@ export function verifier(racine, env = process.env) {
|
|
|
142
149
|
rel,
|
|
143
150
|
avant: head.status === 0 ? head.stdout : null,
|
|
144
151
|
apres: readFileSync(iface, 'utf8'),
|
|
152
|
+
matiere: dossiersMatiere.has(path.resolve(c.dir)),
|
|
145
153
|
});
|
|
146
154
|
}
|
|
147
155
|
const principal = () =>
|
|
@@ -159,13 +167,17 @@ export function verifier(racine, env = process.env) {
|
|
|
159
167
|
/**
|
|
160
168
|
* The findings on the lot of <ticket>, in the debt's form (`dette.mjs`): <interfaces>
|
|
161
169
|
* `[{ rel, avant, apres }]`, each interface's path from the root, its text at HEAD (null when
|
|
162
|
-
* absent) and in the working tree
|
|
170
|
+
* absent) and in the working tree, `matiere` true for a package of the test material, whose lines are
|
|
171
|
+
* not judged (see the header); `commentaires()` the ticket's comments (`[{ text }]`) and
|
|
163
172
|
* `ticketLu()` the ticket (`{ title, description }`), each read only when a changed line needs it,
|
|
164
173
|
* throwing when it does not read.
|
|
165
174
|
*/
|
|
166
175
|
export function juger(ticket, interfaces, commentaires, ticketLu) {
|
|
167
176
|
const changees = [];
|
|
168
|
-
for (const { rel, avant: texteAvant, apres } of interfaces) {
|
|
177
|
+
for (const { rel, avant: texteAvant, apres, matiere } of interfaces) {
|
|
178
|
+
if (matiere) {
|
|
179
|
+
continue;
|
|
180
|
+
}
|
|
169
181
|
const lignesAvant = texteAvant === null ? [] : lignesConsommateurs(texteAvant);
|
|
170
182
|
const avant = new Set(lignesAvant);
|
|
171
183
|
// The names each consumer of HEAD's section reads (`lireLigne` of scripts/langages/typescript/consommateurs.mjs,
|
|
@@ -6,7 +6,8 @@
|
|
|
6
6
|
// node tests-de-nuit.mjs from the root of the copy: the night of the poste
|
|
7
7
|
// node tests-de-nuit.mjs --hors-du-poste the night of an equipped runner: all but @poste
|
|
8
8
|
// node tests-de-nuit.mjs --hors-du-poste --sans-equipement all but @poste and @equipee
|
|
9
|
-
// node tests-de-nuit.mjs --du-poste the tests tagged @poste
|
|
9
|
+
// node tests-de-nuit.mjs --du-poste the tests tagged @poste, then the measures of time unless
|
|
10
|
+
// the project's Nuit flow plays them (the night of PC3)
|
|
10
11
|
// node tests-de-nuit.mjs --mesures the benches and the time witnesses alone
|
|
11
12
|
// node tests-de-nuit.mjs --hors-du-poste --tranche i/n its tranche i of n
|
|
12
13
|
//
|
|
@@ -54,6 +55,7 @@ import { fileURLToPath, pathToFileURL } from 'node:url';
|
|
|
54
55
|
import {
|
|
55
56
|
A_REPASSER,
|
|
56
57
|
avecLaPasse,
|
|
58
|
+
fluxDuProjetJoueLesMesures,
|
|
57
59
|
LA_FORME,
|
|
58
60
|
lireLaTranche,
|
|
59
61
|
} from '../../services-du-noyau.mjs';
|
|
@@ -148,7 +150,11 @@ export function runsDeLaNuit(
|
|
|
148
150
|
: [];
|
|
149
151
|
}
|
|
150
152
|
if (duPoste) {
|
|
151
|
-
|
|
153
|
+
// The night of the poste leaves the flow of the project the measures it declares it plays.
|
|
154
|
+
const mesures =
|
|
155
|
+
(enTient(racine, estUnBanc) || fichiersTemoins(racine).length > 0) &&
|
|
156
|
+
!fluxDuProjetJoueLesMesures(racine);
|
|
157
|
+
return [testsDuPoste(racine).length > 0 && 'du-poste', mesures && 'mesures'].filter(Boolean);
|
|
152
158
|
}
|
|
153
159
|
if (mesuresSeules) {
|
|
154
160
|
return enTient(racine, estUnBanc) || fichiersTemoins(racine).length > 0 ? ['mesures'] : [];
|