Skip to content

Commit

Permalink
manual: clean up build and make compatible with python 3.7
Browse files Browse the repository at this point in the history
  • Loading branch information
sbourdeauducq committed Feb 26, 2019
1 parent 0d05d4b commit f65bcbc
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions doc/manual/conf.py
Expand Up @@ -15,9 +15,9 @@

import sys
import os
from unittest.mock import Mock

import sphinx_rtd_theme
from unittest.mock import MagicMock


# Hack-patch Sphinx so that ARTIQ-Python types are correctly printed
Expand All @@ -26,21 +26,14 @@
autodoc.repr = str


class Mock(MagicMock):
@classmethod
def __getattr__(cls, name):
if name == "_mock_methods":
return None
return Mock()


mock_modules = ["artiq.gui.moninj",
"artiq.gui.waitingspinnerwidget",
mock_modules = ["artiq.gui.waitingspinnerwidget",
"artiq.gui.flowlayout",
"artiq.compiler.module",
"artiq.compiler.embedding",
"quamash", "pyqtgraph", "matplotlib",
"numpy", "dateutil", "dateutil.parser", "prettytable", "PyQt5",
"h5py", "serial", "scipy", "scipy.interpolate", "asyncserial",
"llvmlite_artiq", "Levenshtein", "aiohttp"]
"llvmlite_artiq", "Levenshtein", "aiohttp", "pythonparser"]

for module in mock_modules:
sys.modules[module] = Mock()
Expand Down

0 comments on commit f65bcbc

Please sign in to comment.