docs: def apply_augmentations(linter):
      """Apply augmentation and suppression rules."""
      augment_visit(linter, TypeChecker.visit_attribute, foreign_key_sets)
      augment_visit(linter, TypeChecker.visit_attribute, foreign_key_ids)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_model_field_display_method)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_style_attribute)
      suppress_message(linter, NameChecker.visit_assignname, 'invalid-name', is_urls_module_valid_constant)
  
      # supress errors when accessing magical class attributes
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_manager_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_admin_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_model_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_field_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_charfield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_datefield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_decimalfield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_filefield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_imagefield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_ipfield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_slugfield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_foreignkeyfield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_manytomanyfield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_onetoonefield_attribute)
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_form_attribute)
  
      for parents, attrs in VIEW_ATTRS:
          suppress_message(linter, TypeChecker.visit_attribute, 'no-member', generic_is_view_attribute(parents, attrs))
  
      # formviews have too many ancestors, there's nothing the user of the library can do about that
      suppress_message(linter, MisdesignChecker.visit_classdef, 'too-many-ancestors',
                       is_class('django.views.generic.edit.FormView'))
  
      # model forms have no __init__ method anywhere in their bases
      suppress_message(linter, ClassChecker.visit_classdef, 'W0232', is_class('django.forms.models.ModelForm'))
  
      # Meta
      suppress_message(linter, DocStringChecker.visit_classdef, 'missing-docstring', is_model_meta_subclass)
      pylint_newstyle_classdef_compat(linter, 'old-style-class', is_model_meta_subclass)
      suppress_message(linter, ClassChecker.visit_classdef, 'no-init', is_model_meta_subclass)
      suppress_message(linter, MisdesignChecker.leave_classdef, 'too-few-public-methods', is_model_meta_subclass)
      suppress_message(linter, ClassChecker.visit_attribute, 'protected-access', allow_meta_protected_access)
  
      # Media
      suppress_message(linter, NameChecker.visit_assignname, 'C0103', is_model_media_valid_attributes)
      suppress_message(linter, DocStringChecker.visit_classdef, 'missing-docstring', is_model_media_subclass)
      pylint_newstyle_classdef_compat(linter, 'old-style-class', is_model_media_subclass)
      suppress_message(linter, ClassChecker.visit_classdef, 'no-init', is_model_media_subclass)
      suppress_message(linter, MisdesignChecker.leave_classdef, 'too-few-public-methods', is_model_media_subclass)
  
      # Admin
      # Too many public methods (40+/20)
      # TODO: Count public methods of django.contrib.admin.options.ModelAdmin and increase
      # MisdesignChecker.config.max_public_methods to this value to count only user' methods.
      # nb_public_methods = 0
      # for method in node.methods():
      #     if not method.name.startswith('_'):
      #         nb_public_methods += 1
      suppress_message(linter, MisdesignChecker.leave_classdef, 'R0904', is_model_admin_subclass)
  
      # Tests
      suppress_message(linter, MisdesignChecker.leave_classdef, 'R0904', is_model_test_case_subclass)
  
      # View
      # Method could be a function (get, post)
      suppress_message(linter, ClassChecker.leave_functiondef, 'no-self-use',
                       is_model_view_subclass_method_shouldnt_be_function)
      # Unused argument 'request' (get, post)
      suppress_message(linter, VariablesChecker.leave_functiondef, 'unused-argument',
                       is_model_view_subclass_unused_argument)
      suppress_message(linter, VariablesChecker.leave_functiondef, 'unused-argument', is_argument_named_request)
  
      # django-mptt
      suppress_message(linter, DocStringChecker.visit_classdef, 'missing-docstring', is_model_mpttmeta_subclass)
      pylint_newstyle_classdef_compat(linter, 'old-style-class', is_model_mpttmeta_subclass)
      suppress_message(linter, ClassChecker.visit_classdef, 'W0232', is_model_mpttmeta_subclass)
      suppress_message(linter, MisdesignChecker.leave_classdef, 'too-few-public-methods', is_model_mpttmeta_subclass)
  
      # factory_boy's DjangoModelFactory
      suppress_message(linter, TypeChecker.visit_attribute, 'no-member', is_model_factory)
      suppress_message(linter, ClassChecker.visit_functiondef, 'no-self-argument', is_factory_post_generation_method)
  
      # ForeignKey and OneToOneField
      # Must update this in a thread safe way to support the parallel option on pylint (-j)
      current_leave_module = VariablesChecker.leave_module
      if current_leave_module.__name__ == 'leave_module':
          # current_leave_module is not wrapped
          # Two threads may hit the next assignment concurrently, but the result is the same
          VariablesChecker.leave_module = wrap(current_leave_module, ignore_import_warnings_for_related_fields)
          # VariablesChecker.leave_module is now wrapped
      # else VariablesChecker.leave_module is already wrapped
  
      # wsgi.py
      suppress_message(linter, NameChecker.visit_assignname, 'invalid-name', is_wsgi_application)