model-writtenrun 491 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Junwen An reported that COVAR_POP, COVAR_SAMP, and REGR_SXY incorrectly returned zero when one input was constant and Infinity appeared after the first row, reproducing the regression on PostgreSQL 19 betas and 20 development but not 18.4 #1.
- Andrey Rachitskiy traced the problem to skipping the Sxy update for constant inputs and supplied a patch that explicitly forces Sxy to NaN for Inf/NaN inputs while preserving exact zero for finite constant inputs, with regression tests #2.
- Tom Lane independently confirmed that the missing special-value handling affected Sxy, while Sxx and Syy were already handled correctly #3.
- Tom Lane committed the patch as 94f94b245c, retaining the logic from #2, revising the comment, and replacing the tests with finite-input and Inf/NaN position checks; the commit specifies backpatching through PostgreSQL 19.
- Tom Lane announced that the fix had been pushed after comment and test adjustments, leaving no outstanding work identified in the thread #4.