Skip to content

Commit 7d1f6dd

Browse files
Florian WilhelmFlorian Wilhelm
Florian Wilhelm
authored and
Florian Wilhelm
committed
Some more RTD specific changes
1 parent e1fa540 commit 7d1f6dd

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

docs/conf.py

+7
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,13 @@
1616
__location__ = os.path.join(os.getcwd(), os.path.dirname(
1717
inspect.getfile(inspect.currentframe())))
1818

19+
# Specific options for RTD build
20+
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
21+
22+
if on_rtd:
23+
import pip
24+
pip.main(['install', 'statsmodels'])
25+
1926
# If extensions (or modules to document with autodoc) are in another directory,
2027
# add these directories to sys.path here. If the directory is relative to the
2128
# documentation root, use os.path.abspath to make it absolute, like shown here.

requirements.txt

-1
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,3 @@ six
22
numpy
33
scipy
44
pandas
5-
statsmodels

setup.py

+5
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,11 @@
4747
# Add here console scripts like ['hello_world = pydse.module:function']
4848
CONSOLE_SCRIPTS = []
4949

50+
# temporarily redirect configuration directory
51+
# to prevent matplotlib import testing for
52+
# writeable directory outside of sandbox
53+
os.environ['MPLCONFIGDIR'] = "."
54+
5055
# Versioneer configuration
5156
versioneer.versionfile_source = os.path.join(MAIN_PACKAGE, '_version.py')
5257
versioneer.versionfile_build = os.path.join(MAIN_PACKAGE, '_version.py')

0 commit comments

Comments
 (0)