Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c8FQf-00045C-MC for pgsql-hackers@arkaria.postgresql.org; Sat, 19 Nov 2016 23:52:17 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1c8FQf-0007u2-0i for pgsql-hackers@arkaria.postgresql.org; Sat, 19 Nov 2016 23:52:17 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1c8FPG-0006MW-NE for pgsql-hackers@postgresql.org; Sat, 19 Nov 2016 23:50:50 +0000 Received: from tamriel.snowman.net ([72.66.115.51]) by magus.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c8FPC-0006gf-18 for pgsql-hackers@postgresql.org; Sat, 19 Nov 2016 23:50:50 +0000 Received: by tamriel.snowman.net (Postfix, from userid 1000) id 656FF5F7AA; Sat, 19 Nov 2016 18:49:44 -0500 (EST) Date: Sat, 19 Nov 2016 18:49:44 -0500 From: Stephen Frost To: Tom Lane Cc: Daniel Verite , Rahila Syed , Ashutosh Bapat , pgsql-hackers Subject: Re: Improvements in psql hooks for variables Message-ID: <20161119234944.GD13284@tamriel.snowman.net> References: <20161119233603.GC13284@tamriel.snowman.net> <7464.1479599073@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="tNxygRpKsumvhHvm" Content-Disposition: inline In-Reply-To: <7464.1479599073@sss.pgh.pa.us> X-Editor: Vim http://www.vim.org/ X-Info: http://www.snowman.net X-Operating-System: Linux/3.13.0-91-generic (x86_64) X-Uptime: 18:48:35 up 134 days, 1:12, 25 users, load average: 0.03, 0.05, 0.05 User-Agent: Mutt/1.5.21 (2010-09-15) X-Pg-Spam-Score: -4.8 (----) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org --tNxygRpKsumvhHvm Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Tom Lane (tgl@sss.pgh.pa.us) wrote: > Stephen Frost writes: > > In reviewing this patch, I also noticed that it's set up to assume a > > 'true' result when a variable can't be parsed by ParseVariableBool. >=20 > I suppose that's meant to be backwards-compatible with the current > behavior: Ah, good point, however.. > but I agree that if we're changing things in this area, that would > be high on my list of things to change. I think what we want going > forward is to disallow setting "special" variables to invalid values, > and that should hold both for regular variables that have special > behaviors, and for the special-syntax cases like \timing. I completely agree with you here. We shouldn't be assuming "invalid" means "true". Thanks! Stephen --tNxygRpKsumvhHvm Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCgAGBQJYMOUYAAoJEO1sijiDR2RVO1YP/impOdHldw+Z0gCRIWcuKtN6 crkpk+vzCD1YL3I7S3O72RT+JiS5r8CqGGw6CsHkn0l6XyabifwmH7ZD88EhCUtO SnYvLEFmRC6XIdLTH7crF0DtE2dcQZYmHGOvy9sIQqrCgUgBBrubCuQyN0cs1UVs YYJCo0YRCxlaZ1T480A0gOYtKL3BG8XMgCLGeG3x2jYvOZkXmqnFoJRZ6Y/92e6J JCQewPzuHf4Dj08RlJmhRTEC4Uy1uZO4j9U11OFc1hnewKr16uR7FlSRea4j6Fnz Hmem7w0dH9FCIjTYAl/rJ2JqwdElWbWOoKXueBE0qcqywY3wXUjZjWWfbGGxb9If rkzYRmOZHETt07DCUJf6i08XOIjMDQy9cRAORTWT1p/tpxZuMKt+iH2BXhxrf6bV a3CUQed/uEbLFgqfgo+SlXm1TMKs/J+QiDc/P3PcXk9GOaNpphgUEuJdHq8EcRo1 ezasf9/h6JpmSlykZbYzxdWKW4vxx+3W3BC04VTPcL1UUrYd8FC3GnpJRaHTM6/N PzOLlfq707CJ1mJEPkzQ4j5zE6L6fCqzc/ozYcrAOnVkS5IGRghjD7asUnnVLNJD rIn25cxijUIdJwDX7ufhTVjXYcAZ8eTyGVN3CmgUu94pdUJ7PwexsX435VvimBjo T1AWEn4GplD6E1+9UD6k =GIvX -----END PGP SIGNATURE----- --tNxygRpKsumvhHvm--