validate_field

Function validate_field 

Source
pub fn validate_field(key: &str, value: &str) -> Result<()>
Expand description

Validate and parse a configuration field based on its key.

This function handles the validation logic that was previously embedded in ProductionConfigService::validate_and_set_value.

§Arguments

  • key - The configuration key (e.g., “ai.temperature”)
  • value - The string value to validate and parse

§Returns

Returns Ok(()) if validation passes, or an error describing the validation failure.