-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Separate terminal verbosity from diff verbosity #6723
Comments
I have I'm planning to have something like This could also default to "auto", which means that it would be 2 for running on CI. #5192 is a bug, not really related to having the option / control for it. |
I almost always use Will the How does the parsing of
In that case there will also need to be a flag to decrease the default verbosity, so should consider it in the bikesheding. |
Adding this as a config option (rather than a CLI-flag) as a first step would work well for me, since I almost always want the highest level of verbosity for tests. |
Is there still interest in this? I use I'm a bit strapped for time, however, and I'm not very experienced with the codebase so will likely need guidance. |
@iliakur thanks for volunteering! Yes definitely there's still interest in this. Beside the original post, we also need to consider the remarks in #6723 (comment).
Sure, we are glad to provide it. To get you started, you can see that pytest/src/_pytest/terminal.py Lines 114 to 123 in ced125a
And is used like this throughout the codebase: pytest/src/_pytest/terminal.py Lines 773 to 775 in ced125a
So we need to review everywhere the option is used and adapt it for the new flags (which we still need to decide precisely). Let us know if this is enough to at least get started. 👍 |
@nicoddemus should this be closed as implemented by #11387? |
Sure, thanks for the ping! |
Currently
-v
controls both terminal verbosity (how to display test session progress in the terminal) and diff verbosity (how verbose is our diffs when assertions fail).I've often wanted to increase diff verbosity while also keeping terminal verbosity at the normal level, but this is not possible today.
Proposal
Introduce a new option that controls only diff verbosity (for discussion here
-dv
, but please let's bikeshed on this).For backward compatibility reasons,
-v
keeps controlling both terminal verbosity and diff verbosity, but-dv
can be used to increase diff verbosity independently.-v
: when used, increase both terminal verbosity and diff verbosity.-dv
: when used, increase diff verbosity only (we also need the equivalent of-q
for diff verbosity).With
-dv
in place, we might even consider changing to a higher level of diff verbosity in the future by default, but that remains to be seen.Related: #6292, #5192
The text was updated successfully, but these errors were encountered: