Skip to content

CI: No single CPU builds for pytest.mark.single test? #44584

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

Closed
mroeschke opened this issue Nov 23, 2021 · 5 comments
Closed

CI: No single CPU builds for pytest.mark.single test? #44584

mroeschke opened this issue Nov 23, 2021 · 5 comments
Labels
CI Continuous Integration

Comments

@mroeschke
Copy link
Member

mroeschke commented Nov 23, 2021

The single mark is supposed to be for mark a test as single cpu only

If I am interpreting the purpose correctly, these tests should be run with pytest -n 1. Though in our CI, I see PYTEST_WORKERS as either "auto" or 2

Github actions runners seem multi core: https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners#supported-runners-and-hardware-resources
Same with azure runners: https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#hardware

So is it correct that we aren't running these single tests as intended?

cc @lithomas1

@mroeschke mroeschke added the CI Continuous Integration label Nov 23, 2021
@lithomas1
Copy link
Member

This is not that hard to do. I think we can add "not single" to the -k argument when running the tests and then run pytest -k "single" -n 1 or something afterwards.

I don't understand why these are single core only though and I'm pretty sure the tests are actually still being run in the regular CI.

@mroeschke
Copy link
Member Author

Right, I think these tests are still being run, but maybe the intention is that @pytest.mark.single tests should be run on a single core to avoid flakiness when running with multiple cores?

@mroeschke
Copy link
Member Author

This was fixed

@jbrockmendel
Copy link
Member

There are a couple of # TODO(GH#44584): Mark these as pytest.mark.single_cpu in the code. since this is closed, can these be addressed?

@mroeschke
Copy link
Member Author

Yeah I bet those tests can be marked as single_cpu now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants