From 515fb53b60a5873c28eda41c2f6eedc6d678cd0f Mon Sep 17 00:00:00 2001 From: Jakob Lykke Andersen Date: Sat, 9 Jun 2018 17:12:43 +0200 Subject: [PATCH 01/20] C, render empty argument lists for macros. Fixes #2410 --- CHANGES | 1 + sphinx/domains/c.py | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index 7db859da4..73b5fdbf4 100644 --- a/CHANGES +++ b/CHANGES @@ -22,6 +22,7 @@ Bugs fixed * #5022: latex: crashed with docutils package provided by Debian/Ubuntu * #5009: latex: a label for table is vanished if table does not have a caption * #5048: crashed with numbered toctree +* #2410: C, render empty argument lists for macros. Testing -------- diff --git a/sphinx/domains/c.py b/sphinx/domains/c.py index f0c81db7b..ea44d6103 100644 --- a/sphinx/domains/c.py +++ b/sphinx/domains/c.py @@ -147,7 +147,8 @@ class CObject(ObjectDescription): fullname = name if not arglist: - if self.objtype == 'function': + if self.objtype == 'function' or \ + self.objtype == 'macro' and sig.rstrip().endswith('()'): # for functions, add an empty parameter list signode += addnodes.desc_parameterlist() if const: From b1e1fd08221be951e0f21b4b11067a7ed9de1931 Mon Sep 17 00:00:00 2001 From: Jakob Lykke Andersen Date: Sat, 9 Jun 2018 18:07:20 +0200 Subject: [PATCH 02/20] C++, fix lookup of full template specializations with no template arguments --- CHANGES | 1 + sphinx/domains/cpp.py | 3 +++ 2 files changed, 4 insertions(+) diff --git a/CHANGES b/CHANGES index 73b5fdbf4..33c406b71 100644 --- a/CHANGES +++ b/CHANGES @@ -23,6 +23,7 @@ Bugs fixed * #5009: latex: a label for table is vanished if table does not have a caption * #5048: crashed with numbered toctree * #2410: C, render empty argument lists for macros. +* C++, fix lookup of full template specializations with no template arguments. Testing -------- diff --git a/sphinx/domains/cpp.py b/sphinx/domains/cpp.py index f2505f881..11c400df2 100644 --- a/sphinx/domains/cpp.py +++ b/sphinx/domains/cpp.py @@ -3519,6 +3519,9 @@ class Symbol(object): # and params that are packs must in the args be the name expanded if len(templateParams.params) != len(templateArgs.args): return True + # having no template params and no arguments is also a specialization + if len(templateParams.params) == 0: + return True for i in range(len(templateParams.params)): param = templateParams.params[i] arg = templateArgs.args[i] From 6441853e66879fe8aaa8295504bf42769d9ab2f0 Mon Sep 17 00:00:00 2001 From: "Alan M. Carroll" Date: Thu, 22 Feb 2018 08:30:46 -0600 Subject: [PATCH 03/20] cpp domain: Fix assert when describing unreferenced symbol. --- sphinx/domains/cpp.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sphinx/domains/cpp.py b/sphinx/domains/cpp.py index 11c400df2..567562d0b 100644 --- a/sphinx/domains/cpp.py +++ b/sphinx/domains/cpp.py @@ -6239,7 +6239,7 @@ class CPPDomain(Domain): if target is None: return None parentKey = node.get("cpp:parent_key", None) - if parentKey is None: + if parentKey is None or len(parentKey) <= 0: return None rootSymbol = self.data['root_symbol'] From ac9f973c9be70c9f253a42939a73035be1e9e6aa Mon Sep 17 00:00:00 2001 From: Jakob Lykke Andersen Date: Sat, 9 Jun 2018 20:08:46 +0200 Subject: [PATCH 04/20] Update CHANGES --- CHANGES | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGES b/CHANGES index 33c406b71..9c48d472c 100644 --- a/CHANGES +++ b/CHANGES @@ -24,6 +24,8 @@ Bugs fixed * #5048: crashed with numbered toctree * #2410: C, render empty argument lists for macros. * C++, fix lookup of full template specializations with no template arguments. +* #4667: C++, fix assertion on missing references in global scope when using + intersphinx. Thanks to Alan M. Carroll. Testing -------- From 0edcae1ff875c64e7d011604df26fdb4a4dffca3 Mon Sep 17 00:00:00 2001 From: Takeshi KOMIYA Date: Sun, 10 Jun 2018 12:50:52 +0900 Subject: [PATCH 05/20] Fix #5019: autodoc: crashed by Form Feed Character --- CHANGES | 1 + sphinx/pycode/parser.py | 7 ++++++- tests/test_pycode_parser.py | 9 +++++++++ 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index 9c48d472c..db36f5d81 100644 --- a/CHANGES +++ b/CHANGES @@ -26,6 +26,7 @@ Bugs fixed * C++, fix lookup of full template specializations with no template arguments. * #4667: C++, fix assertion on missing references in global scope when using intersphinx. Thanks to Alan M. Carroll. +* #5019: autodoc: crashed by Form Feed Character Testing -------- diff --git a/sphinx/pycode/parser.py b/sphinx/pycode/parser.py index 5c4291d3d..40334f2e3 100644 --- a/sphinx/pycode/parser.py +++ b/sphinx/pycode/parser.py @@ -34,6 +34,11 @@ else: ASSIGN_NODES = (ast.Assign) +def filter_whitespace(code): + # type: (unicode) -> unicode + return code.replace('\f', ' ') # replace FF (form feed) with whitespace + + def get_assign_targets(node): # type: (ast.AST) -> List[ast.expr] """Get list of targets from Assign and AnnAssign node.""" @@ -466,7 +471,7 @@ class Parser(object): def __init__(self, code, encoding='utf-8'): # type: (unicode, unicode) -> None - self.code = code + self.code = filter_whitespace(code) self.encoding = encoding self.comments = {} # type: Dict[Tuple[unicode, unicode], unicode] self.deforders = {} # type: Dict[unicode, int] diff --git a/tests/test_pycode_parser.py b/tests/test_pycode_parser.py index 29363e17e..0875329a4 100644 --- a/tests/test_pycode_parser.py +++ b/tests/test_pycode_parser.py @@ -315,3 +315,12 @@ def test_decorators(): 'func3': ('def', 7, 9), 'Foo': ('class', 11, 15), 'Foo.method': ('def', 13, 15)} + + +def test_formfeed_char(): + source = ('class Foo:\n' + '\f\n' + ' attr = 1234 #: comment\n') + parser = Parser(source) + parser.parse() + assert parser.comments == {('Foo', 'attr'): 'comment'} From c15e2f3eff669f02540f66947b73639613965a08 Mon Sep 17 00:00:00 2001 From: Takeshi KOMIYA Date: Fri, 8 Jun 2018 22:35:14 +0900 Subject: [PATCH 06/20] Fix #5036: quickstart: Typing Ctrl-U clears the whole of line --- CHANGES | 1 + sphinx/cmd/quickstart.py | 14 ++++++++++---- sphinx/util/console.py | 18 +++++++++++++++--- 3 files changed, 26 insertions(+), 7 deletions(-) diff --git a/CHANGES b/CHANGES index 9c48d472c..6d81408a5 100644 --- a/CHANGES +++ b/CHANGES @@ -26,6 +26,7 @@ Bugs fixed * C++, fix lookup of full template specializations with no template arguments. * #4667: C++, fix assertion on missing references in global scope when using intersphinx. Thanks to Alan M. Carroll. +* #5036: quickstart: Typing Ctrl-U clears the whole of line Testing -------- diff --git a/sphinx/cmd/quickstart.py b/sphinx/cmd/quickstart.py index 68718eeaf..8b928b478 100644 --- a/sphinx/cmd/quickstart.py +++ b/sphinx/cmd/quickstart.py @@ -38,7 +38,7 @@ from six.moves.urllib.parse import quote as urlquote from sphinx import __display_version__, package_dir from sphinx.util import texescape from sphinx.util.console import ( # type: ignore - purple, bold, red, turquoise, nocolor, color_terminal + colorize, bold, red, turquoise, nocolor, color_terminal ) from sphinx.util.osutil import ensuredir, make_filename from sphinx.util.template import SphinxRenderer @@ -82,8 +82,14 @@ PROMPT_PREFIX = '> ' # function to get input from terminal -- overridden by the test suite def term_input(prompt): # type: (unicode) -> unicode - print(prompt, end='') - return input('') + if sys.platform == 'win32': + # Important: On windows, readline is not enabled by default. In these + # environment, escape sequences have been broken. To avoid the + # problem, quickstart uses ``print()`` to show prompt. + print(prompt, end='') + return input('') + else: + return input(prompt) class ValidationError(Exception): @@ -183,7 +189,7 @@ def do_prompt(text, default=None, validator=nonempty): prompt = prompt.encode('utf-8') except UnicodeEncodeError: prompt = prompt.encode('latin1') - prompt = purple(prompt) + prompt = colorize('purple', prompt, input_mode=True) x = term_input(prompt).strip() if default and not x: x = default diff --git a/sphinx/util/console.py b/sphinx/util/console.py index 7663feb1e..d62169adf 100644 --- a/sphinx/util/console.py +++ b/sphinx/util/console.py @@ -87,9 +87,21 @@ def coloron(): codes.update(_orig_codes) -def colorize(name, text): - # type: (str, unicode) -> unicode - return codes.get(name, '') + text + codes.get('reset', '') +def colorize(name, text, input_mode=False): + # type: (str, unicode, bool) -> unicode + def escseq(name): + # Wrap escape sequence with ``\1`` and ``\2`` to let readline know + # it is non-printable characters + # ref: https://tiswww.case.edu/php/chet/readline/readline.html + # + # Note: This hack does not work well in Windows (see #5059) + escape = codes.get(name, '') + if input_mode and escape and sys.platform != 'win32': + return '\1' + escape + '\2' + else: + return escape + + return escseq(name) + text + escseq('reset') def strip_colors(s): From fb5a4cbcc045fb6e4849ec587ab1ce3f5c5b06b2 Mon Sep 17 00:00:00 2001 From: Drew Risinger Date: Tue, 12 Jun 2018 23:54:35 -0400 Subject: [PATCH 07/20] Autodoc.rst typo: ommit->omit Fix typo in docs/ext/autodoc.rst. Changed "ommit"->"omit" --- doc/ext/autodoc.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/ext/autodoc.rst b/doc/ext/autodoc.rst index 09098f39c..dc45c6bc3 100644 --- a/doc/ext/autodoc.rst +++ b/doc/ext/autodoc.rst @@ -374,7 +374,7 @@ There are also new config values that you can set: This value contains a list of modules to be mocked up. This is useful when some external dependencies are not met at build time and break the building process. You may only specify the root package of the dependencies - themselves and ommit the sub-modules: + themselves and omit the sub-modules: .. code-block:: python From 6c4d6c3b940040a05d7a703643c032645f40e0ab Mon Sep 17 00:00:00 2001 From: Takeshi KOMIYA Date: Sat, 9 Jun 2018 23:05:31 +0900 Subject: [PATCH 08/20] Fix #5032: autodoc loses the first staticmethod parameter for old styled classes --- CHANGES | 1 + sphinx/util/inspect.py | 4 ++-- tests/test_util_inspect.py | 23 +++++++++++++++++++++++ 3 files changed, 26 insertions(+), 2 deletions(-) diff --git a/CHANGES b/CHANGES index db36f5d81..c5a5e6021 100644 --- a/CHANGES +++ b/CHANGES @@ -27,6 +27,7 @@ Bugs fixed * #4667: C++, fix assertion on missing references in global scope when using intersphinx. Thanks to Alan M. Carroll. * #5019: autodoc: crashed by Form Feed Character +* #5032: autodoc: loses the first staticmethod parameter for old styled classes Testing -------- diff --git a/sphinx/util/inspect.py b/sphinx/util/inspect.py index 72c3065bc..fbef01341 100644 --- a/sphinx/util/inspect.py +++ b/sphinx/util/inspect.py @@ -176,8 +176,8 @@ def isstaticmethod(obj, cls=None, name=None): elif cls and name: # trace __mro__ if the method is defined in parent class # - # .. note:: This only works with new style classes. - for basecls in getattr(cls, '__mro__', []): + # .. note:: This only works well with new style classes. + for basecls in getattr(cls, '__mro__', [cls]): meth = basecls.__dict__.get(name) if meth: if isinstance(meth, staticmethod): diff --git a/tests/test_util_inspect.py b/tests/test_util_inspect.py index 76f21a5e1..e18e21761 100644 --- a/tests/test_util_inspect.py +++ b/tests/test_util_inspect.py @@ -362,3 +362,26 @@ def test_dict_customtype(): description = inspect.object_description(dictionary) # Type is unsortable, just check that it does not crash assert ": 2" in description + + +def test_isstaticmethod(): + class Foo(): + @staticmethod + def method1(): + pass + + def method2(self): + pass + + class Bar(Foo): + pass + + assert inspect.isstaticmethod(Foo.method1, Foo, 'method1') is True + assert inspect.isstaticmethod(Foo.method2, Foo, 'method2') is False + + if sys.version_info < (3, 0): + assert inspect.isstaticmethod(Bar.method1, Bar, 'method1') is False + assert inspect.isstaticmethod(Bar.method2, Bar, 'method2') is False + else: + assert inspect.isstaticmethod(Bar.method1, Bar, 'method1') is True + assert inspect.isstaticmethod(Bar.method2, Bar, 'method2') is False From 5df7228cde0b81507f57a00cff3c11c0b2b7d37c Mon Sep 17 00:00:00 2001 From: dombre Date: Wed, 13 Jun 2018 15:32:41 +0200 Subject: [PATCH 09/20] Update intl.rst Fixes #5081 --- doc/intl.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/intl.rst b/doc/intl.rst index 43f620bd0..129665dde 100644 --- a/doc/intl.rst +++ b/doc/intl.rst @@ -123,14 +123,14 @@ This section describe an easy way to translate with sphinx-intl. .. code-block:: console - > set SPHINXOPTS=-D language='de' + > set SPHINXOPTS=-D language=de > .\make.bat html command line (for PowerShell): .. code-block:: console - > Set-Item env:SPHINXOPTS "-D language='de'" + > Set-Item env:SPHINXOPTS "-D language=de" > .\make.bat html From 34126021d9cdff90acd73131e9d7d7132c7f1eaa Mon Sep 17 00:00:00 2001 From: Takeshi KOMIYA Date: Wed, 13 Jun 2018 23:24:14 +0900 Subject: [PATCH 10/20] Close #3784: mathjax: Add :confval:`mathjax_options` --- CHANGES | 2 ++ doc/ext/math.rst | 10 ++++++++++ sphinx/ext/mathjax.py | 5 ++++- tests/test_ext_math.py | 12 ++++++++++++ 4 files changed, 28 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index c2c0bd45c..a4beb3c7d 100644 --- a/CHANGES +++ b/CHANGES @@ -137,6 +137,8 @@ Features added * html: Output ``canonical_url`` metadata if :confval:`html_baseurl` set (refs: #4193) * #5029: autosummary: expose ``inherited_members`` to template +* #3784: mathjax: Add :confval:`mathjax_options` to give options to script tag + for mathjax Bugs fixed ---------- diff --git a/doc/ext/math.rst b/doc/ext/math.rst index c00713a3d..c299b7bee 100644 --- a/doc/ext/math.rst +++ b/doc/ext/math.rst @@ -260,6 +260,16 @@ Sphinx. You can also give a full ``https://`` URL different from the CDN URL. +.. confval:: mathjax_options + + The options to script tag for mathjax. For example, you can set integrity + option with following setting:: + + mathjax_options = { + 'integrity': 'sha384-......', + } + + The default is empty (``{}``). :mod:`sphinx.ext.jsmath` -- Render math via JavaScript ------------------------------------------------------ diff --git a/sphinx/ext/mathjax.py b/sphinx/ext/mathjax.py index 8aeafefc7..0d73f3d3d 100644 --- a/sphinx/ext/mathjax.py +++ b/sphinx/ext/mathjax.py @@ -74,6 +74,8 @@ def builder_inited(app): 'mathjax extension to work') if app.builder.format == 'html': options = {'async': 'async'} + if app.config.mathjax_options: + options.update(app.config.mathjax_options) app.builder.add_js_file(app.config.mathjax_path, **options) # type: ignore @@ -88,7 +90,8 @@ def setup(app): # https://docs.mathjax.org/en/latest/start.html#secure-access-to-the-cdn app.add_config_value('mathjax_path', 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?' - 'config=TeX-AMS-MML_HTMLorMML', False) + 'config=TeX-AMS-MML_HTMLorMML', 'html') + app.add_config_value('mathjax_options', {}, 'html') app.add_config_value('mathjax_inline', [r'\(', r'\)'], 'html') app.add_config_value('mathjax_display', [r'\[', r'\]'], 'html') app.connect('builder-inited', builder_inited) diff --git a/tests/test_ext_math.py b/tests/test_ext_math.py index 47465f07e..99940977b 100644 --- a/tests/test_ext_math.py +++ b/tests/test_ext_math.py @@ -89,6 +89,18 @@ def test_imgmath_svg(app, status, warning): assert re.search(html, content, re.S) +@pytest.mark.sphinx('html', testroot='ext-math', + confoverrides={'extensions': ['sphinx.ext.mathjax'], + 'mathjax_options': {'integrity': 'sha384-0123456789'}}) +def test_mathjax_options(app, status, warning): + app.builder.build_all() + + content = (app.outdir / 'index.html').text() + assert ('' in content) + + @pytest.mark.sphinx('html', testroot='ext-math', confoverrides={'extensions': ['sphinx.ext.mathjax']}) def test_mathjax_align(app, status, warning): From 93060bbac2b2e48c3f1c61ca56fee40135ed4c6b Mon Sep 17 00:00:00 2001 From: Jonathan Bayless Date: Wed, 13 Jun 2018 11:47:24 -0500 Subject: [PATCH 11/20] Add PROS to Examples List --- EXAMPLES | 1 + 1 file changed, 1 insertion(+) diff --git a/EXAMPLES b/EXAMPLES index 98bab3987..fd2beaee4 100644 --- a/EXAMPLES +++ b/EXAMPLES @@ -218,6 +218,7 @@ Documentation using sphinx_rtd_theme * peewee: http://docs.peewee-orm.com/ * Phinx: http://docs.phinx.org/ * phpMyAdmin: https://docs.phpmyadmin.net/ +* PROS: https://pros.cs.purdue.edu/v5/ (customized) * Pweave: http://mpastell.com/pweave/ * PyPy: http://doc.pypy.org/ * python-sqlparse: https://sqlparse.readthedocs.io/ From 61ef928310686d3b78046627bcb3de139948a63f Mon Sep 17 00:00:00 2001 From: "Justin W. Flory" Date: Wed, 13 Jun 2018 12:12:49 -0500 Subject: [PATCH 12/20] Update Google style guide link (previous link deprecated) --- doc/ext/autodoc.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/ext/autodoc.rst b/doc/ext/autodoc.rst index 0bddba5c5..bf20f7ac4 100644 --- a/doc/ext/autodoc.rst +++ b/doc/ext/autodoc.rst @@ -41,7 +41,7 @@ you can also enable the :mod:`napoleon ` extension. docstrings to correct reStructuredText before :mod:`autodoc` processes them. .. _Google: - https://google.github.io/styleguide/pyguide.html#Comments + https://github.com/google/styleguide/blob/gh-pages/pyguide.md#38-comments-and-docstrings .. _NumPy: https://github.com/numpy/numpy/blob/master/doc/HOWTO_DOCUMENT.rst.txt From d66e663f28ee10e5510f8d921c944e4560615e53 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roy=20Wellington=20=E2=85=A3?= Date: Wed, 13 Jun 2018 11:25:21 -0700 Subject: [PATCH 13/20] Fix minor typo of "them" --- doc/extdev/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/extdev/index.rst b/doc/extdev/index.rst index 4e041066b..7aa6a7948 100644 --- a/doc/extdev/index.rst +++ b/doc/extdev/index.rst @@ -101,7 +101,7 @@ Deprecated APIs On developing Sphinx, we are always careful to the compatibility of our APIs. But, sometimes, the change of interface are needed for some reasons. In such -cases, we've marked thme as deprecated. And they are kept during the two +cases, we've marked them as deprecated. And they are kept during the two major versions (for more details, please see :ref:`deprecation-policy`). The following is a list of deprecated interface. From 503eb7f2fd8f385c650267a20f48b81c0d62f96a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roy=20Wellington=20=E2=85=A3?= Date: Wed, 13 Jun 2018 11:25:21 -0700 Subject: [PATCH 14/20] Fix minor typo of "them" --- doc/extdev/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/extdev/index.rst b/doc/extdev/index.rst index ace43fd71..69a1732f6 100644 --- a/doc/extdev/index.rst +++ b/doc/extdev/index.rst @@ -92,7 +92,7 @@ Deprecated APIs On developing Sphinx, we are always careful to the compatibility of our APIs. But, sometimes, the change of interface are needed for some reasons. In such -cases, we've marked thme as deprecated. And they are kept during the two +cases, we've marked them as deprecated. And they are kept during the two major versions (for more details, please see :ref:`deprecation-policy`). The following is a list of deprecated interface. From b1af9f085045762ca9fea4a37be8a0d98865b168 Mon Sep 17 00:00:00 2001 From: rneubert <32850878+rneubert@users.noreply.github.com> Date: Thu, 14 Jun 2018 17:59:55 -0700 Subject: [PATCH 15/20] Fix typo in error message --- sphinx/config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sphinx/config.py b/sphinx/config.py index 4ad09c08b..c5f44e57c 100644 --- a/sphinx/config.py +++ b/sphinx/config.py @@ -365,7 +365,7 @@ def eval_config_file(filename, tags): "called sys.exit()") raise ConfigError(msg) except Exception: - msg = __("There is a programable error in your configuration file:\n\n%s") + msg = __("There is a programmable error in your configuration file:\n\n%s") raise ConfigError(msg % traceback.format_exc()) return namespace From 4be0941dd625c09bdfabf1cfb57f8b342ac97303 Mon Sep 17 00:00:00 2001 From: Takeshi KOMIYA Date: Sat, 16 Jun 2018 19:19:55 +0900 Subject: [PATCH 16/20] Update CHANGES (see #5000) --- CHANGES | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index 2c4374abe..3e154d2f7 100644 --- a/CHANGES +++ b/CHANGES @@ -34,7 +34,7 @@ Incompatible changes * #1857: latex: :confval:`latex_show_pagerefs` does not add pagerefs for citations * #4648: latex: Now "rubric" elements are rendered as unnumbered section title -* #4983: html: The URL for the productionlist has been changed +* #4983: html: The anchor for productionlist tokens has been changed * Modifying a template variable ``script_files`` in templates is allowed now. Please use ``app.add_js_file()`` instead. From 422e8bbc6fd279bc949417eb63077f944054f535 Mon Sep 17 00:00:00 2001 From: cmhughes Date: Sat, 16 Jun 2018 15:48:04 +0100 Subject: [PATCH 17/20] added latexindent.pl to list of examples --- EXAMPLES | 1 + 1 file changed, 1 insertion(+) diff --git a/EXAMPLES b/EXAMPLES index ee9d4a128..94aade9bc 100644 --- a/EXAMPLES +++ b/EXAMPLES @@ -195,6 +195,7 @@ Documentation using sphinx_rtd_theme * Julia: https://julia.readthedocs.io/ * Jupyter Notebook: https://jupyter-notebook.readthedocs.io/ * Lasagne: https://lasagne.readthedocs.io/ +* latexindent.pl: https://latexindentpl.readthedocs.io/ * Linguistica: https://linguistica-uchicago.github.io/lxa5/ * Linux kernel: https://www.kernel.org/doc/html/latest/index.html * MathJax: https://docs.mathjax.org/ From 26cbd6956813e57da0d73ee2c53bcc963d35e7a6 Mon Sep 17 00:00:00 2001 From: Takeshi KOMIYA Date: Sun, 17 Jun 2018 14:13:32 +0900 Subject: [PATCH 18/20] Fix #5100: Fix HTML search has been broken --- sphinx/themes/basic/search.html | 4 ++-- sphinx/themes/bizstyle/layout.html | 4 ++-- sphinx/themes/classic/layout.html | 4 ++-- sphinx/themes/scrolls/layout.html | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/sphinx/themes/basic/search.html b/sphinx/themes/basic/search.html index 6264d0414..57030d83a 100644 --- a/sphinx/themes/basic/search.html +++ b/sphinx/themes/basic/search.html @@ -9,10 +9,10 @@ #} {%- extends "layout.html" %} {% set title = _('Search') %} -{%- macro script() %} +{%- block scripts %} {{ super() }} -{%- endmacro %} +{%- endblock %} {% block extrahead %} -{%- endmacro %} +{%- endblock %} {# put the sidebar before the body #} {% block sidebar1 %}{{ sidebar() }}{% endblock %} diff --git a/sphinx/themes/classic/layout.html b/sphinx/themes/classic/layout.html index 3ba9ad57f..8042e3f7e 100644 --- a/sphinx/themes/classic/layout.html +++ b/sphinx/themes/classic/layout.html @@ -10,8 +10,8 @@ {%- extends "basic/layout.html" %} {% if theme_collapsiblesidebar|tobool %} -{%- macro script() %} +{%- block scripts %} {{ super() }} -{%- endmacro %} +{%- endblock %} {% endif %} diff --git a/sphinx/themes/scrolls/layout.html b/sphinx/themes/scrolls/layout.html index 1b58a6d46..7bb7b19e3 100644 --- a/sphinx/themes/scrolls/layout.html +++ b/sphinx/themes/scrolls/layout.html @@ -13,10 +13,10 @@ {{ super() }} {%- endblock %} -{%- macro script() %} +{%- block scripts %} {{ super() }} -{%- endmacro %} +{%- endblock %} {# do not display relbars #} {% block relbar1 %}{% endblock %} {% block relbar2 %}{% endblock %} From 3d6c7d147d535a85facccb2c13c8ccc3fdfa2d27 Mon Sep 17 00:00:00 2001 From: shimizukawa Date: Sun, 17 Jun 2018 15:39:32 +0900 Subject: [PATCH 19/20] update CHANGES. refs #5083 --- CHANGES | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGES b/CHANGES index 7a9b05236..75f7623a0 100644 --- a/CHANGES +++ b/CHANGES @@ -157,6 +157,11 @@ Features removed * ``sphinx.ext.pngmath`` extension +Documentation +------------- + +* #5083: Fix wrong make.bat option for internationalization. + Release 1.7.6 (in development) ============================== From cff11467756468dae045bc82d0d59cf04bbe8570 Mon Sep 17 00:00:00 2001 From: Jakob Lykke Andersen Date: Sun, 17 Jun 2018 09:57:52 +0200 Subject: [PATCH 20/20] Customizable Python interpreter in doc/Makefile Fix after previous stray edit. --- doc/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/Makefile b/doc/Makefile index 293ccca2e..4d2067071 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -1,9 +1,10 @@ # Makefile for Sphinx documentation # +PYTHON ?= python # You can set these variables from the command line. SPHINXOPTS = -SPHINXBUILD = python3 ../sphinx/cmd/build.py +SPHINXBUILD = $(PYTHON) ../sphinx/cmd/build.py SPHINXPROJ = sphinx SOURCEDIR = . BUILDDIR = _build