@@ -550,6 +550,8 @@ def _write_main_fuzzing_logic(self) -> None:
550550 if not self .module_classes :
551551 break
552552 class_name = choice (self .module_classes )
553+ if class_name in OBJECT_BLACKLIST :
554+ continue
553555 try :
554556 class_obj = getattr (self .module , class_name )
555557 except AttributeError :
@@ -588,7 +590,11 @@ def _fuzz_one_class(self, class_idx: int, class_name_str: str, class_type: type)
588590 self .write_print_to_stderr (
589591 0 , f'"[{ prefix } ] Attempting to instantiate class: { class_name_str } "'
590592 )
591-
593+ if class_name_str in OBJECT_BLACKLIST :
594+ self .write_print_to_stderr (
595+ 0 , f'"[{ prefix } ] Skipping blacklisted class: { class_name_str } "'
596+ )
597+ return
592598 instance_var_name = (
593599 f"instance_{ prefix } _{ class_name_str .lower ().replace ('.' , '_' )} " # Unique name
594600 )
@@ -793,7 +799,7 @@ def _fuzz_generic_object_methods(
793799 )
794800 self .write (
795801 0 ,
796- f"if callable({ current_prefix } _attr_val): { current_prefix } _methods.append(({ current_prefix } _attr_name, { current_prefix } _attr_val))" ,
802+ f"if callable({ current_prefix } _attr_val) and not { current_prefix } _attr_val.__name__ == 'wait' : { current_prefix } _methods.append(({ current_prefix } _attr_name, { current_prefix } _attr_val))" ,
797803 )
798804 self .restoreLevel (self .base_level - 1 ) # Exit inner try
799805 self .write (0 , f"except Exception: pass" )
@@ -824,7 +830,7 @@ def _fuzz_generic_object_methods(
824830 self .write (0 , f"# Conceptual call to generic method fuzzer" )
825831 self .write (
826832 0 ,
827- f"callMethod(f'{ current_prefix } _gen{{_i_{ current_prefix } }}', { target_obj_expr_str } , { current_prefix } _method_name_to_call)" ,
833+ f"if { current_prefix } _method_name_to_call != 'wait': callMethod(f'{ current_prefix } _gen{{_i_{ current_prefix } }}', { target_obj_expr_str } , { current_prefix } _method_name_to_call)" ,
828834 ) # Example simplified call
829835 self .restoreLevel (self .base_level - 1 ) # Exit for loop
830836 self .restoreLevel (self .base_level - 1 ) # Exit if methods
0 commit comments