mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Drop typing.TYPE_CHECKING
This commit is contained in:
parent
5734d8ad02
commit
f9ae69d9b0
@ -10,12 +10,12 @@
|
||||
"""
|
||||
|
||||
import warnings
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
from sphinx.deprecation import RemovedInSphinx20Warning
|
||||
from sphinx.ext.apidoc import main as _main
|
||||
|
||||
if TYPE_CHECKING:
|
||||
if False:
|
||||
# For type annotation
|
||||
from typing import Any # NOQA
|
||||
from sphinx.application import Sphinx # NOQA
|
||||
|
||||
|
@ -24,15 +24,14 @@
|
||||
:license: BSD, see LICENSE for details.
|
||||
"""
|
||||
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
from docutils import nodes, utils
|
||||
from six import iteritems
|
||||
|
||||
import sphinx
|
||||
from sphinx.util.nodes import split_explicit_title
|
||||
|
||||
if TYPE_CHECKING:
|
||||
if False:
|
||||
# For type annotation
|
||||
from typing import Any, Dict, List, Tuple # NOQA
|
||||
from docutils.parsers.rst.states import Inliner # NOQA
|
||||
from sphinx.application import Sphinx # NOQA
|
||||
|
@ -10,11 +10,11 @@
|
||||
"""
|
||||
|
||||
import os
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
import sphinx
|
||||
|
||||
if TYPE_CHECKING:
|
||||
if False:
|
||||
# For type annotation
|
||||
from typing import Any, Dict # NOQA
|
||||
from sphinx.application import Sphinx # NOQA
|
||||
from sphinx.environment import BuildEnvironment # NOQA
|
||||
|
@ -10,8 +10,6 @@
|
||||
:license: BSD, see LICENSE for details.
|
||||
"""
|
||||
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
from docutils import nodes
|
||||
|
||||
import sphinx
|
||||
@ -20,8 +18,8 @@ from sphinx.ext.mathbase import get_node_equation_number
|
||||
from sphinx.ext.mathbase import setup_math as mathbase_setup
|
||||
from sphinx.locale import _
|
||||
|
||||
|
||||
if TYPE_CHECKING:
|
||||
if False:
|
||||
# For type annotation
|
||||
from typing import Any, Dict # NOQA
|
||||
from sphinx.application import Sphinx # NOQA
|
||||
|
||||
|
@ -11,8 +11,6 @@
|
||||
:license: BSD, see LICENSE for details.
|
||||
"""
|
||||
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
from docutils import nodes
|
||||
|
||||
import sphinx
|
||||
@ -21,7 +19,8 @@ from sphinx.ext.mathbase import get_node_equation_number
|
||||
from sphinx.ext.mathbase import setup_math as mathbase_setup
|
||||
from sphinx.locale import _
|
||||
|
||||
if TYPE_CHECKING:
|
||||
if False:
|
||||
# For type annotation
|
||||
from typing import Any, Dict # NOQA
|
||||
from sphinx.application import Sphinx # NOQA
|
||||
|
||||
|
@ -10,12 +10,12 @@
|
||||
"""
|
||||
|
||||
import warnings
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
from sphinx.cmd.quickstart import main as _main
|
||||
from sphinx.deprecation import RemovedInSphinx20Warning
|
||||
|
||||
if TYPE_CHECKING:
|
||||
if False:
|
||||
# For type annotation
|
||||
from typing import Any # NOQA
|
||||
|
||||
|
||||
|
@ -10,11 +10,11 @@ import os
|
||||
import shutil
|
||||
import sys
|
||||
from io import open
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
from six import PY2, text_type
|
||||
|
||||
if TYPE_CHECKING:
|
||||
if False:
|
||||
# For type annotation
|
||||
from typing import Any, Callable, IO, List # NOQA
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user