diff --git a/_unittests/ut_sphinxext/test_latex_builder.py b/_unittests/ut_sphinxext/test_latex_builder.py index f71de23f7..4150c049e 100644 --- a/_unittests/ut_sphinxext/test_latex_builder.py +++ b/_unittests/ut_sphinxext/test_latex_builder.py @@ -171,7 +171,8 @@ def test_latex_builder_sphinx_table(self): raise Exception(html) t1 = "a&b1" - if t1 not in html.replace("\n", ""): + t1b = "a&\\sphinxAtStartParb1" # sphinx 3.5 + if t1 not in html.replace("\n", "") and t1b not in html.replace("\n", ""): raise Exception(html) t1 = "\\begin{tabulary}{\\linewidth}[t]{|T|T|}" diff --git a/src/pyquickhelper/helpgen/sphinxm_convert_doc_sphinx_helper.py b/src/pyquickhelper/helpgen/sphinxm_convert_doc_sphinx_helper.py index 07e88e5f8..ce02117e3 100644 --- a/src/pyquickhelper/helpgen/sphinxm_convert_doc_sphinx_helper.py +++ b/src/pyquickhelper/helpgen/sphinxm_convert_doc_sphinx_helper.py @@ -158,9 +158,18 @@ def depart_only(self, node): # The program should not necessarily be here. pass + def visit_viewcode_anchor(self, node): + # Removed in sphinx 3.5 + pass + + def depart_viewcode_anchor(self, node): + # Removed in sphinx 3.5 + pass + def unknown_visit(self, node): # pragma: no cover - raise NotImplementedError("[_AdditionalVisitDepart] Unknown node: '{0}' in '{1}'".format( - node.__class__.__name__, self.__class__.__name__)) + raise NotImplementedError( + "[_AdditionalVisitDepart] Unknown node: '{0}' in '{1}'".format( + node.__class__.__name__, self.__class__.__name__)) class HTMLTranslatorWithCustomDirectives(_AdditionalVisitDepart, HTMLTranslator):