From 49bfa1418a14c877419e895bf9c538f9e92d34d2 Mon Sep 17 00:00:00 2001 From: Ivana Kellyerova Date: Tue, 27 Jun 2023 12:03:39 +0200 Subject: [PATCH] random improvements --- docs-requirements.txt | 2 +- docs/conf.py | 16 +++++++++------- sentry_sdk/client.py | 4 ++-- tests/test_basics.py | 2 +- 4 files changed, 13 insertions(+), 11 deletions(-) diff --git a/docs-requirements.txt b/docs-requirements.txt index 2a98682baa..e1f694004b 100644 --- a/docs-requirements.txt +++ b/docs-requirements.txt @@ -1,4 +1,4 @@ +shibuya sphinx==7.0.1 -sphinx-rtd-theme sphinx-autodoc-typehints[type_comments]>=1.8.0 typing-extensions diff --git a/docs/conf.py b/docs/conf.py index 9dde301cfb..0420f7f5ef 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -2,16 +2,16 @@ import os import sys - import typing +from datetime import datetime # prevent circular imports import sphinx.builders.html import sphinx.builders.latex import sphinx.builders.texinfo import sphinx.builders.text -import sphinx.ext.autodoc -import urllib3.exceptions +import sphinx.ext.autodoc # noqa: F401 +import urllib3.exceptions # noqa: F401 typing.TYPE_CHECKING = True @@ -27,7 +27,7 @@ # -- Project information ----------------------------------------------------- project = "sentry-python" -copyright = "2019, Sentry Team and Contributors" +copyright = "2019-{}, Sentry Team and Contributors".format(datetime.now().year) author = "Sentry Team and Contributors" release = "1.26.0" @@ -87,13 +87,15 @@ on_rtd = os.environ.get("READTHEDOCS", None) == "True" -html_theme = "alabaster" +html_theme = "shibuya" # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the # documentation. # -# html_theme_options = {} +html_theme_options = { + "github_url": "https://github.com/getsentry/sentry-python", +} # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, @@ -167,7 +169,7 @@ "sentry-python Documentation", author, "sentry-python", - "One line description of project.", + "The official Sentry SDK for Python.", "Miscellaneous", ) ] diff --git a/sentry_sdk/client.py b/sentry_sdk/client.py index 8009f4f9fd..01d244679e 100644 --- a/sentry_sdk/client.py +++ b/sentry_sdk/client.py @@ -617,8 +617,8 @@ class Client(ClientConstructor, _Client): else: # Alias `get_options` for actual usage. Go through the lambda indirection # to throw PyCharm off of the weakly typed signature (it would otherwise - # discover both the weakly typed signature of `_init` and our faked `init` - # type). + # discover both the weakly typed signature of `_get_options` and our faked + # `get_options` types). get_options = (lambda: _get_options)() Client = (lambda: _Client)() diff --git a/tests/test_basics.py b/tests/test_basics.py index 751b0a617b..d1995509bb 100644 --- a/tests/test_basics.py +++ b/tests/test_basics.py @@ -256,7 +256,7 @@ def test_option_enable_tracing( assert options["traces_sample_rate"] == updated_traces_sample_rate -def test_breadcrumb_arguments(sentry_init, capture_events): +def test_breadcrumb_arguments(sentry_init): assert_hint = {"bar": 42} def before_breadcrumb(crumb, hint):