pub struct BuildSpec {
pub version: u32,
pub renderer: Renderer,
pub module: ModuleSpec,
pub packages: BTreeMap<String, PackageSpec>,
pub root_package: String,
pub workspace_members: Vec<String>,
pub target_resolves: Option<GoCompactTargetResolves>,
pub go_sum_sha256: Option<String>,
}Fields§
§version: u32§renderer: RendererCoarse = the v1 buildGoModule path; Incremental = this
per-package graph. The M1 encoder always emits Incremental.
module: ModuleSpec§packages: BTreeMap<String, PackageSpec>EVERY build-graph node, keyed canonically (see node_key).
BTreeMap ⇒ canonical JSON key order by construction.
root_package: StringThe primary buildable node key (a package main).
workspace_members: Vec<String>Every buildable main node (akeyless: logan/gator/auth/… → many).
target_resolves: Option<GoCompactTargetResolves>Compact per-target import graph. M1 populates exactly one target;
the shape is future-proof for the multi-target milestone.
Lossless: substrate reconstructs base // overrides[tuple].
go_sum_sha256: Option<String>SHA-256 of go.sum content at emit — the D2 freshness tie
(mirror of cargo_lock_sha256; consumed by substrate’s
go/lockfile-delta.nix). Empty-string hash e3b0c4… when the
module is dep-free.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for BuildSpec
impl<'de> Deserialize<'de> for BuildSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Spec for BuildSpec
impl Spec for BuildSpec
Source§type Args = GoPackageArgs
type Args = GoPackageArgs
Per-package buildRustCrate-equivalent args.
Source§type Quirk = GomodQuirk
type Quirk = GomodQuirk
Per-package quirks variant set (typed by the adapter).
Source§fn schema_version(&self) -> u32
fn schema_version(&self) -> u32
Spec schema version. Substrate’s lockfile-builder asserts
this >= a known floor; cse-lint flags stale specs.
Source§fn member_keys(&self) -> Vec<&str>
fn member_keys(&self) -> Vec<&str>
Every package the workspace tracks (root + members).
Source§fn args_for(&self, key: &str) -> Option<&Self::Args>
fn args_for(&self, key: &str) -> Option<&Self::Args>
Pre-shaped build args for one package, or None if the package
isn’t in the spec.
Source§fn quirks_for(&self, key: &str) -> &[Self::Quirk]
fn quirks_for(&self, key: &str) -> &[Self::Quirk]
Quirks registered for one package — empty when no quirks
apply, never None.
Auto Trait Implementations§
impl Freeze for BuildSpec
impl RefUnwindSafe for BuildSpec
impl Send for BuildSpec
impl Sync for BuildSpec
impl Unpin for BuildSpec
impl UnsafeUnpin for BuildSpec
impl UnwindSafe for BuildSpec
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more