Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:112988 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 61638 invoked from network); 25 Jan 2021 16:44:25 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 25 Jan 2021 16:44:25 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 449081804CF for ; Mon, 25 Jan 2021 08:25:41 -0800 (PST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_NONE autolearn=no autolearn_force=no version=3.4.2 X-Spam-Virus: No X-Envelope-From: Received: from darkcity.gna.ch (darkcity.gna.ch [195.49.47.11]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Mon, 25 Jan 2021 08:25:40 -0800 (PST) Received: from wafer.home (unknown [IPv6:2a02:1205:5053:a220:e1ca:d444:5aef:5dec]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by darkcity.gna.ch (Postfix) with ESMTPSA id 51F1E1517ABD; Mon, 25 Jan 2021 17:25:39 +0100 (CET) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.40.0.2.32\)) In-Reply-To: Date: Mon, 25 Jan 2021 17:25:38 +0100 Cc: PHP internals Content-Transfer-Encoding: quoted-printable Message-ID: References: <0edafce4-c9a5-c483-65f1-72e49614135a@telia.com> To: "G. P. B." X-Mailer: Apple Mail (2.3654.40.0.2.32) Subject: Re: [PHP-DEV] [RFC]: Change Default mysqli Error Mode From: cschneid@cschneid.com (Christian Schneider) Am 25.01.2021 um 16:59 schrieb G. P. B. : > The BC break is totally minimal as it's a one line of code that needs = to be added (and for all intent and purposes should already be done). That does not change the fact that it is a BC break which should be = treated accordingly. You are basically advocating people should add = mysqli_report(MYSQLI_REPORT_OFF) to their setup which will totally = defeat the purpose of the change. Or (probably more what you have in mind) that they should add = mysqli_report(MYSQLI_REPORT_ERROR) now (to prepare for the change) and = switch to MYSQLI_REPORT_ERROR | MYSQLI_REPORT_STRICT later once they = know they are ready. And this is exactly what I think should be done by the PHP default so = people don't have to go through this manually. > Moreover, I'd rather we get rid of the warning modes all together as = they make the least sense to me. > Either you're handling the failures explicitly anyway and you use the = silent mode, or you don't and want it to throw with the exception mode. This is where you are missing a key component: I want to go through a = phase where I will notice parts where manual error handling (or = exception handling after the change) is missing without having my = application abort. This is what warnings are good for. To some of us this is a very valuable step when upgrading. - Chris