Fix 'General' settings not available after upgrade (blocks startup)#3013
Merged
HelioGuilherme66 merged 1 commit intorobotframework:developfrom Mar 29, 2026
Merged
Conversation
- Add migration from settings version 8 to 9 that ensures General section exists with all required keys - Add safe access to General settings in application.py, mainframe.py, treeplugin.py, and dialog.py - Use .get() with fallback values instead of direct dictionary access - This prevents KeyError when user settings file is missing or corrupted Closes robotframework#3000
HelioGuilherme66
approved these changes
Mar 29, 2026
HelioGuilherme66
pushed a commit
to HelioGuilherme66/RIDE
that referenced
this pull request
Mar 29, 2026
…obotframework#3013) - Add migration from settings version 8 to 9 that ensures General section exists with all required keys - Add safe access to General settings in application.py, mainframe.py, treeplugin.py, and dialog.py - Use .get() with fallback values instead of direct dictionary access - This prevents KeyError when user settings file is missing or corrupted Closes robotframework#3000
HelioGuilherme66
added a commit
that referenced
this pull request
Mar 29, 2026
* Add options to make visible spaces and newlines in Text Editor. * Fix 'General' settings not available after upgrade (blocks startup) (#3013) - Add migration from settings version 8 to 9 that ensures General section exists with all required keys - Add safe access to General settings in application.py, mainframe.py, treeplugin.py, and dialog.py - Use .get() with fallback values instead of direct dictionary access - This prevents KeyError when user settings file is missing or corrupted Closes #3000 * Enable visible spaces and newlines in External/Code Editor. --------- Co-authored-by: ChelSlava <chelslava@gmail.com>
HelioGuilherme66
added a commit
to HelioGuilherme66/RIDE
that referenced
this pull request
Mar 31, 2026
* Add options to make visible spaces and newlines in Text Editor. * Fix 'General' settings not available after upgrade (blocks startup) (robotframework#3013) - Add migration from settings version 8 to 9 that ensures General section exists with all required keys - Add safe access to General settings in application.py, mainframe.py, treeplugin.py, and dialog.py - Use .get() with fallback values instead of direct dictionary access - This prevents KeyError when user settings file is missing or corrupted Closes robotframework#3000 * Enable visible spaces and newlines in External/Code Editor. --------- Co-authored-by: ChelSlava <chelslava@gmail.com>
HelioGuilherme66
added a commit
to HelioGuilherme66/RIDE
that referenced
this pull request
Mar 31, 2026
* Add visible searching indicator to Find Usages dialog Closes robotframework#2672 The 'searching...' indicator is now shown as the first row in the results table, making it more visible to users who focus on the table rather than the dialog title. * Make visible spaces and newlines in Text Editor. (robotframework#3026) * Add options to make visible spaces and newlines in Text Editor. * Fix 'General' settings not available after upgrade (blocks startup) (robotframework#3013) - Add migration from settings version 8 to 9 that ensures General section exists with all required keys - Add safe access to General settings in application.py, mainframe.py, treeplugin.py, and dialog.py - Use .get() with fallback values instead of direct dictionary access - This prevents KeyError when user settings file is missing or corrupted Closes robotframework#3000 * Enable visible spaces and newlines in External/Code Editor. --------- Co-authored-by: ChelSlava <chelslava@gmail.com> * Restore wrongly deleted test fixture * Add ChelSlova PR to improve visibility off Search in Find Usages --------- Co-authored-by: ChelSlava <chelslava@gmail.com>
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.
Summary
'General'settings section is missingGeneralsection exists with all required keysGeneralsettings in multiple files using.get()with fallback valuesProblem
After upgrading RIDE, the application crashes on startup with:
This happens when:
Generalsectionsettings['General']failsRoot Cause
Multiple files accessed
settings['General']directly without checking if the section exists:application.py:150-self.settings['General'].get('font size', 12)mainframe.py:163-application.settings['General']treeplugin.py:291-settings.get_without_default('General')dialog.py:34-_settings['General']Solution
migrate_from_8_to_9()- CreatesGeneralsection with default values if missing['General']access to.get('General', {})with fallback valuesFiles Modified
src/robotide/preferences/settings.py- Added migration methodsrc/robotide/preferences/settings.cfg- Updated version to 9src/robotide/application/application.py- Safe access to font settingssrc/robotide/ui/mainframe.py- Safe access to general settingssrc/robotide/ui/treeplugin.py- Safe access to theme settingssrc/robotide/widgets/dialog.py- Safe access to dialog settingsTesting
Generalsection in settingsCloses #3000