Skip to content

Commit

Permalink
better document None as return value of view()
Browse files Browse the repository at this point in the history
- fix #106
  • Loading branch information
xflr6 committed Sep 11, 2020
1 parent 21bf42a commit 326063b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions graphviz/backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,10 @@ def view(filepath, quiet=False):
(ineffective on Windows).
Raises:
RuntimeError: If the current platform is not supported.
Note:
There is no option to wait for the application to close, and no way
to retrieve the application's exit status.
"""
try:
view_func = getattr(view, PLATFORM)
Expand Down
4 changes: 4 additions & 0 deletions graphviz/files.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,10 @@ def view(self, filename=None, directory=None, cleanup=False,
RuntimeError: If opening the viewer is not supported.
Short-cut method for calling :meth:`.render` with ``view=True``.
Note:
There is no option to wait for the application to close, and no way
to retrieve the application's exit status.
"""
return self.render(filename=filename, directory=directory,
view=True, cleanup=cleanup,
Expand Down

0 comments on commit 326063b

Please sign in to comment.