Skip to content

CI: Implement conditional verbose logging [verbose]#32081

Draft
Aaratrika-Shelly wants to merge 1 commit into
matplotlib:mainfrom
Aaratrika-Shelly:ci/verbose-toggle
Draft

CI: Implement conditional verbose logging [verbose]#32081
Aaratrika-Shelly wants to merge 1 commit into
matplotlib:mainfrom
Aaratrika-Shelly:ci/verbose-toggle

Conversation

@Aaratrika-Shelly

Copy link
Copy Markdown
Contributor

This PR is a follow up to the discussion in #31087 and the disscusion regarding my GSOC proposal on discoourse (https://discourse.matplotlib.org/t/gsoc-2026-intro-aaratrika-shelly-indirecttransforms-test-hardening/26173/10)

PR summary

This PR implements the verbose toggle for the Matplotlib CI pipelines (Github Actions, Azure Pipelines and AppVeyor).

  • Why is this change necessary?
    Right now the logs dont provide much information while debugging test flakiness. This makes finding the issue really difficult. To get the logs, we need to manually edit the config files, which is time consuming.
  • What problem does it solve?
    This PR helps automate the process by introducting pytest -vv command. This command lets aanyone (maintainer or contributer) trigger the verbose logs without making permanent config changes. It helps to get logs for each run, which in turn helps diagnose the flaky tests I identified during my GSOC 2026 research.
  • What is the reasoning for this implementation?
    I used PYTEST_ADDOPTS as an environment variable since it is a native functionality of pytest.
    -I introduced two triggers to cater to 2 different users.
    Commit Message- for contributors/
    Github Label(ci:verbose) for maintainers: They can turn on verbosity for PR without creation of a new commit
    Consistency across Platforms: By making it available via GitHub Actions (Linux/macOS), Azure Pipelines (Windows) and AppVeyor (Legacy Windows), I was able to provide consistency of debugging experience for the community members, whatever platform they use when encountering a problem.

I have opened this as a Draft to verify the trigger logic across all CI runners. I've included [verbose] in this commit to verify the behavior in the logs

AI Disclosure

Proofreading PR desciption.

PR checklist

cc: @rcomer, @story645, @timhoffm

@timhoffm

Copy link
Copy Markdown
Member

Thanks for the contribution. IMHO this doesn't really help with the problem. Flakiness means that you cannot systematically test this; i.e. you cannot take a PR with a failing run, add the verbose label and rerun.

There are only two approaches that can help:

  • either systematically log relevant information across all PR. - However, this must be more targeted than a global pytest -vv
  • do systematic testing, as it was done in Debugging timeouts: make tests verbose in CI #31087. But here it's good enough to modify the CI configuration of the systematic test.

@melissawm melissawm added Maintenance CI: testing CI configuration and testing labels Jul 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI: testing CI configuration and testing Maintenance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants