lib

Core libraries for Radroots
git clone https://radroots.dev/git/lib.git
Log | Files | Refs | README

commit 682509146a99903c5eccb39e88607223f165de94
parent 90cc25893d2105fed3ca142958e4b15fb72cc22c
Author: triesap <tyson@radroots.org>
Date:   Mon,  3 Aug 2026 12:56:35 +0000

facade: forbid a public radroots::sdk namespace

- Compile-fail the forbidden facade SDK namespace from packaged rustdoc.
- Keep the facade root limited to the curated client boundary exports.
- Assert the namespace contract remains present in primary documentation.
- Verify tests, doctests, strict Clippy, and architecture enforcement.

Diffstat:
Mcrates/radroots/README.md | 6++++++
Mcrates/radroots/tests/package_boundary.rs | 2++
2 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/crates/radroots/README.md b/crates/radroots/README.md @@ -82,5 +82,11 @@ implementations, coordinate FFI/mobile lifecycle, or inspect advanced capability and diagnostics contracts. There is intentionally no `radroots::sdk` namespace or wildcard SDK reexport. +The namespace separation is a compiled contract: + +```compile_fail +use radroots::sdk; +``` + The normative package charter is the [`radroots` release-v1 specification](../../docs/specs/radroots_crates_release_v1.md#19-radroots). diff --git a/crates/radroots/tests/package_boundary.rs b/crates/radroots/tests/package_boundary.rs @@ -3,6 +3,7 @@ use std::collections::BTreeSet; const MANIFEST: &str = include_str!("../Cargo.toml"); const WORKSPACE: &str = include_str!("../../../Cargo.toml"); const ROOT: &str = include_str!("../src/lib.rs"); +const README: &str = include_str!("../README.md"); #[test] fn package_has_final_identity_and_exact_dependencies() { @@ -53,6 +54,7 @@ fn root_has_exact_exports_and_no_sdk_namespace() { assert!(!ROOT.contains("pub mod sdk")); assert!(!ROOT.contains("pub use radroots_sdk::*")); assert_eq!(ROOT.matches("pub use ").count(), 1); + assert!(README.contains("```compile_fail\nuse radroots::sdk;\n```")); } #[test]