Skip to content

fix(test): raise pytest-rerunfailures floor to stop fixture leak across reruns - #1618

Merged
sd-db merged 3 commits into
mainfrom
sd-db/fix/rerunfailures-fixture-leak
Jul 29, 2026
Merged

fix(test): raise pytest-rerunfailures floor to stop fixture leak across reruns#1618
sd-db merged 3 commits into
mainfrom
sd-db/fix/rerunfailures-fixture-leak

Conversation

@sd-db

@sd-db sd-db commented Jul 28, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Raise the pytest-rerunfailures lower bound to >=16.2 (and regenerate the min-deps lock) so CI no longer pins 14.0
  • In 14.0, a failed test's rerun teardown dropped class-scoped setup finalizers, leaking the first class's dbt project fixture into later classes on the same xdist worker
  • That cascade turned a real TestSpecifyingHttpPath cluster REPL failure into false failures in TestJobClusterMissingConfig, TestAllPurposeClusterMissingClusterId, and TestManagedIcebergPythonModel on Min-Deps SQL-warehouse shard 0 (run 30367154216)
  • Remove the SchemaNameVarMixin workaround that was papering over the same leak (test-only, no runtime impact)

Test plan

  • Minimal repro: class-scoped fixture leak on pytest-rerunfailures==14.0 with --reruns 1; absent on 15.0–16.2
  • Functional: deliberate rerun trigger + missing-config tests fail under 14.0, pass under 16.2 (SQL warehouse profile)
  • Functional: de-mixined TestChangingSchema / TestChangingSchemaIncremental pass on SQL warehouse
  • hatch run code-quality / pre-commit hooks pass
  • CI Min-Deps Integration Tests green (or only the known flaky TestSpecifyingHttpPath REPL failure, without the cascade)

…ss reruns

Min-deps pinned 14.0, which dropped class-scoped setup finalizers on rerun and
leaked the first class's dbt project into later Python-model tests. Bump to
>=16.2 and drop the SchemaNameVarMixin workaround that was papering over it.
@sd-db
sd-db requested a review from jprakash-db as a code owner July 28, 2026 19:29
sd-db added 2 commits July 29, 2026 00:59
1.12.3 is already released; this test-only change belongs in the next version.
@sd-db

sd-db commented Jul 28, 2026

Copy link
Copy Markdown
Collaborator Author

/integration-test min-deps

@sd-db
sd-db enabled auto-merge (squash) July 28, 2026 19:32
@github-actions

Copy link
Copy Markdown

Min-deps integration tests dispatched for PR #1618 by @sd-db. Testing commit 3418865. Track progress in the Actions tab.

@github-actions

Copy link
Copy Markdown

Coverage report

This PR does not seem to contain any modification to coverable code.

@github-actions

Copy link
Copy Markdown

Min-deps integration results for PR #1618 — UC cluster ✅ success · SQL warehouse ✅ success · All-purpose cluster ✅ success · Shard coverage ✅ success

Run details.

@sd-db
sd-db merged commit 50dd334 into main Jul 29, 2026
10 checks passed
@sd-db
sd-db deleted the sd-db/fix/rerunfailures-fixture-leak branch July 29, 2026 15:33
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.

2 participants