v0.3.12-pre.009-fix.001

This commit is contained in:
2026-09-09 22:14:29 +02:00
parent f9d4e6bc74
commit b608ed2c50
4 changed files with 155 additions and 6 deletions

View File

@@ -1,12 +1,12 @@
# file: Cargo.toml
# version: 533
# version: 534
[workspace]
resolver = "3"
members = ["crates/ksp-app-backfill-desk", "crates/ksp-app-config-desk", "crates/ksp-app-solprices-desk", "crates/ksp-app-store-desk", "crates/ksp-app-wallet-desk", "crates/ksp-config-lib", "crates/ksp-core-lib", "crates/ksp-interface-lib", "crates/ksp-job-api", "crates/ksp-job-backfill-lib", "crates/ksp-logging-lib", "crates/ksp-offchain-transport-lib", "crates/ksp-onchain-transport-lib", "crates/ksp-program-api", "crates/ksp-raw-transaction-lib", "crates/ksp-store-api", "crates/ksp-store-lib", "crates/ksp-store-postgres-lib", "crates/ksp-wallet-lib", "crates/ksp-worker-api", "crates/ksp-worker-raw-transaction-ingest-lib"]
[workspace.package]
version = "0.3.12-pre.9"
version = "0.3.12-pre.9.fix.1"
edition = "2024"
license = "MIT"
repository = "https://git.sasedev.com/Sasedev/khadhroony-solana-project"

View File

@@ -1,5 +1,5 @@
// file: crates/ksp-worker-raw-transaction-ingest-lib/unit_tests/runtime_resources.rs
// version: 10
// version: 11
fn grpc_endpoint(cluster: &str) -> std::option::Option<ksp_onchain_transport_lib::YellowstoneGrpcEndpointSettings> {
return grpc_endpoint_with_identity(cluster, "yellowstone-fixture", "fixture-provider");
@@ -1455,7 +1455,8 @@ async fn pre_009_duplicate_storm_is_bounded_coalesced_and_abort_leaves_no_orphan
let pending = *frontier_receiver.borrow();
assert_eq!(pending.hydration_pending(), 3);
assert_eq!(pending.oldest_pending_slot(), std::option::Option::Some(10));
assert_eq!(pending.processing_frontier_slot(), std::option::Option::Some(9));
assert!(pending.processing_frontier_slot() != std::option::Option::Some(10));
let safe_frontier_before_abort = pending.processing_frontier_slot();
coordinator.abort_all(&mut processing_frontier).await;
assert!(coordinator.pending.is_empty());
assert_eq!(coordinator.pending_signal_count, 0);
@@ -1463,7 +1464,7 @@ async fn pre_009_duplicate_storm_is_bounded_coalesced_and_abort_leaves_no_orphan
let cleaned = *frontier_receiver.borrow();
assert_eq!(cleaned.hydration_pending(), 0);
assert_eq!(cleaned.oldest_pending_slot(), std::option::Option::None);
assert_eq!(cleaned.processing_frontier_slot(), std::option::Option::Some(9));
assert_eq!(cleaned.processing_frontier_slot(), safe_frontier_before_abort);
return;
}

View File

