Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1no5k8-0000d6-1O for pgsql-hackers@arkaria.postgresql.org; Mon, 09 May 2022 15:56:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1no5k6-0001jh-ID for pgsql-hackers@arkaria.postgresql.org; Mon, 09 May 2022 15:56:14 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1no5k6-0001jY-8Y for pgsql-hackers@lists.postgresql.org; Mon, 09 May 2022 15:56:14 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1no5k4-0005rU-9u for pgsql-hackers@lists.postgresql.org; Mon, 09 May 2022 15:56:13 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 249Fu5RQ3813351; Mon, 9 May 2022 11:56:05 -0400 From: Tom Lane To: Peter Eisentraut , Fabien COELHO cc: pgsql-hackers@lists.postgresql.org Subject: psql now shows zero elapsed time after an error MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3813349.1652111765.1@sss.pgh.pa.us> Date: Mon, 09 May 2022 11:56:05 -0400 Message-ID: <3813350.1652111765@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Example (you need up-to-the-minute HEAD for this particular test case, but anything that runs a little while before failing will do): regression=# \timing Timing is on. regression=# select * from generate_series('2022-01-01 00:00'::timestamptz, 'infinity'::timestamptz, '1 month'::interval) limit 10; ERROR: timestamp out of range Time: 0.000 ms That timing is wrong. It visibly takes more-or-less half a second on my machine, and v14 psql reports that accurately: regression=# \timing Timing is on. regression=# select * from generate_series('2022-01-01 00:00'::timestamptz, 'infinity'::timestamptz, '1 month'::interval) limit 10; ERROR: timestamp out of range Time: 662.107 ms While I've not bisected, I think it's a dead cinch that 7844c9918 is what broke this. regards, tom lane