Re: pgsql: Include GUC's unit, if it has one, in out-of-range error message
Michael Paquier <michael@paquier.xyz>
From: Michael Paquier <michael@paquier.xyz>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-committers@lists.postgresql.org
Date: 2019-03-11T01:11:14Z
Lists: pgsql-hackers
On Sun, Mar 10, 2019 at 07:18:20PM +0000, Tom Lane wrote: > Include GUC's unit, if it has one, in out-of-range error messages. > > This should reduce confusion in cases where we've applied a units > conversion, so that the number being reported (and the quoted range > limits) are in some other units than what the user gave in the > setting we're rejecting. > > Some of the changes here assume that float GUCs can have units, > which isn't true just yet, but will be shortly. It does not seem to have cooled down all animals yet, whelk is still complaining: https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=whelk&dt=2019-03-11%2000%3A41%3A13 -ERROR: -Infinity is outside the valid range for parameter "geqo_selection_bias" (1.5 .. 2) +ERROR: invalid value for parameter "geqo_selection_bias": "-infinity" It would be nice if we could avoid an alternate output. -- Michael
Commits
-
Give up on testing guc.c's behavior for "infinity" inputs.
- d9c5e9629bf5 12.0 landed
-
In guc.c, ignore ERANGE errors from strtod().
- b212245f9643 12.0 landed
-
Include GUC's unit, if it has one, in out-of-range error messages.
- 28a65fc3607a 12.0 cited