Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better error message for conflicting settings in plando #1862

Merged
merged 1 commit into from
Feb 4, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions SettingsList.py
Original file line number Diff line number Diff line change
Expand Up @@ -6310,9 +6310,8 @@ def validate_settings(settings_dict):

def validate_disabled_setting(settings_dict, setting, choice, other_setting):
if other_setting in settings_dict:
disabled_default = get_setting_info(other_setting).disabled_default
if settings_dict[other_setting] != disabled_default:
raise ValueError(f'{other_setting!r} must be set to {disabled_default!r} since {setting!r} is set to {choice!r}')
if settings_dict[other_setting] != get_setting_info(other_setting).disabled_default:
raise ValueError(f'The {other_setting!r} setting cannot be used since {setting!r} is set to {choice!r}')

class UnmappedSettingError(Exception):
pass
Expand Down