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

Skip to content

Commit bd84a58

Browse files
committed
Fix 3k's sphinx-build.py so that the version detection works with 2.x and 3.x.
1 parent 04c420f commit bd84a58

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Doc/tools/sphinx-build.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@
1212
if __name__ == '__main__':
1313

1414
if sys.version_info[:3] < (2, 4, 0):
15-
print("""\
15+
sys.stderr.write("""\
1616
Error: Sphinx needs to be executed with Python 2.4 or newer (not 3.0 though).
1717
(If you run this from the Makefile, you can set the PYTHON variable
1818
to the path of an alternative interpreter executable, e.g.,
1919
``make html PYTHON=python2.5``).
20-
""", file=sys.stderr)
20+
""")
2121
sys.exit(1)
2222

2323
from sphinx import main

0 commit comments

Comments
 (0)