-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Closed
Labels
topic: reportingrelated to terminal output and user-facing messages and errorsrelated to terminal output and user-facing messages and errorstopic: tracebacksrelated to displaying and handling of tracebacksrelated to displaying and handling of tracebackstype: enhancementnew feature or API change, should be merged into features branchnew feature or API change, should be merged into features branch
Description
Currently pytest always truncates any output string when displaying assertion errors to 240 characters (it is hardcoded in saferepr
). This is often a problem, specially in CI (#6682).
#8391 changes how verbosity affects truncation of assertion output, like this:
Verbosity | Max chars |
0 | 240 |
1 | 240 |
2 | 240 |
3 | 2400 |
4+ | No limit |
The intent here was to keep the normal -v
and -vv
(the more common verbosity levels) unchanged, however I have been thinking that perhaps it makes more sense to increase the threshold starting right with -v
, like this:
Verbosity | Max chars |
0 | 240 |
1 | 2400 |
2+ | No limit |
Thoughts?
The logic is that one who is increasing verbosity already expects more output anyway, so it makes sense to increase the threshold limit as well.
cc @ssbarnea
ssbarnea
Metadata
Metadata
Assignees
Labels
topic: reportingrelated to terminal output and user-facing messages and errorsrelated to terminal output and user-facing messages and errorstopic: tracebacksrelated to displaying and handling of tracebacksrelated to displaying and handling of tracebackstype: enhancementnew feature or API change, should be merged into features branchnew feature or API change, should be merged into features branch