Repository navigation
Check Profile: offer fixes, including renumbering sticks to match this PC - #40
Merged
Merged
Conversation
…s PC Amr expected Check Profile to repair what it finds, not just list it (2026-11-20), and chose to add fixes before 0.11.0 ships. Each finding now carries a fix; profile_fixer applies them to the XML and writes a temp copy, which the app loads as an unsaved, modified profile so the user reviews and saves as usual. The original file is never written. Safe fixes (applied by "Fix all safe ones"): drop forced "press" on view actions, move tuning to the stick's current device ID, clear bindings on inputs a stick lacks, and renumber jsN so every binding follows its stick (only offered when each profile stick is connected exactly once). Fixes that need a choice: which action keeps a button that switches several modes, and restoring cleared view actions onto free hat directions. Renumbering runs last so other fixes still match old jsN. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011hqxFh5GLh4UnV4rY8Fzdw
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.
Requested by Amr · project thread
Why
While testing 0.11.0, Amr expected Check Profile to fix the problems it finds, not only list them. He chose to add the fixes before 0.11.0 ships.
What
Most findings now have a 🔧 link, and Fix all safe ones applies every fix that doesn't need a choice. Fixes are applied to the XML, written to a temp copy, and loaded as an unsaved, modified profile. The user reviews the changes and then uses Save Profile, which defaults to the original folder. The original file is never written.
*_holdaction forced to "press"The renumber fix always runs last, so the other fixes still match the profile's old js numbers.
Verified
pytest tests/: 101 passed, including 11 new tests intests/test_profile_fixer.py.actionmaps.xml, with mock sticks set to a swapped order: after the fixes, only the two informational notes remain, and the fixed file parses with SCPE's parser.check_profile_swapped.json): Fix all safe ones renumbers the profile, and the device table goes all ✓. The choice fixes work, the profile is marked modified, Save is enabled, and the last-opened path still points at the original file.Windows test
Add this to the #39 checklist: on the game PC, click Fix all safe ones on the live profile, then Save Profile to a new layout file and import that in game.
Generated by Claude Code