diff --git a/docs/source/conf.py b/docs/source/conf.py index 10b0238..f37239d 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -17,11 +17,13 @@ import shlex # https://read-the-docs.readthedocs.org/en/latest/faq.html#i-get-import-errors-on-libraries-that-depend-on-c-modules -#from mock import Mock as MagicMock - #py27 import -from unittest.mock import MagicMock +try: #py3 import - + from unittest.mock import MagicMock +except ImportError: + #py27 import + from mock import Mock as MagicMock + class Mock(MagickMock): @classmethod def __getattr__(cls, name): diff --git a/docs/source/index.rst.leo b/docs/source/index.rst.leo index ae89ce0..b1007c6 100644 --- a/docs/source/index.rst.leo +++ b/docs/source/index.rst.leo @@ -12,7 +12,7 @@ @persistence @data:@auto conf.py -@gnxs +@gnxs Apt - Read The Docs @@ -24,11 +24,11 @@ @path b:\code\apt\docs\source +gnx: maphew.20150613204824.3 +unl: conf declarations + gnx: maphew.20150613204824.2 -gnx: maphew.20150613204824.3 -unl: conf declarations -