Skip to content

Commit ed587ab

Browse files
committed
doc: document {Code,TracebackEntry}.path changes as breaking
Closes pytest-dev#9423.
1 parent 69da199 commit ed587ab

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

doc/en/changelog.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,12 @@ Deprecations
173173
This was changed for consistency with :func:`pytest.mark.skip <pytest.mark.skip>` and :func:`pytest.mark.xfail <pytest.mark.xfail>` which both accept
174174
``reason`` as an argument.
175175

176+
- `#8174 <https://github.com/pytest-dev/pytest/issues/8174>`_: The following changes have been made to types reachable through :attr:`pytest.ExceptionInfo.traceback`:
177+
178+
- The ``path`` property of ``_pytest.code.Code`` returns ``Path`` instead of ``py.path.local``.
179+
- The ``path`` property of ``_pytest.code.TracebackEntry`` returns ``Path`` instead of ``py.path.local``.
180+
181+
There was no deprecation period for this change (sorry!).
176182

177183

178184
Features
@@ -477,6 +483,7 @@ Trivial/Internal Changes
477483
- The ``path`` property of ``_pytest.code.TracebackEntry`` returns ``Path`` instead of ``py.path.local``.
478484
- The ``_pytest.code.getfslineno()`` function returns ``Path`` instead of ``py.path.local``.
479485
- The ``_pytest.python.path_matches_patterns()`` function takes ``Path`` instead of ``py.path.local``.
486+
- The ``_pytest._code.Traceback.cut()`` function accepts any ``os.PathLike[str]``, not just ``py.path.local``.
480487

481488

482489
- `#8248 <https://github.com/pytest-dev/pytest/issues/8248>`_: Internal Restructure: let ``python.PyObjMixin`` inherit from ``nodes.Node`` to carry over typing information.

0 commit comments

Comments
 (0)