@@ -0,0 +1,97 @@
<!-- file: deltas/0.3.12/pre.009-fix.001.md -->
<!-- version: 1 -->
# Delta `0.3.12-pre.009-fix.001` — correction du canari duplicate-storm
## Base requise
```text
0.3.12-pre.009
workspace.package.version = 0.3.12-pre.9
```
## Objectif
Corriger l'unique échec du gate opérateur de `pre.009` sans modifier le runtime :
```text
pre_009_duplicate_storm_is_bounded_coalesced_and_abort_leaves_no_orphan_frontier
left: None
right: Some(9)
```
La predecessor `9` n'est pas une garantie du modèle borné. Après compaction, un pending tardif sur la candidate haute peut rendre la frontier conservative `None`. Le contrat requis est seulement qu'elle n'avance pas à travers le pending et qu'un abort ne l'avance pas artificiellement.
## Version
```text
workspace.package.version = 0.3.12-pre.9.fix.1
```
## Correction
Le canari conserve les preuves de saturation/coalescence/no-orphan mais remplace l'attente exacte `Some(9)` par les invariants :
```text
frontier pré-abort != Some(10)
sauvegarde de la frontier sûre pré-abort
abort_all -> 0 pending / 0 tâche
frontier post-abort == frontier sûre pré-abort
```
Aucun test n'est supprimé et aucune garantie productive n'est relâchée.
## Fichiers modifiés
```text
Cargo.toml
crates/ksp-worker-raw-transaction-ingest-lib/unit_tests/runtime_resources.rs
docs/validation/029-V0_3_12_YELLOWSTONE_HYDRATION_CONTINUITY.md
```
## Fichier ajouté
```text
deltas/0.3.12/pre.009-fix.001.md
```
## Fichiers supprimés
```text
aucun
```
## Non-changements
```text
aucun code productif modifié
aucune API publique modifiée
aucune sémantique frontier/coalescence/hydration modifiée
aucun changement Transport/Store/Config/Backfill/Common RAW
aucun nouveau retry ou repair
```
## Validations d'assemblage
```text
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
canari statique du test corrigé
contrôle diff exact contre pre.009
unzip -t
reproduction du delta sur pre.009
```
`cargo`, `rustc` et `rustfmt` ne sont pas disponibles dans l'environnement d'assemblage ; aucun gate Cargo local n'est revendiqué.
## Gate opérateur requis
```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
cargo check --workspace
cargo clippy --workspace --all-targets --all-features -- -D warnings
cargo test -p ksp-onchain-transport-lib
cargo test -p ksp-worker-raw-transaction-ingest-lib
```

View File

@@ -1,5 +1,5 @@
<!-- file: docs/validation/029-V0_3_12_YELLOWSTONE_HYDRATION_CONTINUITY.md -->
<!-- version: 19 -->
<!-- version: 20 -->
# Validation v0.3.12 — Yellowstone + hydration HTTP + continuité de run du Worker RawTransaction
@@ -1806,3 +1806,54 @@ cargo tree --duplicates
Dans l'environnement d'assemblage, `cargo`, `rustc` et `rustfmt` ne sont pas installés ; aucun gate Cargo local n'est revendiqué.
## 77. Gate opérateur `pre.009` et correction du canari duplicate-storm
Le gate opérateur reçu pour `0.3.12-pre.9` confirme :
```text
cargo check --workspace : PASS
cargo clippy --workspace --all-targets --all-features -- -D warnings : PASS
ksp-onchain-transport-lib : 388 unit PASS, 51 public_api PASS, 43 release_completeness PASS, doc-tests PASS
ksp-worker-raw-transaction-ingest-lib : 65/66 unit PASS avant fix ; l'unique échec est le nouveau canari duplicate-storm
```
L'échec est :
```text
pre_009_duplicate_storm_is_bounded_coalesced_and_abort_leaves_no_orphan_frontier
left: None
right: Some(9)
```
La cause est le canari, pas le runtime. La compaction run-local de `pre.007` conserve une représentation bornée des slots settled. Après `observe_settled(10)`, la predecessor `9` peut déjà avoir été compactée ; si un pending tardif arrive ensuite sur `10`, la projection conservative autorisée est donc `None` plutôt qu'une predecessor inventée.
`pre.009-fix.001` ne modifie pas la logique productive. Le canari vérifie désormais les invariants réellement garantis :
```text
le pending sur 10 ne peut jamais publier frontier = 10
la frontier sûre observée avant abort est mémorisée telle quelle
abort_all nettoie pending/coalescence/tasks
après abort, la frontier est identique à la frontier sûre pré-abort
aucun pending abandonné n'est transformé en settled
```
Ainsi, le test reste strict sur le no-orphan et l'absence d'avancement artificiel, sans exiger une history predecessor que la compaction bornée n'a pas obligation de conserver.
Version de fix :
```text
workspace.package.version = 0.3.12-pre.9.fix.1
```
Gate opérateur requis :
```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
cargo check --workspace
cargo clippy --workspace --all-targets --all-features -- -D warnings
cargo test -p ksp-onchain-transport-lib
cargo test -p ksp-worker-raw-transaction-ingest-lib
```