Skip to content

fix(config): align FeedbackSection serde defaults with config YAML#52

Merged
missuo merged 1 commit into
missuo:mainfrom
erning:fix/feedback-default
Apr 6, 2026
Merged

fix(config): align FeedbackSection serde defaults with config YAML#52
missuo merged 1 commit into
missuo:mainfrom
erning:fix/feedback-default

Conversation

@erning

@erning erning commented Apr 1, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • FeedbackSection fields (start_sound, stop_sound, error_sound) used #[serde(default = "default_true")], but DEFAULT_CONFIG_YAML sets them all to false. When the feedback section is missing from a user's config file, serde fills in true, causing sounds to turn on unexpectedly.
  • Change serde defaults to #[serde(default)] (bool defaults to false) so they match the YAML template.

Test plan

  • cargo test -p koe-core — 27 tests pass
  • Remove feedback section from ~/.koe/config.yaml, relaunch app, verify no startup/stop sounds play

FeedbackSection fields used `default_true` for serde defaults while
DEFAULT_CONFIG_YAML set them to false. When the feedback section was
missing from a user's config file, sounds would unexpectedly turn on.
Change serde defaults to `#[serde(default)]` (bool defaults to false)
to match the YAML template.
@missuo missuo merged commit 47c0a34 into missuo:main Apr 6, 2026
@erning erning deleted the fix/feedback-default branch April 7, 2026 02:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants