-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix TestHooksInSourceFreshnessDisabled flaky test #10308
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #10308 +/- ##
==========================================
- Coverage 88.76% 88.70% -0.06%
==========================================
Files 180 180
Lines 22483 22483
==========================================
- Hits 19957 19944 -13
- Misses 2526 2539 +13
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
def global_deprecations(self): | ||
deprecations.reset_deprecations() | ||
yield | ||
deprecations.reset_deprecations() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
root cause: this clean-up call was missing from test_hooks_do_run_for_source_freshness
initially, meaning the global active_deprecations
was preserved across tests, triggering deprecations erronously (and cluttering up the logs)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh that's interesting, updates look fine to me
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
(cherry picked from commit d4a6482)
resolves #10309
Problem
TestHooksInSourceFreshnessDisabled
passes when run viatests/functional/sources/test_source_freshness.py
, but fails independently.TestSourceFreshnessProjectHooksNotRun
, likely due to a shared global (deprecations
).Solution
deprecations
inTestSourceFreshnessProjectHooksNotRun
Checklist