Skip to content
← All reviews
sqlalchemy/sqlalchemy #13435 · Yijian6 · 4mo ago

Add log_note execution option

Needs attention1 finding · openOpen the pull request on GitHub ↗
Panel verdict

The panel surfaced issues that deserve attention before merge.

1
raised by reviewers
1
kept by the panel

Findings

HighCorrectnessconfidence 1.00

Abstract method _get_log_note breaks custom ExecutionContext subclasses

The PR adds _get_log_note as an abstract method on ExecutionContext with no default implementation (raises NotImplementedError). Only DefaultExecutionContext provides an implementation. Any third-party dialect or custom context that subclasses ExecutionContext directly (not DefaultExecutionContext) will raise NotImplementedError when self._echo is True and logging occurs. This is a breaking change for such subclasses and will cause runtime errors in production if logging is enabled. The fix is to provide a default implementation in ExecutionContext that returns "" (empty string) to maintain backward compatibility.

3 reviewers · deepseek/deepseek-v4-flash · reviewed in 37s · 10 files, +219 −4

Ship the PR.
Skip the noise.

Free on 2 repositories · No credit card · Advisory only—never blocks a merge