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 1nJOMc-0005oY-FG for pgsql-hackers@arkaria.postgresql.org; Sun, 13 Feb 2022 23:33:06 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nJOMb-00021p-C8 for pgsql-hackers@arkaria.postgresql.org; Sun, 13 Feb 2022 23:33:05 +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 1nJOMb-00021g-2z for pgsql-hackers@lists.postgresql.org; Sun, 13 Feb 2022 23:33:05 +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 1nJOMY-0003Rh-Rf for pgsql-hackers@postgresql.org; Sun, 13 Feb 2022 23:33:04 +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 21DNWxJV2744435; Sun, 13 Feb 2022 18:32:59 -0500 From: Tom Lane To: Andres Freund cc: pgsql-hackers@postgresql.org Subject: Re: bailing out in tap tests nearly always a bad idea In-reply-to: <20220213232249.7sevhlioapydla37@alap3.anarazel.de> References: <20220213232249.7sevhlioapydla37@alap3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Sun, 13 Feb 2022 15:22:49 -0800" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2744433.1644795179.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Sun, 13 Feb 2022 18:32:59 -0500 Message-ID: <2744434.1644795179@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Andres Freund writes: > Does anybody want to defend / explain the use of BAIL_OUT? If not, I thi= nk we > should consider doing a global replace of the use of bailing. +1 > Best with a > central function signalling fatal error, rather than individual uses of = die > or such. Huh, doesn't Test::More already provide a sane way to do this? If not, why isn't die() good enough? (I don't think you can realistically expect to prohibit die() anywhere in the TAP tests.) regards, tom lane