summaryrefslogtreecommitdiff
path: root/sphinx/ext/graphviz.py
diff options
context:
space:
mode:
Diffstat (limited to 'sphinx/ext/graphviz.py')
-rw-r--r--sphinx/ext/graphviz.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/sphinx/ext/graphviz.py b/sphinx/ext/graphviz.py
index f0ffcf3ef..3532377b1 100644
--- a/sphinx/ext/graphviz.py
+++ b/sphinx/ext/graphviz.py
@@ -145,7 +145,7 @@ class Graphviz(SphinxDirective):
rel_filename, filename = self.env.relfn2path(argument)
self.env.note_dependency(rel_filename)
try:
- with open(filename, encoding='utf-8') as fp: # type: ignore
+ with open(filename, encoding='utf-8') as fp:
dotcode = fp.read()
except (IOError, OSError):
return [document.reporter.warning(
@@ -310,7 +310,7 @@ def render_dot_html(self, node, code, options, prefix='graphviz',
self.body.append('<p class="warning">%s</p>' % alt)
self.body.append('</object></div>\n')
else:
- with open(outfn + '.map', encoding='utf-8') as mapfile: # type: ignore
+ with open(outfn + '.map', encoding='utf-8') as mapfile:
imgmap = ClickableMapDefinition(outfn + '.map', mapfile.read(), dot=code)
if imgmap.clickable:
# has a map