modal-labs / pytest-markdown-docs

Run pytest on markdown code fence blocks
MIT License
46 stars 6 forks source link

Warning thrown from `pytest` Re: PytestRemovedIn8Warning #9

Closed engineerjoe440 closed 7 months ago

engineerjoe440 commented 1 year ago

Hi there!

Was just trying this plugin for a project I manage, and I came across a few warnings:

=========================================================================================== warnings summary =========================================================================================== 
..\..\..\..\..\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:234
..\..\..\..\..\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:234
..\..\..\..\..\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:234
..\..\..\..\..\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:234
..\..\..\..\..\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:234
..\..\..\..\..\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:234
  C:\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:234: PytestRemovedIn8Warning: The (fspath: py.path.local) argument to MarkdownTextFile is deprecated. Please use the (path: pathlib.Path) argument instead.
  See https://docs.pytest.org/en/latest/deprecations.html#fspath-argument-for-node-constructors-replaced-with-pathlib-path
    return MarkdownTextFile.from_parent(parent, fspath=path)

..\..\..\..\..\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:232
..\..\..\..\..\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:232
  C:\Python311\Lib\site-packages\pytest_markdown_docs\plugin.py:232: PytestRemovedIn8Warning: The (fspath: py.path.local) argument to MarkdownDocstringCodeModule is deprecated. Please use the (path: pathlib.Path) argument instead.
  See https://docs.pytest.org/en/latest/deprecations.html#fspath-argument-for-node-constructors-replaced-with-pathlib-path
    return MarkdownDocstringCodeModule.from_parent(parent, fspath=path)

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
==================================================================================== 2 passed, 8 warnings in 0.65s ===================================================================================== 

System Information

It seems this might be the result of a pending change in pytest, but perhaps I'm misreading that. Any thoughts?

Thank you for this exciting project!