]> git.notmuchmail.org Git - notmuch/commit
python: fix documentation build with python 3.7
authorJani Nikula <jani.nikula@intel.com>
Mon, 11 Feb 2019 18:22:35 +0000 (20:22 +0200)
committerDavid Bremner <david@tethera.net>
Sat, 16 Feb 2019 12:42:13 +0000 (08:42 -0400)
commit510dc8c8377e4fef1e96c13c2ea3f25f4b51c889
tree2cce8fa3a7b711a2d5c97799e0ed45daa273a6f3
parent3c752b855f900f5251df9997514b4d27d9f38e83
python: fix documentation build with python 3.7

The simplistic mocking in conf.py falls short on python 3.7. Just use
unittest.mock instead.

Fixes:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/sphinx/config.py", line 368, in eval_config_file
    execfile_(filename, namespace)
  File "/usr/lib/python3/dist-packages/sphinx/util/pycompat.py", line 150, in execfile_
    exec_(code, _globals)
  File "/path/to/notmuch/bindings/python/docs/source/conf.py", line 39, in <module>
    from notmuch import __VERSION__,__AUTHOR__
  File "/path/to/notmuch/bindings/python/notmuch/__init__.py", line 54, in <module>
    from .database import Database
  File "/path/to/notmuch/bindings/python/notmuch/database.py", line 25, in <module>
    from .globals import (
  File "/path/to/notmuch/bindings/python/notmuch/globals.py", line 48, in <module>
    class NotmuchDatabaseS(Structure):
TypeError: __mro_entries__ must return a tuple
bindings/python/docs/source/conf.py