Phantom <lambda> teardown entries with unknown status when using pytest 9.1+

Open
#918 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
58/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
python
Domain
testing

Research direction

Start by reproducing the report with allure-pytest 2.15.3 or 2.16.0 and pytest 9.1.1, then compare it with pytest 9.0.x. Trace the allure-pytest fixture teardown integration implicated by the issue; done means reports no longer contain phantom :: afterStage entries with unknown status.

Written by the indexing model from the issue text.

Description

Description

When using allure-pytest (2.15.3 or 2.16.0) with pytest >= 9.1.0, every fixture produces a phantom <fixture>::<lambda> afterStage entry in the Allure report with unknown status. These entries are not real teardown failures — they are internal pytest finalizers that allure wraps but are never invoked through allure's wrapper.

Image

Versions

  • pytest: 9.1.1
  • allure-pytest: 2.16.0
  • Python: 3.12
    Works correctly with pytest <= 9.0.x.
Dominant language
Python
Stars
815
Forks
260
Avg merge
9h 12m
Merged PRs (30d)
1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from allure-framework/allure-python

All issues in allure-framework/allure-python

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.