From 919dafe89cd046ba8beba864152376da697aa5e9 Mon Sep 17 00:00:00 2001 From: Shengyu Zhang Date: Fri, 18 Oct 2024 15:27:23 +0800 Subject: [PATCH] update --- src/sphinxnotes/fasthtml/__init__.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/sphinxnotes/fasthtml/__init__.py b/src/sphinxnotes/fasthtml/__init__.py index c3c514d..524241f 100644 --- a/src/sphinxnotes/fasthtml/__init__.py +++ b/src/sphinxnotes/fasthtml/__init__.py @@ -10,6 +10,7 @@ TODO: - [ ] config-able. +- [ ] copy files? such as download-able files. """ @@ -27,7 +28,6 @@ if TYPE_CHECKING: from sphinx.application import Sphinx - from sphinx.builders import Builder logger = logging.getLogger(__name__) @@ -109,7 +109,7 @@ def _restore_config(self) -> None: def _dummy_check_consistency() -> None: - """Used to overwrte :meth:`BuildEnvironment.check_consistency`, for + """Used to overwrte :meth:`BuildEnvironment.check_consistency`, for skipping the consistency checking of Sphinx. """ raise SkipProgressMessage @@ -119,7 +119,9 @@ def _on_builder_inited(app: Sphinx): if not isinstance(app.builder, FastHTMLBuilder): # Restore env.check_consistency. if app.env.check_consistency == _dummy_check_consistency: - app.env.check_consistency = functools.partial(BuildEnvironment.check_consistency, app.env) + app.env.check_consistency = functools.partial( + BuildEnvironment.check_consistency, app.env + ) return app.builder._overwrite_config()