<commit_before>===============
Base Exceptions
===============

.. module:: oauth2_consumer.exceptions.base

.. exception:: AccessDenied
   
   The :exc:`AccessDenied` exception is raised during the approval step of the authorization process if the user rejects the clients request for permission.  The OAuth ``error`` for this exception is ``access_denied``.

.. exception:: InvalidClient

.. exception:: InvalidGrant

.. exception:: InvalidRequest
   
   The :exc:`InvalidRequest` exception is raised because a parameter did not pass validation or was not provided.  The OAuth ``error`` for this exception is ``invalid_request``.
   
   This can be raised during the initial authorization request because:
   
   - A required parameter was not provideed.
   - A supplied parameter failed its verification check.
   
   This exception is not intended to be redirected to the client during the authorization stage.

.. exception:: InvalidScope
   
   The :exc:`InvalidScope` exception is raised because the scope that was provided for the request does not pass validation or was not provided.  The OAuth ``error`` for this exception is ``invalid_scope``.

.. exception:: UnsupportedGrantType

.. exception:: UnsupportedResponseType
   
   The :exc:`UnsupportedResponseType` exception is raised during the initial authorization step because the requested ``response_type`` was not supported.  The OAuth ``error`` for this exception is ``unsupported_response_type``.<commit_msg>Added more information about two base exceptions<commit_after>===============
Base Exceptions
===============

.. module:: oauth2_consumer.exceptions.base

.. exception:: AccessDenied
   
   The :exc:`AccessDenied` exception is raised during the approval step of the authorization process if the user rejects the clients request for permission.  The OAuth ``error`` for this exception is ``access_denied``.

.. exception:: InvalidClient
   
   The :exc:`InvalidClient` exception is raised if a client was provided but had an error.

.. exception:: InvalidGrant

.. exception:: InvalidRequest
   
   The :exc:`InvalidRequest` exception is raised because a parameter did not pass validation or was not provided.  The OAuth ``error`` for this exception is ``invalid_request``.
   
   This can be raised during the initial authorization request because:
   
   - A required parameter was not provideed.
   - A supplied parameter failed its verification check.
   
   This exception is not intended to be redirected to the client during the authorization stage.

.. exception:: InvalidScope
   
   The :exc:`InvalidScope` exception is raised because the scope that was provided for the request does not pass validation or was not provided.  The OAuth ``error`` for this exception is ``invalid_scope``.

.. exception:: UnsupportedGrantType
   
   The :exc:`UnsupportedGrantType` exception is raised during the exchanging of tokens if the specified grant type is in the list of suppported grant types, or was not provided.

.. exception:: UnsupportedResponseType
   
   The :exc:`UnsupportedResponseType` exception is raised during the initial authorization step because the requested ``response_type`` was not supported.  The OAuth ``error`` for this exception is ``unsupported_response_type``.
{'fraction_non_alphanumeric': 0.08486519607843138, 'fraction_numerical': 0.0006127450980392157, 'mean_word_length': 4.387788778877888, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '955434', 'n_tokens_mistral': 775, 'n_tokens_neox': 753, 'n_words': 378}