From 64b54e668acb42d13dfa77563ec585e30e0b2452 Mon Sep 17 00:00:00 2001 From: Seth House Date: Mon, 28 Sep 2015 13:51:31 -0600 Subject: [PATCH] Add fake pymongo version attribute for the docs This bypasses the following traceback when building the docs. File "/Users/shouse/src/salt/salt/salt/returners/mongo_future_return.py", line 72, in version = '.'.join(version.split('.')[:2]) TypeError: 'Mock' object has no attribute '__getitem__' --- doc/conf.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/conf.py b/doc/conf.py index 117b7d4fe9..e2a2a09b6d 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -123,8 +123,9 @@ MOCK_MODULES = [ for mod_name in MOCK_MODULES: sys.modules[mod_name] = Mock() -# Define a fake version attribute for libcloud so docs build as supposed +# Define a fake version attribute for the following libs. sys.modules['libcloud'].__version__ = '0.0.0' +sys.modules['pymongo'].version = '0.0.0' # -- Add paths to PYTHONPATH ---------------------------------------------------