Skip to content

Question/Bug regarding total duration with xdist #774

@klott

Description

@klott

I am running my test suite with xdist (-n 8 --dist worksteal) and everything is working except for the total duration time which is summing up all individual test execution times instead of tracking actual duration of the test run.

For example, 27 tests at 8 threads took 19 minutes and 15 seconds (setup and all) but the HTML report is reporting the total duration as 58 minutes and 37 seconds.

Am I missing something or is this an oversight? If the latter, then this stackoverflow answer seems like a promising solution by utilizing the pytest_unconfigure hook along with terminalreporter. Why not use this regardless of xdist for an accurate duration time?

https://stackoverflow.com/questions/56271207/how-to-access-the-overall-runtime-in-pytest

thanks for your time.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions