diff options
author | danieleades <33452915+danieleades@users.noreply.github.com> | 2022-07-18 22:08:16 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-18 22:08:16 +0100 |
commit | a504ac6100a577cbda1bedf80d69636603ee287c (patch) | |
tree | 0aa79585440486bdb109f7238f8f5c992dad0d99 /sphinx/ext/graphviz.py | |
parent | a340427ba4d208193d539cb7e8401be23d75547e (diff) | |
download | sphinx-git-a504ac6100a577cbda1bedf80d69636603ee287c.tar.gz |
Improve static typing strictness (#10569)
Diffstat (limited to 'sphinx/ext/graphviz.py')
-rw-r--r-- | sphinx/ext/graphviz.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sphinx/ext/graphviz.py b/sphinx/ext/graphviz.py index b4a69a0f2..0459c4a96 100644 --- a/sphinx/ext/graphviz.py +++ b/sphinx/ext/graphviz.py @@ -6,7 +6,7 @@ import re import subprocess from os import path from subprocess import PIPE, CalledProcessError -from typing import Any, Dict, List, Tuple +from typing import Any, Dict, List, Optional, Tuple from docutils import nodes from docutils.nodes import Node @@ -210,7 +210,7 @@ class GraphvizSimple(SphinxDirective): def render_dot(self: SphinxTranslator, code: str, options: Dict, format: str, - prefix: str = 'graphviz', filename: str = None) -> Tuple[str, str]: + prefix: str = 'graphviz', filename: Optional[str] = None) -> Tuple[str, str]: """Render graphviz code into a PNG or PDF output file.""" graphviz_dot = options.get('graphviz_dot', self.builder.config.graphviz_dot) hashkey = (code + str(options) + str(graphviz_dot) + |