Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#27028 closed Cleanup/optimization (fixed)

Clarify failed parallel tests run message

Reported by: Adam Zapletal Owned by: Adam Zapletal
Component: Testing framework Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

If the test suite fails while running with more than one process, and the traceback is cannot be pickled, this message is printed:

You should re-run this test without the --parallel option to reproduce the failure and get a correct traceback.

The CPU count on my machine is 4, and the test suite runs with 4 processors if I don't provide the --parallel option or if I provide it with no argument. So the message is misleading.

Perhaps the error message should say:

You should re-run this test with the "--parallel 1" option to reproduce the failure and get a correct traceback.

I'll be happy to submit a PR if this ticket is accepted.

Change History (6)

comment:1 Changed 3 years ago by Adam Zapletal

Owner: changed from nobody to Adam Zapletal
Status: newassigned

comment:2 Changed 3 years ago by Aymeric Augustin

Triage Stage: UnreviewedAccepted

I believe this message can show up:

  • when you run Django's test suite: runtests.py enables parallelization by default
  • when you run a project's test suite: parallelization isn't enabled by default

The message is appropriate for the latter case but not for the former.

--parallel=1 covers both use cases. That's a good solution.

comment:3 Changed 3 years ago by Adam Zapletal

comment:4 Changed 3 years ago by Adam Zapletal

Has patch: set

comment:5 Changed 3 years ago by Tim Graham <timograham@…>

Resolution: fixed
Status: assignedclosed

In 2a11d2d:

Fixed #27028 -- Clarified failed parallel tests message.

comment:6 Changed 3 years ago by Tim Graham <timograham@…>

In 06ba4926:

[1.10.x] Fixed #27028 -- Clarified failed parallel tests message.

Backport of 2a11d2d7a7d5c6609c85dbc631fad6b8a8645a64 from master

Note: See TracTickets for help on using tickets.
Back to Top