Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add more docs on the fspath deprecation #8445

Closed
RonnyPfannschmidt opened this issue Mar 14, 2021 · 5 comments · Fixed by #8903
Closed

add more docs on the fspath deprecation #8445

RonnyPfannschmidt opened this issue Mar 14, 2021 · 5 comments · Fixed by #8903
Labels
type: deprecation feature that will be removed in the future type: docs documentation improvement, missing or needing clarification
Milestone

Comments

@RonnyPfannschmidt
Copy link
Member

provide more help for testing and general code handling it

Originally posted by @RonnyPfannschmidt in #8418 (reply in thread)

@Zac-HD Zac-HD added type: deprecation feature that will be removed in the future type: docs documentation improvement, missing or needing clarification labels Mar 15, 2021
@nicoddemus nicoddemus added this to the 7.0 milestone Mar 18, 2021
@h-vetinari
Copy link

Since #8037 has gone in, this should probably be remilestoned to 7.0? CC @The-Compiler

PS. The GH UI looks mighty confusing with renamed milestones:

pytest_7 0

@nicoddemus nicoddemus modified the milestones: 8.0, 7.0 Jun 29, 2021
@nicoddemus
Copy link
Member

Fixed, thanks!

@nicoddemus nicoddemus removed this from the 7.0 milestone Jun 29, 2021
@nicoddemus
Copy link
Member

nicoddemus commented Jun 29, 2021

Ahh no sorry, it should be removed from 7.0 but will be released in a future version.

@h-vetinari
Copy link

h-vetinari commented Jun 29, 2021

Ahh no sorry, it should be removed from 7.0 but will be released in a future version.

How so? It's already released, isn't it (based on the notice you link below)? Quoting from #8418 (which is what this issues was about):

hl037: From here: https://docs.pytest.org/en/latest/reference.html#request [fixed link]
I can see request.fspath will be deprecated. I can't find information about this decision and I was wondering what could I use instead to get the current test path ?

@RonnyPfannschmidt: Good catch, the path alias needs to be added there, request.node.path will do meanwhile

@nicoddemus: we have a short notice here: https://docs.pytest.org/en/latest/deprecations.html#node-fspath-in-favor-of-pathlib-and-node-path

However I wonder if we should expand that? We only mention some kind of reasoning briefly:

As pytest tries to move off py.path.local we ported most of the node internals to pathlib.

Should we expand/create a new section with the rationale and future plans?

@RonnyPfannschmidt: We should

@The-Compiler
Copy link
Member

Yeah, it sounds like this should be in 7.0. The fspath deprecation is in 7.0, so I suppose we should also have proper deprecation docs there. Let's add it for now and then look at it in detail later before the final release.

@The-Compiler The-Compiler added this to the 7.0 milestone Jun 29, 2021
nicoddemus added a commit to nicoddemus/pytest that referenced this issue Jul 13, 2021
It is not clear yet how we should proceed with this deprecation
because `pytest.Item.reportinfo` is public API and returns a `py.path` object,
and is not clear how plugins and our examples should handle that.

Reverting just the deprecation aspect of pytest-dev#8251 so we can get a 7.0.0 release out.

We will reintroduce the deprecation later once we have a clear path moving forward with replacing `reportinfo`.

Closes pytest-dev#8445
Closes pytest-dev#8821
nicoddemus added a commit to nicoddemus/pytest that referenced this issue Jul 13, 2021
It is not clear yet how we should proceed with this deprecation
because `pytest.Item.reportinfo` is public API and returns a `py.path` object,
and is not clear how plugins and our examples should handle that.

Reverting just the deprecation aspect of pytest-dev#8251 so we can get a 7.0.0 release out.

We will reintroduce the deprecation later once we have a clear path moving forward with replacing `reportinfo`.

Closes pytest-dev#8445
Closes pytest-dev#8821
RonnyPfannschmidt pushed a commit to RonnyPfannschmidt/pytest that referenced this issue Oct 1, 2021
It is not clear yet how we should proceed with this deprecation
because `pytest.Item.reportinfo` is public API and returns a `py.path` object,
and is not clear how plugins and our examples should handle that.

Reverting just the deprecation aspect of pytest-dev#8251 so we can get a 7.0.0 release out.

We will reintroduce the deprecation later once we have a clear path moving forward with replacing `reportinfo`.

Closes pytest-dev#8445
Closes pytest-dev#8821
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: deprecation feature that will be removed in the future type: docs documentation improvement, missing or needing clarification
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants