-
Notifications
You must be signed in to change notification settings - Fork 48
Add ability to run tests in parallel [PULP-753] #1241
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
base: main
Are you sure you want to change the base?
Conversation
5447ea9 to
bd148c5
Compare
| if pulp_ctx.api._dry_run: | ||
| raise click.ClickException( | ||
| _("Trying to cancel {} tasks in safe-mode, aborting").format(len(tasks)) | ||
| ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤔 Is this changing the behaviour or just preventing an Exception further down in the stack to trigger?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's changing the behavior to be more consistent. Before if you ran this command in dry mode it would only give the abort message upon the first task cancellation, meaning it would only error if there was running/waiting tasks. Now it will always give an error (with the amount of available tasks to cancel) when ran in dry mode. Basically the test_tasks check of this command was really inconsistent when running in parallel.
bd148c5 to
bb3bdfa
Compare
bb3bdfa to
6aa7ae5
Compare
|
I can't figure out why the query_params test is failing. The output looks sorted. I test with the same names and I get no error, albeit I'm not running other tests in the background at the same time. But even with parallel tests I can't see how another test is affecting this one. I look at the error message in the $OUTPUT list and the list is sorted. This failure doesn't happen often, but I seen it on both the reverse and normal alphabetical list. Is it somehow possible we have a bug in pulpcore, a race condition that breaks the ordering maybe having to do with paginating the query? |
Is it a good idea to test whether pulpcore sorts properly in the first place? |
Need to figure out how to handle tests that call orphan cleanup and make sure they run last and in serial. Most of this is ensuring each test uses unique names to prevent collisions.