Hmbown/CodeWhale · error
Failed to update setting: invalid transcript spacing
Error message
Failed to update setting: invalid transcript spacing '{value}'. Expected: compact, comfortable, spacious. What it means
The settings setter rejected the value for `transcript_spacing` (alias `spacing`). normalize_transcript_spacing must produce one of compact, comfortable, or spacious; otherwise the update fails. This keeps transcript line spacing within the three supported levels.
Solutions
- Use one of: compact, comfortable, spacious.
- Use the same vocabulary as composer_density — the two share the allowed set.
- Verify with normalize_transcript_spacing in settings.rs if an alias should be accepted.
Example fix
// before
settings.set("spacing", "loose")
// after
settings.set("spacing", "spacious") Defensive patterns
Strategy: validation
Validate before calling
const SPACINGS: [&str; 3] = ["compact", "comfortable", "spacious"];
fn valid_transcript_spacing(v: &str) -> bool {
SPACINGS.contains(&v.trim().to_ascii_lowercase().as_str())
} Try / catch
if let Err(e) = settings.set("transcript_spacing", value) {
eprintln!("{e}");
} Prevention
- Use compact/comfortable/spacious; no loose/tight or numeric values.
- Share the density constant with composer_density tooling.
- Validate in any script that writes settings before invoking the setter.
When it happens
Trigger: Settings update with key `transcript_spacing` or `spacing` and a value outside {compact, comfortable, spacious}, e.g. `set spacing loose`.
Common situations: Using CSS-like keywords (loose, tight); typos like `comforatable`; assuming a numeric spacing value is accepted.
Understand the failure class
Background: "Invalid value" and "allowed values are" config errors: what your library rejected and how to fix it — this error's family across 41 libraries.
Related errors
- Failed to update setting: invalid composer density
- Failed to update setting: invalid focus texture
- Failed to update setting: invalid work surface placement
- Failed to update setting: invalid workbar panel
- Invalid tui.alternate_screen
AI-assisted analysis of Hmbown/CodeWhale@73e0f67d83 (2026-09-22).
Data as JSON: /api/errors/41b559b907d95b16.
Report an issue: GitHub.
Appendix: source
Thrown at crates/tui/src/settings.rs:1669
"composer_border" | "border" => {
self.composer_border = parse_bool(value)?;
}
"composer_multiline_mode" | "multiline_mode" | "multiline" => {
self.composer_multiline_mode = parse_bool(value)?;
}
"composer_vim_mode" | "vim_mode" | "vim" => {
let normalized = value.trim().to_ascii_lowercase();
if !["vim", "normal"].contains(&normalized.as_str()) {
anyhow::bail!(
"Failed to update setting: invalid composer vim mode '{value}'. Expected: normal, vim."
);
}
self.composer_vim_mode = normalized;
}
"transcript_spacing" | "spacing" => {
let normalized = normalize_transcript_spacing(value);
if !["compact", "comfortable", "spacious"].contains(&normalized) {
anyhow::bail!(
"Failed to update setting: invalid transcript spacing '{value}'. Expected: compact, comfortable, spacious."
);
}
self.transcript_spacing = normalized.to_string();
}
"status_indicator" | "indicator" => {
let normalized = normalize_status_indicator(value);
if !["cw", "whale", "dots", "off"].contains(&normalized) {
anyhow::bail!(
"Failed to update setting: invalid status indicator '{value}'. Expected: cw, whale, dots, off."
);
}
self.status_indicator = normalized.to_string();
}
"synchronized_output" | "sync_output" | "sync" => {
let normalized = normalize_synchronized_output(value);
if !["auto", "on", "off"].contains(&normalized) {
anyhow::bail!(View on GitHub (pinned to 73e0f67d83)