Commit dcae8f1
committed
gh-150076: Document the public attributes of warnings.deprecated
The documentation described only the ``__deprecated__`` attribute set on
the decorated object, and did not mention that ``deprecated`` is a class
whose instances expose the constructor arguments (``message``, ``category``
and ``stacklevel``) as attributes of the same names -- a part of the API
that downstream projects rely on.
Document these attributes, and rename the first parameter in the signature
from ``msg`` to ``message`` to match the implementation and the attribute.1 parent 1736526 commit dcae8f1
1 file changed
Lines changed: 13 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
566 | 566 | | |
567 | 567 | | |
568 | 568 | | |
569 | | - | |
| 569 | + | |
570 | 570 | | |
571 | 571 | | |
572 | 572 | | |
| |||
612 | 612 | | |
613 | 613 | | |
614 | 614 | | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
615 | 627 | | |
616 | 628 | | |
617 | 629 | | |
| |||
0 commit comments