File tree 3 files changed +12
-1
lines changed
3 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -50,6 +50,8 @@ Features added
50
50
pattern doesn't match any documents, via the new ``toc.glob_not_matching ``
51
51
warning sub-type.
52
52
Patch by Slawek Figiel.
53
+ * #9732: Add the new ``autodoc.mock_objects `` warnings sub-type.
54
+ Patch by Cyril Roelandt.
53
55
54
56
Bugs fixed
55
57
----------
Original file line number Diff line number Diff line change @@ -1404,6 +1404,7 @@ Options for warning control
1404
1404
1405
1405
* ``autodoc ``
1406
1406
* ``autodoc.import_object ``
1407
+ * ``autodoc.mocked_object ``
1407
1408
* ``autosectionlabel.<document name> ``
1408
1409
* ``autosummary ``
1409
1410
* ``autosummary.import_cycle ``
@@ -1453,6 +1454,11 @@ Options for warning control
1453
1454
.. versionadded :: 8.2
1454
1455
Added ``toc.empty_glob ``.
1455
1456
1457
+ .. versionadded :: 8.2
1458
+
1459
+ Added ``autodoc.mocked_object ``
1460
+
1461
+
1456
1462
Builder options
1457
1463
===============
1458
1464
Original file line number Diff line number Diff line change @@ -1032,7 +1032,10 @@ def generate(
1032
1032
)
1033
1033
if ismock (self .object ) and not docstrings :
1034
1034
logger .warning (
1035
- __ ('A mocked object is detected: %r' ), self .name , type = 'autodoc'
1035
+ __ ('A mocked object is detected: %r' ),
1036
+ self .name ,
1037
+ type = 'autodoc' ,
1038
+ subtype = 'mocked_object' ,
1036
1039
)
1037
1040
1038
1041
# check __module__ of object (for members not given explicitly)
You can’t perform that action at this time.
0 commit comments