MCPcopy Create free account
hub / github.com/base/base / builder_api_config

Method builder_api_config

crates/builder/cli/src/args.rs:402–411  ·  view source on GitHub ↗

Builds validated configuration for the builder transaction insertion RPC. # Errors Returns an error when the shadow injection sample rate is out of range.

(&self)

Source from the content-addressed store, hash-verified

400 ///
401 /// Returns an error when the shadow injection sample rate is out of range.
402 pub fn builder_api_config(&self) -> eyre::Result<BuilderApiExtensionConfig> {
403 let shadow_validity = if self.shadow_validity_injection_enabled {
404 ShadowValidityConfig::enabled(self.shadow_validity_injection_sample_rate_bps)?
405 } else {
406 ShadowValidityConfig::disabled()
407 };
408 Ok(BuilderApiExtensionConfig::new(self.validity_max_predicates)
409 .with_validity_signature_mode(self.validity_signature_mode)
410 .with_shadow_validity(shadow_validity))
411 }
412
413 /// Converts these CLI arguments into a [`BuilderConfig`] using the given shared metering
414 /// provider. The same provider must also be passed to the RPC extension so that the

Callers 3

runMethod · 0.80
mainFunction · 0.80

Calls 3

with_shadow_validityMethod · 0.80
newFunction · 0.50

Tested by 1