Skip to content

Conversation

@junhaoliao
Copy link
Contributor

@junhaoliao junhaoliao commented Dec 2, 2025

closes #14023

This change introduces a long-form CLI option --report-chars as an alternative to the existing
short -r option.


Here is a quick checklist that should be present in PRs.

  • Include documentation when adding new features.
  • Include new tests or update existing tests when applicable.
  • Allow maintainers to push and squash when merging my commits. Please uncheck this if you prefer to squash the commits yourself.

If this change fixes an issue, please:

  • Add text like closes #XYZW to the PR description and/or commits (where XYZW is the issue number). See the github docs for more information.

Unless your change is trivial or a small documentation fix (e.g., a typo or reword of a small section) please:

  • Create a new changelog file in the changelog folder, with a name like <ISSUE NUMBER>.<TYPE>.rst. See changelog/README.rst for details.

    Write sentences in the past or present tense, examples:

    • Improved verbose diff output with sequences.
    • Terminal summary statistics now use multiple colors.

    Also make sure to end the sentence with a ..

  • Add yourself to AUTHORS in alphabetical order.

@psf-chronographer psf-chronographer bot added the bot:chronographer:provided (automation) changelog entry is part of PR label Dec 2, 2025
@junhaoliao junhaoliao marked this pull request as ready for review December 2, 2025 07:15
@junhaoliao junhaoliao requested a review from jakkdl December 2, 2025 18:24
@junhaoliao
Copy link
Contributor Author

Hi @jakkdl , I tried parameterizing the test case as instructed. Do you mind taking a look again?

@jakkdl
Copy link
Member

jakkdl commented Dec 4, 2025

rewrote the parametrize to be slightly cleaner :)

Looking at --help I'm seeing a small discrepancy where some long options are displayed with a
= before the value and some aren't - but that's not limited to this option.

  --deselect=nodeid_prefix
  --doctest-glob=pat
  --lfnf, --last-failed-no-failures={all,none}

vs

  -r, --report-chars chars
  -c, --config-file FILE

but I don't think it really matters.

I'll merge this in a few days unless somebody pops in and notices something, thank you!

@jakkdl jakkdl enabled auto-merge December 8, 2025 12:01
@jakkdl jakkdl merged commit 324ef94 into pytest-dev:main Dec 8, 2025
33 checks passed
@nicoddemus
Copy link
Member

Thanks @junhaoliao for the PR and @jakkdl for merging!

@jakkdl just a note, in the future prefer to squash the commits when they by themselves are not very valuable to keep in the history (for example, "add changelog", "precommit fixes", etc).

Thanks again folks!

@jakkdl
Copy link
Member

jakkdl commented Dec 10, 2025

frick sorry, not the first time it happened. I used to have a monkeyscript that warned about it but it appears to have gotten disabled at some point.

@nicoddemus
Copy link
Member

No worries!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bot:chronographer:provided (automation) changelog entry is part of PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add a long form "--report-chars" to pytest.

3 participants