Skip to content

fix(engine): report config.toml parse errors instead of using defaults - #4416

Merged
LHagfoss merged 2 commits into
mainfrom
fix/engine-config-parse-errors
Nov 25, 2026
Merged

LHagfoss merged 2 commits into
mainfrom
fix/engine-config-parse-errors

Conversation

@LHagfoss

Copy link
Copy Markdown
Owner

What

A config.toml that fails to parse no longer leaves the user guessing. The engine keeps the parser's message (file, line and column) and reports it:

  • rustcode doctor fails config-load with the message and a hint; a broken project .rustcode/config.toml gets its own project-config row.
  • _rustcode/settings/get (a full read) carries configIssues, and Settings shows a warning notice at the top of every page.
  • A save refused while the config is invalid names the file and the parse error instead of "configuration is invalid".

The file is still never rewritten while invalid.

Changelog

Settings and rustcode doctor now say when config.toml could not be read, with the line to fix, instead of silently using defaults.

Testing

cargo fmt --all -- --check, scripts/check-comments.py, scripts/check-rust-size.py, bun run check. New unit tests in config/load_issues.rs, doctor.rs, acp/settings.rs and configIssues.test.ts; Rust tests run in CI.

Closes #4371

@LHagfoss LHagfoss added the bug Something isn't working label Nov 25, 2026
@github-actions github-actions Bot added the fix A bug fix label Nov 25, 2026
@LHagfoss
LHagfoss merged commit bf463ec into main Nov 25, 2026
10 checks passed
@LHagfoss
LHagfoss deleted the fix/engine-config-parse-errors branch November 25, 2026 22:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working fix A bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(engine): report config.toml parse errors instead of using defaults

2 participants