Commit Graph

1095 Commits

Author SHA1 Message Date
Takeshi KOMIYA
6611140c76 Merge branch '4.x' into HEAD 2022-01-15 19:46:45 +09:00
Jean Abou Samra
0269bec1ed In translated docs, sort glossaries by translated terms
This is done by moving the sorting from the glossary directive to a
transform operating after the i18n transform.

Closes #9827
2022-01-12 16:47:40 +01:00
Takeshi KOMIYA
6f707a0944 Merge branch '4.x' 2022-01-02 17:24:12 +09:00
Takeshi KOMIYA
e434dd6998 Merge pull request #10042 from tk0miya/9820_distutils
refactor: Reduce usages of distutils (refs: #9820)
2022-01-02 12:08:49 +09:00
Takeshi KOMIYA
e1c090d9f7 Merge pull request #10034 from tk0miya/10027_autodoc_typehints_format_for_bases
Fix #10027: autodoc_typehints_format does not work with :show-inheritance:
2022-01-02 11:39:22 +09:00
Takeshi KOMIYA
0ba202009d refactor: Reduce usages of distutils (refs: #9820)
distutils module is now deprecated and will be removed since Python
3.12.  So this reduces the usages of the module.
2022-01-01 21:38:56 +09:00
Takeshi KOMIYA
ce8039db1f Merge branch '4.x' 2022-01-01 20:04:19 +09:00
Takeshi KOMIYA
b84771dcd2 A happy new year! 2022-01-01 18:45:03 +09:00
Takeshi KOMIYA
3fc98a2b3d Fix #10027: autodoc_typehints_format does not work with :show-inheritance: 2022-01-01 18:06:57 +09:00
jfbu
4235195e77 Fix a spelling typo in tests (s/änhlich/ähnlich) 2021-12-22 12:44:28 +01:00
Christian Roth
10023da895 linkcheck: Exclude links from matched documents 2021-12-08 10:01:45 +01:00
Takeshi KOMIYA
e8e45a3678 Merge pull request #9905 from tk0miya/9883_ismock
Fix #9883: autodoc: doccomment for the alias to mocked object was ignored
2021-11-30 01:37:41 +09:00
Takeshi KOMIYA
74d912133a Merge pull request #9800 from hoefling/extlinks/replacements-check
Proposal: check if hardcoded URLs can be replaced with extlinks
2021-11-29 09:36:55 +09:00
Takeshi KOMIYA
f88ac53e51 Fix #9883: autodoc: doccomment for the alias to mocked object was ignored 2021-11-29 02:06:16 +09:00
Takeshi KOMIYA
15d834e4d8 Merge pull request #9831 from Yoshanuikabundi/autosummary___all__
Allow autosummary to respect __all__
2021-11-26 02:15:43 +09:00
Takeshi KOMIYA
fb92547b91 Fix #9866: autodoc: doccoment for the imported class was ignored
Autodoc tried to scan doccomment on the module where the class defined.
But it failed to get it if the class is imported from other module.

This analyzes the target module to obtain the doccomment.
2021-11-21 18:50:54 +09:00
Josh Mitchell
ad0071ddb7 #2021: Allow autosummary to respect __all__ 2021-11-15 13:16:33 +11:00
oleg.hoefling
8356260554 extlinks: replacement suggestions for hardcoded links
Signed-off-by: oleg.hoefling <oleg.hoefling@gmail.com>
2021-11-12 09:38:59 +01:00
Takeshi KOMIYA
b8844eb339 Fix #9781: autodoc_preserve_defaults does not support hexadecimal 2021-10-31 01:11:56 +09:00
Takeshi KOMIYA
b778ee806e Fix #9752: autodoc: Failed to detect type annotation for slots attribute 2021-10-23 14:59:36 +09:00
Takeshi KOMIYA
d288907fd1 Merge branch '4.x' into 9607_incorrect_orig_bases 2021-09-27 02:21:14 +09:00
Takeshi KOMIYA
d75e3171cd Merge pull request #9670 from jonppe/fix-download-file-with-special-characters
Fix download file with special characters
2021-09-25 14:38:48 +09:00
Johannes Aalto
fa3b334ed0 Add test for encoding local file links with special characters
Add test to make sure Sphinx uses proper URL encoding for
special characters in file names.

Use test_html_download() since it test_html5_output() doesn't
quite seem to have easy pattern to verify the contents of href
attribute.

Issue #3097

Signed-off-by: Johannes Aalto <ext-johannes.aalto@vaisala.com>
2021-09-24 20:34:09 +03:00
Latosha Maltba
cf9b5b5be9 Add tests for :dedent: option of code-block directive 2021-09-21 09:19:53 +00:00
Takeshi KOMIYA
10b7f0e252 Fix #9607: autodoc: Incorrect base class detection
In case of the descendants of generic class, the value of
obj.__orig_bases__ is incorrect because it returns original base
arguments for the child of the generic class instead of the target
class itself.

This uses obj.__dict__ to get the correct __orig_bases__ information.
2021-09-20 13:20:26 +09:00
Takeshi KOMIYA
ccfca458ea Close #9639: autodoc: Support asynchronous generator functions 2021-09-17 02:20:40 +09:00
Christian Clauss
86583c578c Fix typos discovered by codespell 2021-09-08 02:15:25 +02:00
Justin Turner Arthur
adcda091d9 Check complete ancestry of text nodes for smartquotes eligibility.
Fixes sphinx-doc/sphinx#9564.
2021-08-21 00:20:04 -05:00
Jeremy Maitin-Shepard
6c969ac87e Fix autodoc_docstring_signature support for __init__ and __new__
The `MethodDocumenter.get_doc` method added by
51ae283a38 prevents
DocstringSignatureMixin from working correctly for __init__ and
__new__ methods.  Additionally, the __new__ docstring was not obtained
correctly.

This commit checks for `self._new_docstrings` being set, and also
corrects the logic for obtaining the __new__ docstring.

There still remains the issue that when the class signature is
obtained from the signature of __init__ or __new__, only the real
signature is used, due to the use of `sphinx.util.inspect.signature`;
the autodoc_docstring_signature option does not have any effect.
2021-07-31 09:32:40 -07:00
Takeshi KOMIYA
05cce83cc7 Merge branch '4.1.x' into 4.x 2021-07-23 02:16:33 +09:00
Takeshi KOMIYA
a35b009adc Fix #9435: linkcheck: Failed to check anchors in github.com
The approach of `rewrite_github_anchor` makes some anchors valid.  But
it also makes other kind of anchors invalid.  This disables the handler
to make them valid again (while 4.1.x release).
2021-07-18 13:03:57 +09:00
Takeshi KOMIYA
38d80c3d0f Close #9445: autodoc: Support class properties
Since python 3.9, `classmethod` starts to support creating a "class
property".  This supports to generate document for it.
2021-07-17 16:39:50 +09:00
Simon Hausmann
3a50abc5c9 Fix handling of local paths in html_logo/html_favicon directorives in conf.py
Merge request #9381 broke support for local logos/favicons as it
retained the paths that are passed to the template engine. That's wrong
as the actual path will be in _static/.

This should fix #9438
2021-07-13 18:03:36 +02:00
Takeshi KOMIYA
f40c2837dc Merge pull request #9225 from doerwalter/typehint-html
Add HTML markup to method/function return typehint
2021-07-11 12:03:40 +09:00
Eisuke Kawashima
652ebf1bf5 Fix typo 2021-07-08 08:16:22 +09:00
Takeshi KOMIYA
5e5bca98f7 Merge branch '4.x' into 6525_linkcheck_warn_redirects 2021-07-07 02:09:50 +09:00
David A. Ham
c218cf2192 Merge branch 'sphinx-doc:4.x' into container-latex 2021-07-04 20:24:49 +01:00
David Ham
52aac40148 Update tests to match code changes. 2021-07-04 20:15:56 +01:00
Takeshi KOMIYA
54c6c666c1 Merge pull request #9386 from tk0miya/9384_autodoc_typehints_supports_attributes
Fix #9384: autodoc_typehints='none' supports typehints for attributes
2021-07-04 11:24:04 +09:00
Takeshi KOMIYA
2aef00d7bd Fix #9384: autodoc_typehints='none' supports typehints for attributes 2021-06-29 21:57:26 +09:00
Simon Hausmann
6a4c215cf0 Add unit test for remote logo and fav icon 2021-06-28 13:28:29 +02:00
Martin Liska
b23eefa03b Fix :samp:{var} in manual pages.
When a samp begins with a variable part, it is not unwrapped for manual
pages.

Fixes #1860.
2021-06-16 09:30:08 +02:00
Jakob Lykke Andersen
92c5ee07be Merge pull request #9155 from jakobandersen/field_roles
Call roles in typed fields
2021-06-03 19:28:19 +02:00
Takeshi KOMIYA
1418e3acbb Merge pull request #9260 from tk0miya/9016_linkcheck_github_anchors
Close #9016: linkcheck builder failed to check the anchors of github.com
2021-06-04 01:18:22 +09:00
Jakob Lykke Andersen
783314d54d Field roles, add C++ test 2021-06-03 16:52:38 +02:00
Jakob Lykke Andersen
27d40519c1 Field roles, add C test 2021-06-03 16:42:57 +02:00
Takeshi KOMIYA
69cbf7aa92 Merge pull request #9285 from tk0miya/9283_autodoc_attribute_not_having_comment
Fix #9283: autodoc: failed to build doc for attribute not commented
2021-06-03 21:47:58 +09:00
Takeshi KOMIYA
90470b094e Close #9268: python_use_unqualified_type_names supports type field 2021-06-03 00:09:16 +09:00
Takeshi KOMIYA
92335bd6e6 Close #9016: linkcheck builder failed to check the anchors of github.com 2021-06-01 00:31:15 +09:00
Takeshi KOMIYA
676834b998 Merge branch '4.x' into 6525_linkcheck_warn_redirects 2021-05-31 02:54:41 +09:00