code: def is_widget_required_attribute(widget):
      
      if not widget.is_required:
          return False
      if isinstance(widget, WIDGETS_NO_REQUIRED):
          return False
      return True
docs: Is this widget required?