diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index fb479fcc..de5da248 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,14 +15,14 @@ repos: files: (README\.rst)|(CHANGELOG\.rst) - repo: https://github.com/PyCQA/isort/ - rev: 5.12.0 + rev: 5.13.2 hooks: - id: isort additional_dependencies: - toml - repo: https://github.com/psf/black - rev: 23.11.0 + rev: 24.1a1 hooks: - id: black @@ -39,7 +39,7 @@ repos: - id: flake8 - repo: https://github.com/pre-commit/mirrors-prettier - rev: v3.1.0 + rev: v4.0.0-alpha.8 hooks: - id: prettier types_or: [css, scss, javascript] diff --git a/src/documenteer/conf/_toml.py b/src/documenteer/conf/_toml.py index ba75b405..91c6b9e7 100644 --- a/src/documenteer/conf/_toml.py +++ b/src/documenteer/conf/_toml.py @@ -545,9 +545,9 @@ def set_edit_on_github( html_theme_options["use_edit_page_button"] = True html_context["github_user"] = github_owner html_context["github_repo"] = github_repo - html_context[ - "github_version" - ] = self.conf.project.github_default_branch + html_context["github_version"] = ( + self.conf.project.github_default_branch + ) html_context["doc_path"] = doc_dir @property diff --git a/src/documenteer/conf/guide.py b/src/documenteer/conf/guide.py index 83e71cb8..b2e1407b 100644 --- a/src/documenteer/conf/guide.py +++ b/src/documenteer/conf/guide.py @@ -427,9 +427,9 @@ } else: documenteer_openapi_generator = None - documenteer_openapi_path: Optional[ - str - ] = _conf.conf.project.openapi.openapi_path + documenteer_openapi_path: Optional[str] = ( + _conf.conf.project.openapi.openapi_path + ) redoc: Optional[List[Any]] = [ { "name": "REST API", @@ -439,9 +439,9 @@ "opts": {"hide-hostname": True}, } ] - redoc_uri: Optional[ - str - ] = "https://cdn.jsdelivr.net/npm/redoc@next/bundles/redoc.standalone.js" + redoc_uri: Optional[str] = ( + "https://cdn.jsdelivr.net/npm/redoc@next/bundles/redoc.standalone.js" + ) else: documenteer_openapi_generator = None documenteer_openapi_path = None diff --git a/src/documenteer/conf/technote.py b/src/documenteer/conf/technote.py index e32dfa3c..af9ebd6b 100644 --- a/src/documenteer/conf/technote.py +++ b/src/documenteer/conf/technote.py @@ -86,6 +86,6 @@ _id = T.metadata.id # noqa: F405 if _id is not None: - html_context[ # noqa: F405 - "editions_url" - ] = f"https://{_id.lower()}.lsst.io/v/" + html_context["editions_url"] = ( # noqa: F405 + f"https://{_id.lower()}.lsst.io/v/" + ) diff --git a/tests/ext/jira_test.py b/tests/ext/jira_test.py index 3b1220bd..e532e36c 100644 --- a/tests/ext/jira_test.py +++ b/tests/ext/jira_test.py @@ -4,7 +4,6 @@ for licensing information. """ - from shutil import rmtree from tempfile import mkdtemp diff --git a/tests/ext/lsstdocushare_test.py b/tests/ext/lsstdocushare_test.py index 83b24918..34553cf2 100644 --- a/tests/ext/lsstdocushare_test.py +++ b/tests/ext/lsstdocushare_test.py @@ -1,6 +1,5 @@ """Tests for `documenteer.ext.lsstdocushare`.""" - from shutil import rmtree from tempfile import mkdtemp diff --git a/tests/ext/mockcoderefs_test.py b/tests/ext/mockcoderefs_test.py index 66b527e3..8d831d61 100644 --- a/tests/ext/mockcoderefs_test.py +++ b/tests/ext/mockcoderefs_test.py @@ -1,6 +1,5 @@ """Tests for documenteer.ext.mockcoderefs.""" - from shutil import rmtree from tempfile import mkdtemp