Repository navigation
fix: block saves and mapping starts after configuration read failures - #54
Merged
EvanZhu0721 merged 2 commits intoNov 5, 2026
Merged
Conversation
Plain reset could not load a corrupt config-profiles file, while the UI told users to reset or repair it. Co-authored-by: Cursor <cursoragent@cursor.com>
Nardo021
marked this pull request as draft
November 3, 2026 01:13
Nardo021
marked this pull request as ready for review
November 3, 2026 01:13
8 tasks
Reuse the existing UI save-blocked state for initial load and reload failures. Keep the original error visible across edits and hydration, and reject saves, mapping starts, and manual restarts until a successful reload. Stop remains available. Record initial read failures in the existing diagnostics log. Keep the change scoped to this UI failure boundary and its regression coverage. The profile storage format and command-line interface remain unchanged. Validation: the regression fails against the previous UI and passes with this patch; fmt, Clippy, and 139 Rust tests pass (26 ignored and one mouse-hook test skipped). The signed 2.0.2 installer was built and verified locally.
Owner
|
感谢PR! 不过为了这个Edge Case维护1500+代码的逻辑实在有点重量, 很抱歉不能merge一整套恢复逻辑. 参考你的代码精简了亿下, 保留了配置损坏后的block. 再次感谢贡献! BTW, 个人觉得让coding agent做对抗性review还是挺危险的. |
EvanZhu0721
added a commit
that referenced
this pull request
Nov 5, 2026
Keep configuration read failures visible and block saves and mapping starts until reload succeeds.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When the profile collection cannot be read, geometry edits can clear the original error, and a failed reload leaves the UI accepting actions against stale drafts.
Reuse the existing save-blocked state until a successful reload. Preserve the read error across edits and hydration, block mapping saves, starts, and manual restarts, and keep Stop available. The main panel reports that the configuration is unavailable, and initial read failures are recorded in the existing diagnostics log.
The regression test exercises damaged configuration, blocked edits and saves, failed reload, and successful reload after the file is restored.
Validation:
cargo fmt --all --checkandcargo clippy --locked --all-targets -- -D warningspass.