130 lines
4.2 KiB
Markdown
130 lines
4.2 KiB
Markdown
<!-- file: deltas/0.3.6/pre.006-fix.002.md -->
|
|
<!-- version: 1 -->
|
|
|
|
# Delta `0.3.6-pre.006-fix.002` — auto-deref idiomatique des accesseurs RAW
|
|
|
|
## Base requise
|
|
|
|
```text
|
|
0.3.6-pre.006-fix.001 appliquée
|
|
workspace.package.version = 0.3.6-pre.6.fix.1
|
|
```
|
|
|
|
Le gate opérateur fourni pour `pre.006-fix.001` confirme :
|
|
|
|
```text
|
|
cargo fmt --all PASS
|
|
python3 scripts/audit_rust_workspace_rules.py PASS / clean
|
|
python3 scripts/audit_markdown_tables.py ... PASS / clean (264 tables / 150 fichiers)
|
|
cargo check --workspace PASS
|
|
cargo clippy --workspace --all-targets PASS avec 2 warnings clippy::explicit_auto_deref
|
|
cargo test -p ksp-job-backfill-lib PASS
|
|
unitaires 20 PASS
|
|
dependency_boundary 2 PASS
|
|
public_api 3 PASS
|
|
release_completeness 2 PASS
|
|
cargo tree -p ksp-job-backfill-lib --edges normal exécuté
|
|
cargo tree -p ksp-job-backfill-lib -e features exécuté
|
|
```
|
|
|
|
## Objectif
|
|
|
|
Supprimer les deux warnings `clippy::explicit_auto_deref` laissés par `pre.006-fix.001`, sans modifier la représentation, l'API publique ou la sémantique du vertical RAW.
|
|
|
|
## Cause exacte
|
|
|
|
Après l'introduction de l'indirection privée, les deux getters utilisaient encore un déréférencement explicite :
|
|
|
|
```rust
|
|
&(*self.inner).transaction
|
|
&(*self.inner).observation
|
|
```
|
|
|
|
Rust effectue déjà cet auto-deref lors de l'accès aux champs d'un `Box<T>`, et Clippy demande donc la forme idiomatique.
|
|
|
|
## Correctif
|
|
|
|
Les deux expressions deviennent :
|
|
|
|
```rust
|
|
&self.inner.transaction
|
|
&self.inner.observation
|
|
```
|
|
|
|
Aucun autre comportement ne change :
|
|
|
|
- `BackfillRawAcquisition` conserve exactement une `Box` privée ;
|
|
- `BackfillHydrationOutcome::Available(BackfillRawAcquisition)` reste inchangé ;
|
|
- les signatures de `transaction()`, `observation()` et `into_parts()` restent inchangées ;
|
|
- la canarie de taille ajoutée en `fix.001` reste inchangée ;
|
|
- aucune allocation supplémentaire n'est introduite ;
|
|
- aucun `#[allow]` n'est ajouté.
|
|
|
|
## Version
|
|
|
|
Le fix modifie du Rust :
|
|
|
|
```text
|
|
workspace.package.version = 0.3.6-pre.6.fix.2
|
|
delivery = 0.3.6-pre.006-fix.002
|
|
commit = v0.3.6-pre.006-fix.002
|
|
```
|
|
|
|
Aucun tag prerelease.
|
|
|
|
## Fichiers ajoutés
|
|
|
|
```text
|
|
deltas/0.3.6/pre.006-fix.002.md
|
|
```
|
|
|
|
## Fichiers modifiés
|
|
|
|
```text
|
|
Cargo.toml
|
|
crates/ksp-job-backfill-lib/src/conversion.rs
|
|
docs/plans/027-V0_3_6_JOB_API_BACKFILL_PLAN.md
|
|
docs/validation/023-V0_3_6_JOB_API_BACKFILL.md
|
|
```
|
|
|
|
## Versions d'en-tête
|
|
|
|
```text
|
|
Cargo.toml 403 -> 404
|
|
crates/ksp-job-backfill-lib/src/conversion.rs 2 -> 3
|
|
docs/plans/027-V0_3_6_JOB_API_BACKFILL_PLAN.md 11 -> 12
|
|
docs/validation/023-V0_3_6_JOB_API_BACKFILL.md 11 -> 12
|
|
```
|
|
|
|
Le présent delta commence à `version: 1`.
|
|
|
|
## Invariants préservés
|
|
|
|
- identité logique transactionnelle toujours `(RawNetworkId, signature)` ;
|
|
- provider/endpoint/protocole restent uniquement de la provenance d'acquisition ;
|
|
- format RAW v1, canonicalisation JSON, SHA-256 et block time inchangés ;
|
|
- chemin observé `getTransaction` et paramètres Transport inchangés ;
|
|
- `Missing` reste structurellement sans provenance ;
|
|
- aucune persistance Store, checkpoint, concurrence ou snapshot ajoutés ;
|
|
- aucune nouvelle dépendance, feature, crate, test ou API publique ;
|
|
- README, USAGE, CHANGELOG, ROADMAP et prompt restent fermés.
|
|
|
|
## Gate opérateur demandé
|
|
|
|
```bash
|
|
cargo fmt --all
|
|
python3 scripts/audit_rust_workspace_rules.py
|
|
python3 scripts/audit_markdown_tables.py README.md RULES.md ROADMAP.md CHANGELOG.md docs prompts crates deltas/0.3.6
|
|
cargo check --workspace
|
|
cargo clippy --workspace --all-targets
|
|
cargo test -p ksp-job-backfill-lib
|
|
cargo tree -p ksp-job-backfill-lib --edges normal
|
|
cargo tree -p ksp-job-backfill-lib -e features
|
|
```
|
|
|
|
Résultat attendu : **20 tests unitaires + 7 canaries d'intégration**, aucun warning Clippy, et graphe de dépendances inchangé.
|
|
|
|
## Questions ouvertes
|
|
|
|
Aucune. `pre.007` reste interdit tant que ce gate n'est pas warning-free.
|