-
Notifications
You must be signed in to change notification settings - Fork 573
NO-SNOW: Reduce CI flakiness with pytest --lf retry and drop rerunfailures - #2998
Draft
sfc-gh-turbaszek wants to merge 2 commits into
Draft
NO-SNOW: Reduce CI flakiness with pytest --lf retry and drop rerunfailures #2998sfc-gh-turbaszek wants to merge 2 commits into
sfc-gh-turbaszek wants to merge 2 commits into
Conversation
...lures Replace pytest-rerunfailures (and its shutdown crashes) with a follow-up --lf --maxfail=5 pass, and fix test_fetch_batches_with_sessions mocking SnowflakeRestful so OCSP session use is not counted. Co-authored-by: Cursor <cursoragent@cursor.com>
Codecov Report
✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 64.89%. Comparing base (50e7fc5) to head (7579611).
Additional details and impacted files
@@ Coverage Diff @@ ## main #2998 +/- ## ========================================== - Coverage 65.12% 64.89% -0.23% ========================================== Files 123 123 Lines 17447 17447 Branches 2396 2396 ========================================== - Hits 11362 11322 -40 - Misses 5646 5683 +37 - Partials 439 442 +3
☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.
🚀 New features to boost your workflow:
- 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
@sfc-gh-turbaszek
sfc-gh-turbaszek
added
the
NO-CHANGELOG-UPDATES
This pull request does not need to update CHANGELOG.md
label
Aug 7, 2026
... command The follow-up `pytest --lf --last-failed-no-failures none` ran as an unconditional second tox command, so a green suite collected nothing and exited 5, failing every test job. Gate the retry on the first step's outcome instead, matching how universal-driver reruns its suites, and restore the single plain pytest command per tox environment. Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
pytest-rerunfailures/@pytest.mark.flakywith a tox/FIPS follow-up pass usingpytest --lf --maxfail=5 --last-failed-no-failures noneto retry a small number of potential flakes.pytest_unconfiguresocket workaround that existed only for rerunfailures shutdown hangs.test_fetch_batches_with_sessionsto mockSnowflakeRestful.use_requests_sessionso OCSPSessionManager.use_sessioncalls during cloud chunk downloads do not inflatecall_count.Test plan
pytest_rerunfailures/_enter_buffered_busyshutdown abortstest_fetch_batches_with_sessionsis stable across GCP/AWS/Azure jobs--maxfail=5does not greenwash widespread breakage)Supersedes #2997 (opened from fork; secrets were unavailable).
Made with Cursor