Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
|
|
Set multiprocessing start method to `fork`
|
|
Fix #9947: i18n: topic directive having a bullet list can't be translatable
|
|
It seems docutils does not fill the topic node with the source info when
a topic directive has a bullet list. As a workaround, This fills the
source info of them.
|
|
To make the generated function signatures simple, this adds a new
parameter `unqualified_typehints` to sphinx.util.inspect:
stringify_signature() to suppress the leading module name of
typehints.
|
|
To make the generated function signatures simple, this adds a new
parameter `smartref` to sphinx.util.typing:stringify() to suppress the
leading module name from typehints.
|
|
|
|
|
|
Close #9618: i18n: Add gettext_allow_fuzzy_translations
|
|
|
|
Distutils module are now deprecated and will be removed in Python 3.12.
This replaces it by packaging module and reduces the dependency to it.
refs: #9820
|
|
|
|
Also, when a reference is unresolved, don't strip the inventory prefix.
|
|
|
|
Fix issue with warnings without subtype being incorrectly suppressed
|
|
Closes #9733: Fix for logging handler flushing warnings in the middle of the docs build
|
|
|
|
Since the current code requires forking, set it explicitly rather than disabling
parallelization on macOS.
|
|
|
|
Since 0.18, Element.traverse() returns an iterator instead of
intermediate object. As a result, the return value is always considered
as truthy value. And it becomes fragile when the caller modifies the
doctree on the loop.
|
|
build
Summary:
My project was mysteriously dropping warnings (see https://github.com/sphinx-doc/sphinx/issues/9733 for detailed repro) and I realized that it's becaues it imports libraries like airflow or mlflow that set up loggers automatically when they are imported. This causes this handler to flush even though shouldFlush is set to always return False. A simple workaround is to override flush to be a no-op.
Test Plan: Repeat repro steps from #9733 - project now always includes warnings
|
|
Whilst working on the Reproducible Builds effort [0] I noticed that sphinx
generates output that is not reproducible, causing a number of packages in
Debian to unreproducible.
Specifically, when Sphinx locates an alias of an instance when generating
'autodoc' documentation, it uses the raw Python repr(...) of the object and
does not sanitise it for memory addresses (etc.) like elsewhere in Sphinx.
This can result in documentation like this:
-<dd><p>alias of <webob.client.SendRequest object at 0x7fd769189df0></p>
+<dd><p>alias of <webob.client.SendRequest object at 0x7f0f02233df0></p>
Patch attached that uses the object_description method, which was added to fix
precisely this kind of issue.
I originally filed this in Debian as bug #996948 [1].
[0] https://reproducible-builds.org/
[1] https://bugs.debian.org/996948
|
|
|
|
|
|
This allows to inject a reST snippet through autodoc-process-bases
event. It helps to modify the base classes of any class to the expected
mark-up'ed text by custom extension.
|
|
This fixes an issue with warnings that have been raised with no subtype
being suppressed if a suppress warnings value with a subtype has been set.
e.g. all `autodoc` warnings should not be suppressed if
`autodoc.import_object` is only set to be suppressed.
|
|
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.
|
|
Close #9639: autodoc: Support asynchronous generator functions
|
|
|
|
Autodoc generates reST code that uses raw `:obj:` and `:class:` xrefs to
refer the classes and types. But they're fragile because they assume
the primary_domain=='py'.
This adds `:py:` prefix to these xrefs to make them robust.
|
|
Close #9560: autodoc: Allow to refer NewType with modname in py310+
|
|
|
|
Before 3.10, an instance of NewType has incorrect module name. But it
was fixed on 3.10. This starts to use the module info if the
interpreter is 3.10+.
|
|
|
|
Fix #9589: autodoc: typing.Annotated has wrongly been rendered
|
|
At the HEAD of 3.10, the implementation of `typing.Annotated` has
been changed to have __qualname__.
|
|
Fixes sphinx-doc/sphinx#9564.
|
|
FIX: do not try to compute the boolean value of a numpy array
|
|
|
|
At the HEAD of 3.10, the implementation of `typing._GenericAlias` has
been changed to have correct _name and __name__.
|
|
If there is a numpy array as a class attribute, then `bool(meth)` will
raise.
|
|
|
|
|
|
|
|
|
|
Autodoc generates incorrect references to the parent class the target
class inherites the class having `_name` attribute. It conciders the
parent is a kind of SpecialForm'ed class by mistake. This uses
`isinstance(X, SpecialForm)` to check that.
Note: SpecialForm became a class since Python 3.7.
|