-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Include TerminalReporter in reference docs #6649 #12661
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
Include TerminalReporter in reference docs #6649 #12661
Conversation
d020e1b
to
e3a6c63
Compare
I'm wondering if I should/can add an import of TerminalReporter somewhere around Lines 70 to 72 in 6c806b4
|
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.
Hi @soxofaan, thanks for the PR.
The TerminalReporter
not being part of the docs is an oversight, given they are part of the signature of pytest_terminal_summary
.
I'm wondering if I should/can add an import of TerminalReporter somewhere around
Yes we should also publish it as part of the public API: if it is used by a public hook, it should also be available from the pytest
namespace.
Also the build failed with:
/home/docs/checkouts/readthedocs.org/user_builds/pytest/envs/12661/lib/python3.12/site-packages/_pytest/terminal.py:docstring of _pytest.terminal.TerminalReporter.build_summary_stats_line:11: WARNING: Definition list ends without a blank line; unexpected unindent.
Probably just need to fix the docstring here:
pytest/src/_pytest/terminal.py
Lines 1342 to 1343 in 6c806b4
This function builds a list of the "parts" that make up for the text in that line, in | |
the example above it would be: |
To:
This function builds a list of the "parts" that make up for the text in that line, in
- the example above it would be:
+ the example above it would be::
It is unfortunate that the entire terminal plugin is being passed along to this hook, but too late for this now so we might as well document it.
In stoll hoping we can replace it, It's api is from python 2.4 times and libraries more dedicated to the topic recently showed a much nicer variant (like rich) |
thanks for the feedback. All tests pass now |
I know, let's hope we manage to eventually find the time (and will) to do that. 🤞 |
This while small should not be backported, as it is introducing a new public symbol, so it should happen in the next minor release. |
@RonnyPfannschmidt |
(I have a local fix for the docs, will push shortly) |
Closes #6649
closes #XYZW
to the PR description and/or commits (whereXYZW
is the issue number). See the github docs for more information.changelog
folder, with a name like<ISSUE NUMBER>.<TYPE>.rst
. See changelog/README.rst for details.AUTHORS
in alphabetical order.