Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 2f27755

Browse files
committed
Get rid of UserWarnings when running Sphinx from tools dir.
1 parent 7cb1319 commit 2f27755

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

Doc/tools/sphinx-build.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,15 @@
33
Sphinx - Python documentation toolchain
44
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
55
6-
:copyright: 2007 by Georg Brandl.
6+
:copyright: 2007-2010 by Georg Brandl.
77
:license: Python license.
88
"""
99

1010
import sys
11+
import warnings
12+
13+
# Get rid of UserWarnings reported by pkg_resources.
14+
warnings.filterwarnings('ignore', category=UserWarning, module='jinja2')
1115

1216
if __name__ == '__main__':
1317

0 commit comments

Comments
 (0)