summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorJonathan Huot <JonathanHuot@users.noreply.github.com>2019-04-26 22:44:19 +0200
committerGitHub <noreply@github.com>2019-04-26 22:44:19 +0200
commitf1b8781e9f9dbce18ba67bbdf8f122109c5650d3 (patch)
treed197a477345dfeb34df0afe34e3640c815b033e1 /docs
parent91a2792da6e968fa72d871b2f0b95a8734f40546 (diff)
parent30321dd3c0ca784d3508a1970cf90d9f76835c79 (diff)
downloadoauthlib-f1b8781e9f9dbce18ba67bbdf8f122109c5650d3.tar.gz
Merge branch 'master' into oidc-hashes
Diffstat (limited to 'docs')
-rw-r--r--docs/error_reporting.rst6
-rw-r--r--docs/oauth1/server.rst2
-rw-r--r--docs/oauth2/server.rst3
3 files changed, 10 insertions, 1 deletions
diff --git a/docs/error_reporting.rst b/docs/error_reporting.rst
index 705f447..a80287b 100644
--- a/docs/error_reporting.rst
+++ b/docs/error_reporting.rst
@@ -10,16 +10,20 @@ case where that is not true please let us know!
When reporting bugs, especially when they are hard or impossible to reproduce,
it is useful to include logging output. You can enable logging for all
-oauthlib modules by adding a logger to the `oauthlib` namespace.
+oauthlib modules by adding a logger to the `oauthlib` namespace. You might also
+want to enable debugging mode to include request data in output.
.. code-block:: python
import logging
+ import oauthlib
import sys
+ oauthlib.set_debug(True)
log = logging.getLogger('oauthlib')
log.addHandler(logging.StreamHandler(sys.stdout))
log.setLevel(logging.DEBUG)
+
If you are using a library that builds upon OAuthLib please also enable the
logging for their modules, e.g. for `requests-oauthlib`
diff --git a/docs/oauth1/server.rst b/docs/oauth1/server.rst
index db469d2..2f30c65 100644
--- a/docs/oauth1/server.rst
+++ b/docs/oauth1/server.rst
@@ -441,7 +441,9 @@ Drop a line in our `Gitter OAuthLib community`_ or open a `GitHub issue`_ =)
If you run into issues it can be helpful to enable debug logging::
import logging
+ import oauthlib
import sys
+ oauthlib.set_debug(True)
log = logging.getLogger('oauthlib')
log.addHandler(logging.StreamHandler(sys.stdout))
log.setLevel(logging.DEBUG)
diff --git a/docs/oauth2/server.rst b/docs/oauth2/server.rst
index dad0aae..d9846c5 100644
--- a/docs/oauth2/server.rst
+++ b/docs/oauth2/server.rst
@@ -524,7 +524,10 @@ If you run into issues it can be helpful to enable debug logging.
.. code-block:: python
import logging
+ import oauthlib
import sys
+
+ oauthlib.set_debug(True)
log = logging.getLogger('oauthlib')
log.addHandler(logging.StreamHandler(sys.stdout))
log.setLevel(logging.DEBUG)