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

test: run stuff in parallel #787

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from
Draft

test: run stuff in parallel #787

wants to merge 3 commits into from

Conversation

mvo5
Copy link
Collaborator

@mvo5 mvo5 commented Jan 8, 2025

Use filelock.FileLock to workaround the issue that session fixtures do not work with xdist. This should probably be redone in some less hard to read way :(

[edit: results so far not too encouraging, also for some reason the most important function to parallize is build_images() but that for some reason (pytest scopes side-effects?) is only run in sequence even though it it supposed to be parrallel with e.g. "sudo pytest -s -n 8 ./test/test_build.py::test_iso_installs"]
[edit2: I (strongly) suspect the issue is the indirect paramerization of the fixtures, it seems those cannot be parallelized by xdist so we need to rework/remove the fixtures which is probably a good idea anyway as they got a bit out of hand here]

Results:

  • sequencial: 1h47min (pr#791)
  • with -n4: 1h8m
  • with -n8: ... ?

@mvo5 mvo5 force-pushed the xdist-again branch 4 times, most recently from 498c6be to 47dc4e7 Compare January 10, 2025 16:26
mvo5 added 2 commits January 10, 2025 21:38
Use filelock.FileLock to workaround the issue that session fixtures
do not work with xdist. This should probably be redone in some less
hard to read way :(
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant