From 1923d6b1bcaf35d0ffb26ede6eae1d17b8c09a3d Mon Sep 17 00:00:00 2001 From: Aaron Wagener Date: Wed, 16 Jul 2025 11:57:11 -0500 Subject: [PATCH] Options: Assert Not All Option in `Options.as_dict` (#5039) * Options: forbid worlds just dumping every single option they don't need * make the equal proper --------- Co-authored-by: Exempt-Medic <60412657+Exempt-Medic@users.noreply.github.com> --- Options.py | 1 + 1 file changed, 1 insertion(+) diff --git a/Options.py b/Options.py index b910d216..e87280ca 100644 --- a/Options.py +++ b/Options.py @@ -1315,6 +1315,7 @@ class CommonOptions(metaclass=OptionsMetaProperty): will be returned as a sorted list. """ assert option_names, "options.as_dict() was used without any option names." + assert len(option_names) < len(self.__class__.type_hints), "Specify only options you need." option_results = {} for option_name in option_names: if option_name not in type(self).type_hints: