Skip to content

FIX: Increase reruns for flaky test_invisible_Line_rendering (#30809)#30920

Merged
QuLogic merged 1 commit intomatplotlib:mainfrom
codingabhiroop:fix_flaky_test_reruns
Jan 3, 2026
Merged

FIX: Increase reruns for flaky test_invisible_Line_rendering (#30809)#30920
QuLogic merged 1 commit intomatplotlib:mainfrom
codingabhiroop:fix_flaky_test_reruns

Conversation

@codingabhiroop
Copy link
Contributor

PR summary

This PR addresses the flaky test test_invisible_Line_rendering (#30809) by increasing the number of reruns in the @pytest.mark.flaky decorator from 3 → 5.

  • Why is this change necessary?
    The test is timing-based and occasionally fails on loaded systems due to natural timing variability. Increasing reruns reduces intermittent failures while keeping the test fast.

  • What problem does it solve?
    Reduces false negatives in CI caused by timing noise. No functional code is changed.

  • What is the reasoning for this implementation?
    Maintainers recommended increasing reruns as the simplest and safest approach to address flaky timing tests. Other approaches (increasing thresholds or repeats) would either reduce sensitivity or slow down the test unnecessarily.


PR checklist

Copy link
Member

@timhoffm timhoffm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This only helps in some edge cases, but does not cost us anything, so ok.

@QuLogic QuLogic added this to the v3.11.0 milestone Jan 3, 2026
@QuLogic QuLogic merged commit cddd973 into matplotlib:main Jan 3, 2026
37 checks passed
@codingabhiroop codingabhiroop deleted the fix_flaky_test_reruns branch January 3, 2026 19:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: test_invisible_Line_rendering test is flaky (too short timeout)

4 participants