Docs fix (2) (#3265)

* Fix docs building

* And 1
This commit is contained in:
Michael H 2020-01-03 21:48:28 -05:00 committed by GitHub
parent 95e8d60729
commit 25999cea10
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,5 @@
import asyncio as _asyncio
import os as _os
import re as _re
import sys as _sys
import warnings as _warnings
@ -23,7 +24,7 @@ __all__ = [
"VersionInfo",
"_update_event_loop_policy",
]
if _sys.version_info < MIN_PYTHON_VERSION:
if _sys.version_info < MIN_PYTHON_VERSION and not _os.getenv("READTHEDOCS", False):
print(
f"Python {'.'.join(map(str, MIN_PYTHON_VERSION))} is required to run Red, but you have "
f"{_sys.version}! Please update Python."