          try:
              username = backend.clean_username(username)
          return username
  
      def _remove_invalid_user(self, request):
          """
 
</s> remove         with suppress(AttributeError):  # Backend has no clean_username method.
 </s> add         try: </s> remove     with suppress(AttributeError):
 </s> add     try: </s> remove     with suppress(Exception):
 </s> add     try: </s> remove         with suppress(NotImplementedError):
 </s> add         try:
        except AttributeError:  # Backend has no clean_username method.
            pass
          try:
              username = backend.clean_username(username)
        except AttributeError:  # Backend has no clean_username method.
            pass
          return username
  
      def _remove_invalid_user(self, request):
          """
keep add keep keep keep keep
 Reverted "Fixed #27818 -- Replaced try/except/pass with contextlib.suppress()."

This reverts commit 550cb3a365dee4edfdd1563224d5304de2a57fda
because try/except performs better. 
django/contrib/auth/middleware.py