0.0.1-alpha.3.fix.2
This commit is contained in:
6
Cargo.lock
generated
6
Cargo.lock
generated
@@ -4,18 +4,18 @@ version = 4
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "knowledge-domain-lib"
|
name = "knowledge-domain-lib"
|
||||||
version = "0.0.1-alpha.3.fix.1"
|
version = "0.0.1-alpha.3.fix.2"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "knowledge-git-api"
|
name = "knowledge-git-api"
|
||||||
version = "0.0.1-alpha.3.fix.1"
|
version = "0.0.1-alpha.3.fix.2"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"knowledge-domain-lib",
|
"knowledge-domain-lib",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "knowledge-sync-api"
|
name = "knowledge-sync-api"
|
||||||
version = "0.0.1-alpha.3.fix.1"
|
version = "0.0.1-alpha.3.fix.2"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"knowledge-domain-lib",
|
"knowledge-domain-lib",
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
# file: Cargo.toml
|
# file: Cargo.toml
|
||||||
# version: 3
|
# version: 4
|
||||||
|
|
||||||
[workspace]
|
[workspace]
|
||||||
resolver = "3"
|
resolver = "3"
|
||||||
@@ -10,7 +10,7 @@ members = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
[workspace.package]
|
[workspace.package]
|
||||||
version = "0.0.1-alpha.3.fix.1"
|
version = "0.0.1-alpha.3.fix.2"
|
||||||
edition = "2024"
|
edition = "2024"
|
||||||
publish = false
|
publish = false
|
||||||
repository = "https://git.sasedev.com/Sasedev/sasedev-knowledge"
|
repository = "https://git.sasedev.com/Sasedev/sasedev-knowledge"
|
||||||
|
|||||||
@@ -1,13 +1,17 @@
|
|||||||
// file: crates/knowledge-domain-lib/src/content_family.rs
|
// file: crates/knowledge-domain-lib/src/content_family.rs
|
||||||
// version: 1
|
// version: 2
|
||||||
|
|
||||||
//! Content-family identities owned by the Knowledge domain.
|
//! Content-family identities owned by the Knowledge domain.
|
||||||
|
|
||||||
/// Semantic family of knowledge content.
|
/// Semantic family of knowledge content.
|
||||||
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
|
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
|
||||||
pub enum ContentFamily {
|
pub enum ContentFamily {
|
||||||
|
/// Normative Project Governance Rules content.
|
||||||
Pgr,
|
Pgr,
|
||||||
|
/// Practical HOWTO content derived from concrete workflows.
|
||||||
Howto,
|
Howto,
|
||||||
|
/// Reusable focused code or configuration snippet content.
|
||||||
Snippet,
|
Snippet,
|
||||||
|
/// Knowledge that remains local to one project and is not promoted to a shared family.
|
||||||
ProjectLocal,
|
ProjectLocal,
|
||||||
}
|
}
|
||||||
|
|||||||
184
deltas/0.0.1/alpha.3.fix.2.md
Normal file
184
deltas/0.0.1/alpha.3.fix.2.md
Normal file
@@ -0,0 +1,184 @@
|
|||||||
|
<!-- file: deltas/0.0.1/alpha.3.fix.2.md -->
|
||||||
|
<!-- version: 1 -->
|
||||||
|
|
||||||
|
# Delta 0.0.1-alpha.3.fix.2 — documentation publique `ContentFamily`
|
||||||
|
|
||||||
|
## Base requise
|
||||||
|
|
||||||
|
État `0.0.1-alpha.3.fix.1` committé et poussé après application du history :
|
||||||
|
|
||||||
|
```text
|
||||||
|
history/0.0.1/alpha.3.fix.1.md = FAIL
|
||||||
|
```
|
||||||
|
|
||||||
|
La version devient :
|
||||||
|
|
||||||
|
```text
|
||||||
|
0.0.1-alpha.3.fix.2
|
||||||
|
```
|
||||||
|
|
||||||
|
## Cause du second fix
|
||||||
|
|
||||||
|
Le premier fix a corrigé l'erreur `E0423` :
|
||||||
|
|
||||||
|
- `cargo check --workspace` termine ;
|
||||||
|
- les trois suites ciblées passent ;
|
||||||
|
- `SourceId::new("pgr")` est couvert par régression.
|
||||||
|
|
||||||
|
La gate reste néanmoins `FAIL` parce que Clippy est exécuté avec :
|
||||||
|
|
||||||
|
```text
|
||||||
|
-D warnings
|
||||||
|
```
|
||||||
|
|
||||||
|
et transforme en erreurs quatre warnings `missing_docs` sur les variantes publiques :
|
||||||
|
|
||||||
|
```text
|
||||||
|
ContentFamily::Pgr
|
||||||
|
ContentFamily::Howto
|
||||||
|
ContentFamily::Snippet
|
||||||
|
ContentFamily::ProjectLocal
|
||||||
|
```
|
||||||
|
|
||||||
|
La politique `missing_docs` est intentionnelle. Le correctif ne doit donc ni la réduire ni introduire `#[allow(missing_docs)]`.
|
||||||
|
|
||||||
|
## Correctif
|
||||||
|
|
||||||
|
Le fichier :
|
||||||
|
|
||||||
|
```text
|
||||||
|
crates/knowledge-domain-lib/src/content_family.rs
|
||||||
|
```
|
||||||
|
|
||||||
|
documente explicitement chacune des quatre variantes publiques.
|
||||||
|
|
||||||
|
Aucun variant, contrat, type, trait, dépendance ou comportement n'est modifié.
|
||||||
|
|
||||||
|
## Scope
|
||||||
|
|
||||||
|
Le fix reste strictement correctif.
|
||||||
|
|
||||||
|
Il ne modifie pas :
|
||||||
|
|
||||||
|
- `GitRepository` ;
|
||||||
|
- `RepositoryEventSource` ;
|
||||||
|
- `RepositorySyncSignal` ;
|
||||||
|
- le modèle de sources ;
|
||||||
|
- la trajectoire Web/Maud/Vite ;
|
||||||
|
- les décisions PostgreSQL/forge ;
|
||||||
|
- les frontières des trois applications Web.
|
||||||
|
|
||||||
|
Aucun frontend, serveur Actix, adapter Gitea, schéma PostgreSQL ou nouvelle crate n'est ajouté.
|
||||||
|
|
||||||
|
## Fichiers remplacés
|
||||||
|
|
||||||
|
```text
|
||||||
|
VERSION
|
||||||
|
Cargo.toml
|
||||||
|
crates/knowledge-domain-lib/src/content_family.rs
|
||||||
|
docs/plans/001-V0_0_1_FOUNDATION_PLAN.md
|
||||||
|
docs/validation/001-VALIDATION_MATRIX.md
|
||||||
|
```
|
||||||
|
|
||||||
|
## Fichier ajouté
|
||||||
|
|
||||||
|
```text
|
||||||
|
deltas/0.0.1/alpha.3.fix.2.md
|
||||||
|
```
|
||||||
|
|
||||||
|
Aucun fichier n'est supprimé.
|
||||||
|
|
||||||
|
## `Cargo.lock`
|
||||||
|
|
||||||
|
Le delta ne livre pas de lockfile préfabriqué. Les packages héritent de la version workspace `0.0.1-alpha.3.fix.2`; Cargo peut donc mettre à jour `Cargo.lock` dans l'environnement opérateur. Toute modification réelle du lockfile reste versionnée.
|
||||||
|
|
||||||
|
## Validation attendue
|
||||||
|
|
||||||
|
Après application du history `alpha.3.fix.1 FAIL`, commit/push de `alpha.3.fix.1`, puis extraction du présent delta :
|
||||||
|
|
||||||
|
```bash
|
||||||
|
test "$(cat VERSION)" = "0.0.1-alpha.3.fix.2"
|
||||||
|
|
||||||
|
git diff --check
|
||||||
|
|
||||||
|
python3 - <<'PY'
|
||||||
|
from pathlib import Path
|
||||||
|
import tomllib
|
||||||
|
|
||||||
|
with Path("Cargo.toml").open("rb") as handle:
|
||||||
|
root_manifest = tomllib.load(handle)
|
||||||
|
|
||||||
|
assert root_manifest["workspace"]["package"]["version"] == "0.0.1-alpha.3.fix.2"
|
||||||
|
|
||||||
|
content = Path(
|
||||||
|
"crates/knowledge-domain-lib/src/content_family.rs"
|
||||||
|
).read_text(encoding="utf-8")
|
||||||
|
|
||||||
|
for variant in ("Pgr", "Howto", "Snippet", "ProjectLocal"):
|
||||||
|
marker = f" {variant},"
|
||||||
|
index = content.index(marker)
|
||||||
|
prefix = content[:index].rstrip().splitlines()
|
||||||
|
assert prefix[-1].lstrip().startswith("///"), variant
|
||||||
|
|
||||||
|
assert "allow(missing_docs)" not in content
|
||||||
|
assert "missing_docs = \"warn\"" in Path("Cargo.toml").read_text(encoding="utf-8")
|
||||||
|
|
||||||
|
print("Knowledge 0.0.1-alpha.3.fix.2 structural audit: clean")
|
||||||
|
PY
|
||||||
|
|
||||||
|
cargo metadata --format-version 1 --no-deps > /tmp/sasedev-knowledge-alpha3-fix2-metadata.json
|
||||||
|
|
||||||
|
cargo fmt --all
|
||||||
|
cargo fmt --all -- --check
|
||||||
|
|
||||||
|
python3 -B scripts/audit_rust_blank_lines.py crates
|
||||||
|
python3 -B scripts/audit_rust_item_spacing.py crates
|
||||||
|
python3 -B scripts/audit_rust_module_order.py crates
|
||||||
|
python3 -B scripts/audit_rust_trait_import_blocks.py crates
|
||||||
|
python3 -B scripts/audit_rust_reexport_blocks.py crates
|
||||||
|
python3 -B scripts/audit_rust_export_completeness.py --root .
|
||||||
|
|
||||||
|
cargo check --workspace
|
||||||
|
|
||||||
|
cargo clippy --workspace --all-targets --all-features -- -D warnings
|
||||||
|
|
||||||
|
cargo test -p knowledge-domain-lib --all-targets --all-features
|
||||||
|
cargo test -p knowledge-git-api --all-targets --all-features
|
||||||
|
cargo test -p knowledge-sync-api --all-targets --all-features
|
||||||
|
|
||||||
|
test -f Cargo.lock
|
||||||
|
if git check-ignore -q Cargo.lock; then
|
||||||
|
echo 'Cargo.lock must remain versioned' >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
python3 - <<'PY'
|
||||||
|
import json
|
||||||
|
from pathlib import Path
|
||||||
|
|
||||||
|
metadata = json.loads(
|
||||||
|
Path("/tmp/sasedev-knowledge-alpha3-fix2-metadata.json").read_text(encoding="utf-8")
|
||||||
|
)
|
||||||
|
|
||||||
|
packages = {package["name"] for package in metadata["packages"]}
|
||||||
|
assert packages == {
|
||||||
|
"knowledge-domain-lib",
|
||||||
|
"knowledge-git-api",
|
||||||
|
"knowledge-sync-api",
|
||||||
|
}, packages
|
||||||
|
|
||||||
|
for package in metadata["packages"]:
|
||||||
|
assert package["version"] == "0.0.1-alpha.3.fix.2", (
|
||||||
|
package["name"],
|
||||||
|
package["version"],
|
||||||
|
)
|
||||||
|
|
||||||
|
print("Knowledge 0.0.1-alpha.3.fix.2 Cargo metadata audit: clean")
|
||||||
|
PY
|
||||||
|
|
||||||
|
git add -A
|
||||||
|
git diff --cached --check
|
||||||
|
git status --short
|
||||||
|
```
|
||||||
|
|
||||||
|
Ne pas committe `alpha.3.fix.2` avant production de son history à partir des résultats opérateur.
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
<!-- file: docs/plans/001-V0_0_1_FOUNDATION_PLAN.md -->
|
<!-- file: docs/plans/001-V0_0_1_FOUNDATION_PLAN.md -->
|
||||||
<!-- version: 5 -->
|
<!-- version: 6 -->
|
||||||
|
|
||||||
# Plan 0.0.1 — fondation SaseDev Knowledge
|
# Plan 0.0.1 — fondation SaseDev Knowledge
|
||||||
|
|
||||||
@@ -130,7 +130,9 @@ Statut opérateur initial : **FAIL**.
|
|||||||
|
|
||||||
La gate valide la structure et les audits puis échoue dans `knowledge-domain-lib` : `SourceId::new` tente de construire le tuple struct privé via le re-export crate-root depuis son sous-module. Le même défaut bloque `cargo check`, Clippy et les trois suites ciblées.
|
La gate valide la structure et les audits puis échoue dans `knowledge-domain-lib` : `SourceId::new` tente de construire le tuple struct privé via le re-export crate-root depuis son sous-module. Le même défaut bloque `cargo check`, Clippy et les trois suites ciblées.
|
||||||
|
|
||||||
`alpha.3.fix.1` corrige ce défaut Rust, ajoute une régression directe de construction `SourceId` et précise la trajectoire Web/Maud fournie avant clôture de la tranche ; il ne démarre aucune implémentation frontend ou serveur.
|
`alpha.3.fix.1` corrige ce défaut Rust, ajoute une régression directe de construction `SourceId` et précise la trajectoire Web/Maud fournie avant clôture de la tranche ; il ne démarre aucune implémentation frontend ou serveur. Sa gate opérateur reste toutefois **FAIL** : `cargo check` et les tests passent, mais Clippy strict rejette les quatre variantes publiques de `ContentFamily` non documentées sous `missing_docs`.
|
||||||
|
|
||||||
|
`alpha.3.fix.2` corrige exclusivement cette dette de documentation publique et rejoue la gate Rust complète sans modifier les contrats domaine/Git/synchronisation ni le cadrage Web/Maud.
|
||||||
|
|
||||||
Le scope fonctionnel de `alpha.3` reste : introduire uniquement les premiers contrats/types nécessaires aux frontières `GitRepository`, source/famille de contenu et synchronisation, avec tests ciblés. Le modèle doit supporter au moins les trois sources initiales sans coder une limite à trois.
|
Le scope fonctionnel de `alpha.3` reste : introduire uniquement les premiers contrats/types nécessaires aux frontières `GitRepository`, source/famille de contenu et synchronisation, avec tests ciblés. Le modèle doit supporter au moins les trois sources initiales sans coder une limite à trois.
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<!-- file: docs/validation/001-VALIDATION_MATRIX.md -->
|
<!-- file: docs/validation/001-VALIDATION_MATRIX.md -->
|
||||||
<!-- version: 5 -->
|
<!-- version: 6 -->
|
||||||
|
|
||||||
# Matrice de validation Knowledge
|
# Matrice de validation Knowledge
|
||||||
|
|
||||||
@@ -196,3 +196,21 @@ Le fix doit prouver :
|
|||||||
- aucune dépendance ou crate fonctionnelle Web/Actix/PostgreSQL/Gitea ajoutée ;
|
- aucune dépendance ou crate fonctionnelle Web/Actix/PostgreSQL/Gitea ajoutée ;
|
||||||
- trajectoire Web documentée : skeleton Web PGR obligatoire en `alpha.4`, templates statiques de référence, rendu runtime Maud, manifest Vite produit côté frontend et intégration Actix/Maud seulement en `alpha.5` ;
|
- trajectoire Web documentée : skeleton Web PGR obligatoire en `alpha.4`, templates statiques de référence, rendu runtime Maud, manifest Vite produit côté frontend et intégration Actix/Maud seulement en `alpha.5` ;
|
||||||
- hygiène Git et documentation propres.
|
- hygiène Git et documentation propres.
|
||||||
|
|
||||||
|
## Gate de `0.0.1-alpha.3.fix.2`
|
||||||
|
|
||||||
|
Le second fix doit prouver :
|
||||||
|
|
||||||
|
- `VERSION = 0.0.1-alpha.3.fix.2` et version workspace identique ;
|
||||||
|
- history `alpha.3.fix.1` `FAIL` committé avant application du fix ;
|
||||||
|
- documentation Rust présente sur chacune des quatre variantes publiques `Pgr`, `Howto`, `Snippet` et `ProjectLocal` ;
|
||||||
|
- aucune réduction de la politique `missing_docs` et aucun `allow(missing_docs)` introduit pour contourner la gate ;
|
||||||
|
- audits Rust PGR sélectionnés propres ;
|
||||||
|
- `cargo check --workspace` sans warning `missing_docs` ;
|
||||||
|
- Clippy workspace strict `-D warnings` `PASS` ;
|
||||||
|
- les trois suites ciblées `knowledge-domain-lib`, `knowledge-git-api` et `knowledge-sync-api` `PASS` ;
|
||||||
|
- `Cargo.lock` régénéré/versionné si la version workspace le modifie ;
|
||||||
|
- aucun changement fonctionnel des contrats domaine/Git/synchronisation ;
|
||||||
|
- aucun frontend, serveur Actix, schéma PostgreSQL ou adapter de forge ajouté ;
|
||||||
|
- hygiène Git et documentation propres.
|
||||||
|
|
||||||
|
|||||||
118
history/0.0.1/alpha.3.fix.2.md
Normal file
118
history/0.0.1/alpha.3.fix.2.md
Normal file
@@ -0,0 +1,118 @@
|
|||||||
|
<!-- file: history/0.0.1/alpha.3.fix.2.md -->
|
||||||
|
<!-- version: 1 -->
|
||||||
|
|
||||||
|
# History 0.0.1-alpha.3.fix.2 — documentation publique `ContentFamily`
|
||||||
|
|
||||||
|
## Statut
|
||||||
|
|
||||||
|
FAIL
|
||||||
|
|
||||||
|
La gate opérateur de `0.0.1-alpha.3.fix.2` exécutée le `2026-09-27` valide l'ensemble de la gate Rust, mais échoue sur l'hygiène Git/Markdown : `git diff --check` détecte une ligne vide supplémentaire en fin de `docs/validation/001-VALIDATION_MATRIX.md`.
|
||||||
|
|
||||||
|
## Baseline opérateur
|
||||||
|
|
||||||
|
`alpha.3.fix.1` `FAIL` a été historisé, committé et poussé avant application du second fix :
|
||||||
|
|
||||||
|
```text
|
||||||
|
history/0.0.1/alpha.3.fix.1.md = FAIL
|
||||||
|
commit fd3d363
|
||||||
|
message 0.0.1-alpha.3.fix.1
|
||||||
|
branch master
|
||||||
|
push origin/master PASS
|
||||||
|
status clean après push
|
||||||
|
```
|
||||||
|
|
||||||
|
Le push observé a avancé `origin/master` de `6b6bdcf` à `fd3d363`.
|
||||||
|
|
||||||
|
## Audit structurel
|
||||||
|
|
||||||
|
La gate structurelle du fix passe :
|
||||||
|
|
||||||
|
```text
|
||||||
|
Knowledge 0.0.1-alpha.3.fix.2 structural audit: clean
|
||||||
|
```
|
||||||
|
|
||||||
|
Les quatre variantes publiques de `ContentFamily` disposent de doc-comments et aucun `allow(missing_docs)` n'est introduit.
|
||||||
|
|
||||||
|
## Audits Rust
|
||||||
|
|
||||||
|
Les audits PGR sélectionnés passent :
|
||||||
|
|
||||||
|
```text
|
||||||
|
Rust blank-line audit: clean (8 file(s))
|
||||||
|
Rust item-spacing audit: clean (8 file(s))
|
||||||
|
Rust module-order audit: clean (8 file(s))
|
||||||
|
Rust trait-import-block audit: clean (8 file(s))
|
||||||
|
Rust re-export-block audit: clean (8 file(s))
|
||||||
|
Rust export completeness audit: 0 candidate(s) across 3 package(s)
|
||||||
|
```
|
||||||
|
|
||||||
|
## Cargo et Clippy
|
||||||
|
|
||||||
|
Les commandes suivantes passent sans warning `missing_docs` :
|
||||||
|
|
||||||
|
```text
|
||||||
|
cargo check --workspace PASS
|
||||||
|
cargo clippy --workspace --all-targets --all-features
|
||||||
|
-- -D warnings PASS
|
||||||
|
```
|
||||||
|
|
||||||
|
Les trois packages sont observés en version :
|
||||||
|
|
||||||
|
```text
|
||||||
|
0.0.1-alpha.3.fix.2
|
||||||
|
```
|
||||||
|
|
||||||
|
L'audit metadata est propre.
|
||||||
|
|
||||||
|
## Tests ciblés
|
||||||
|
|
||||||
|
Les résultats sont :
|
||||||
|
|
||||||
|
```text
|
||||||
|
knowledge-domain-lib : 3 passed; 0 failed
|
||||||
|
knowledge-git-api : 1 passed; 0 failed
|
||||||
|
knowledge-sync-api : 1 passed; 0 failed
|
||||||
|
```
|
||||||
|
|
||||||
|
Le correctif documentaire n'a donc introduit aucune régression fonctionnelle observée.
|
||||||
|
|
||||||
|
## Défaut bloquant
|
||||||
|
|
||||||
|
`git diff --check` signale avant et après staging :
|
||||||
|
|
||||||
|
```text
|
||||||
|
docs/validation/001-VALIDATION_MATRIX.md:216: new blank line at EOF.
|
||||||
|
```
|
||||||
|
|
||||||
|
La tranche ne peut donc pas être marquée `PASS`, même si toute la gate Rust est propre.
|
||||||
|
|
||||||
|
Cette anomalie provient du delta livré et doit être corrigée par une tranche distincte afin de préserver la vérité opérateur.
|
||||||
|
|
||||||
|
## Staging observé
|
||||||
|
|
||||||
|
Après la gate, le staging contient :
|
||||||
|
|
||||||
|
```text
|
||||||
|
M Cargo.lock
|
||||||
|
M Cargo.toml
|
||||||
|
M VERSION
|
||||||
|
M crates/knowledge-domain-lib/src/content_family.rs
|
||||||
|
A deltas/0.0.1/alpha.3.fix.2.md
|
||||||
|
M docs/plans/001-V0_0_1_FOUNDATION_PLAN.md
|
||||||
|
M docs/validation/001-VALIDATION_MATRIX.md
|
||||||
|
```
|
||||||
|
|
||||||
|
La commande `it status --short` observée dans le transcript est une faute de frappe shell sans impact ; `git status --short` a été exécuté immédiatement après et fournit le scope ci-dessus.
|
||||||
|
|
||||||
|
## Décision
|
||||||
|
|
||||||
|
`0.0.1-alpha.3.fix.2` est `FAIL`.
|
||||||
|
|
||||||
|
La transition autorisée est :
|
||||||
|
|
||||||
|
```text
|
||||||
|
0.0.1-alpha.3.fix.3
|
||||||
|
```
|
||||||
|
|
||||||
|
Le troisième fix doit rester purement documentaire : supprimer la ligne vide supplémentaire en fin de matrice, préserver les corrections Rust déjà validées et rejouer la gate complète.
|
||||||
Reference in New Issue
Block a user