From 1746d47412a7b8ebb1b7676e819f1d8d4386d2ee Mon Sep 17 00:00:00 2001 From: SinuS Von SifriduS Date: Thu, 10 Sep 2026 18:25:54 +0200 Subject: [PATCH] v0.3.13-pre.008-fix.002 --- Cargo.toml | 4 +- .../src/runtime_resources.rs | 9 +- deltas/0.3.13/pre.008-fix.002.md | 89 +++++++++++++++++++ 3 files changed, 96 insertions(+), 6 deletions(-) create mode 100644 deltas/0.3.13/pre.008-fix.002.md diff --git a/Cargo.toml b/Cargo.toml index 4214c23..e130e70 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,12 +1,12 @@ # file: Cargo.toml -# version: 554 +# version: 555 [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.13-pre.8.fix.1" +version = "0.3.13-pre.8.fix.2" edition = "2024" license = "MIT" repository = "https://git.sasedev.com/Sasedev/khadhroony-solana-project" diff --git a/crates/ksp-worker-raw-transaction-ingest-lib/src/runtime_resources.rs b/crates/ksp-worker-raw-transaction-ingest-lib/src/runtime_resources.rs index ced1ec9..1043988 100644 --- a/crates/ksp-worker-raw-transaction-ingest-lib/src/runtime_resources.rs +++ b/crates/ksp-worker-raw-transaction-ingest-lib/src/runtime_resources.rs @@ -1,5 +1,5 @@ // file: crates/ksp-worker-raw-transaction-ingest-lib/src/runtime_resources.rs -// version: 22 +// version: 23 use sha2::Digest; // rust-rules: trait-import @@ -621,7 +621,7 @@ impl crate::RawTransactionIngestYellowstoneSource { } /// Runs the productive Yellowstone source task until cooperative stop or one safe terminal source failure. - pub(crate) async fn run( + async fn run( self, settings: crate::RawTransactionIngestSettings, mut stop_receiver: tokio::sync::watch::Receiver, @@ -858,7 +858,7 @@ impl crate::RawTransactionIngestHeliusTransactionSource { } /// Runs one productive Helius `transactionSubscribe` source until cooperative stop or one safe terminal source failure. - pub(crate) async fn run( + async fn run( self, settings: crate::RawTransactionIngestSettings, mut stop_receiver: tokio::sync::watch::Receiver, @@ -1577,7 +1577,7 @@ impl crate::RawTransactionIngestStandardLogsSource { } /// Runs one productive standard `logsSubscribe` source until cooperative stop or one safe terminal source failure. - pub(crate) async fn run( + async fn run( self, settings: crate::RawTransactionIngestSettings, mut stop_receiver: tokio::sync::watch::Receiver, @@ -3414,6 +3414,7 @@ struct RawTransactionIngestHydrationCoordinator { } impl RawTransactionIngestHydrationCoordinator { + #[cfg(test)] fn new(settings: &crate::RawTransactionIngestSettings) -> Self { return Self::with_global_registry(settings, std::sync::Arc::new(RawTransactionIngestGlobalHydrationRegistry::new(settings))); } diff --git a/deltas/0.3.13/pre.008-fix.002.md b/deltas/0.3.13/pre.008-fix.002.md new file mode 100644 index 0000000..5a90599 --- /dev/null +++ b/deltas/0.3.13/pre.008-fix.002.md @@ -0,0 +1,89 @@ + + + +# Delta 0.3.13-pre.008-fix.002 — correction visibilité hydration globale et constructeur de test + +## Base requise + +```text +livraison précédente : 0.3.13-pre.008-fix.001 +Cargo base : 0.3.13-pre.8.fix.1 +delta base : deltas/0.3.13/pre.008-fix.001.md +archive delta base : ksp-general-0.3.13-pre.008-fix.001.zip +``` + +Le gate opérateur du 10 septembre 2026 confirme que `cargo fmt`, `cargo fmt --check`, les audits Rust/Markdown et `cargo check --workspace` passent. `cargo check` signale toutefois quatre warnings dans le Worker, puis Clippy strict les transforme en erreurs : + +```text +3 x private_interfaces : trois méthodes pub(crate) run exposent RawTransactionIngestGlobalHydrationRegistry, qui reste privée au module +1 x dead_code : RawTransactionIngestHydrationCoordinator::new n'est plus utilisé en production depuis la registry globale pre.008 +``` + +Malgré l'échec Clippy, `cargo test -p ksp-worker-raw-transaction-ingest-lib` compile et passe ensuite : `94/94` tests unitaires et toutes les suites d'intégration affichées sont vertes. + +## Objectif du fix + +Corriger strictement ces quatre diagnostics sans élargir l'API interne et sans modifier le contrat de convergence : + +```text +YellowstoneSource::run : pub(crate) -> privé au module +HeliusTransactionSource::run : pub(crate) -> privé au module +StandardLogsSource::run : pub(crate) -> privé au module +HydrationCoordinator::new : compilé uniquement sous #[cfg(test)] +GlobalHydrationRegistry : reste privée au module +``` + +Les trois méthodes `run` concernées ne sont appelées que par `RawTransactionIngestLiveSource::run` dans le même module. La registry globale ne doit donc pas être rendue `pub(crate)` uniquement pour satisfaire la visibilité d'une signature. + +Le constructeur `RawTransactionIngestHydrationCoordinator::new` reste disponible pour les tests unitaires historiques mais n'entre plus dans le binaire production ; le runtime `pre.008` utilise `with_global_registry` avec la registry partagée du supervisor. + +## Version + +```text +livraison : 0.3.13-pre.008-fix.002 +workspace.package.version : 0.3.13-pre.8.fix.2 +archive : ksp-general-0.3.13-pre.008-fix.002.zip +``` + +`Cargo.toml` passe de la version de fichier `554` à `555`. + +## Fichiers modifiés + +```text +Cargo.toml +crates/ksp-worker-raw-transaction-ingest-lib/src/runtime_resources.rs +``` + +`runtime_resources.rs` passe de la version de fichier `22` à `23`. + +## Fichiers ajoutés + +```text +deltas/0.3.13/pre.008-fix.002.md +``` + +## Fichiers supprimés + +```text +aucun +``` + +## Non-claims + +Ce fix ne modifie aucune dépendance, aucune API publique, aucune clé de convergence, aucune borne de registry/cache, aucune sémantique d'hydration, aucune observation/provenance, aucun comportement Store et aucune politique multi-source. + +## Validation dans l'environnement d'assemblage + +Le toolchain Rust/Cargo/Rustfmt n'est pas disponible dans l'environnement d'assemblage. Les commandes Cargo post-fix restent donc `NON EXÉCUTÉ LOCAL`. Les audits statiques KSP et le contrôle exhaustif du delta sont exécutés avant packaging. + +## Gate opérateur requis avant pre.009 + +```bash +cargo fmt --all +cargo fmt --all -- --check +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-worker-raw-transaction-ingest-lib +```