fix(date_parser): suppress noisy parsedatetime DEBUG logs (#33365)#40144
Conversation
Closes #33365 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Code Review Agent Run #8c7184Actionable Suggestions - 0Additional Suggestions - 1
Review Details
Bito Usage GuideCommands Type the following command in the pull request comment and save the comment.
Refer to the documentation for additional commands. Configuration This repository uses Documentation & Help |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #40144 +/- ##
=======================================
Coverage 64.17% 64.17%
=======================================
Files 2590 2590
Lines 138087 138088 +1
Branches 32039 32039
=======================================
+ Hits 88615 88616 +1
Misses 47947 47947
Partials 1525 1525
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
`parsedatetime` emits 'eval now with context - False, False' at DEBUG on every relative-date evaluation. Superset has no actionable use for that internal trace, and it floods production logs whenever the root logger is at DEBUG (a configuration the user reports hitting in #33365 and that appears in dozens of other unrelated issue threads). Pin the library's own logger to WARNING at module load. Real failures still surface — just not the per-call chatter. The companion test added in this PR's earlier commit asserts no DEBUG records from `parsedatetime` are emitted during `datetime_eval`. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Code Review Agent Run #fb20a7Actionable Suggestions - 0Review Details
Bito Usage GuideCommands Type the following command in the pull request comment and save the comment.
Refer to the documentation for additional commands. Configuration This repository uses Documentation & Help |
SUMMARY
Closes #33365.
parsedatetimeemits a noisy DEBUG record (eval now with context - False, False) on every relative-date evaluation that runs throughdatetime_eval. Superset has no actionable use for that internal library trace, and it floods production logs whenever the root logger is at DEBUG. The reporter notes the line appears in dozens of unrelated issue threads, so this hits a wide range of deployments.This PR:
parsedatetimelogger to WARNING at module load insuperset/utils/date_parser.py(one-liner). Real failures still surface — just not the per-call chatter.test_datetime_eval_does_not_emit_parsedatetime_debug_logs) that captures all log records at DEBUG level during a singledatetime_evalcall and asserts none come from theparsedatetimelogger. Locks in the suppression so a future refactor that drops thesetLevelcall fails CI immediately.BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
N/A — log-volume change only. Verified locally:
(Before the fix:
parsedatetime records: 1.)TESTING INSTRUCTIONS
ADDITIONAL INFORMATION
🤖 Generated with Claude Code