Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:124096 X-Original-To: internals@lists.php.net Delivered-To: internals@lists.php.net Received: from php-smtp4.php.net (php-smtp4.php.net [45.112.84.5]) by qa.php.net (Postfix) with ESMTPS id 52DE71A009C for ; Sun, 30 Jun 2024 14:15:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1719757021; bh=75Bww3BQuw5j1k+fcS7SMKqGDD7JwXy4ZSs6/NafWls=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=dEKBaOZ/dIItXKVHQ4tUGeEFLgVOL8VRadg19awhtM4YLhJUPOqRScZVVAN4eysYB eBVdziCR4tfZ6r8/uf5Tq+kn8ctb2jIi435E93Df71C4vhB4x3awNoCV7IRS0U6x9E 4jv5e6NV8J/Ldsj3cFWONDdYOpshZ0HaG/lKLhGYFcotDkAwkLS0nj7NBYm6psiS/V f+dAVRbm4PAqSDd+md+WHTjwIGKCrvZ4msrHRxctqjkGokxEYFs8jGs9JNiHLBO8mc t3ghY21017GE2fbHtW+47uxpK9ipEHDDuV5lZEzJJAGpMm33X+uCgQZtDoX0s3om/P nfXR8lK4lFqCg== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 74386180C03 for ; Sun, 30 Jun 2024 14:16:58 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=0.6 required=5.0 tests=BAYES_50,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_PASS,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: Error (Cannot connect to unix socket '/var/run/clamav/clamd.ctl': connect: Connection refused) X-Envelope-From: Received: from chrono.xqk7.com (chrono.xqk7.com [176.9.45.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Sun, 30 Jun 2024 14:16:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bastelstu.be; s=mail20171119; t=1719756936; bh=xxxY+iyZfl2c/AjsZVEaJckayBCYmtNKkKndnPvxeys=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type:from:to:cc:subject:message-id; b=dsKGbFPFUSnpDuP4GAUOdB7bW79ObqdWzpgN+mU1TwNTmLNL9qRkr6mOZdj59mCcp I6EH3UyQSQI5D4iep7lYWZdRRGOl4EPkHJmigBdnHht0MnvUzTM8sGHgcf7AXpTiA3 zPSf5aQ9aMU5p1trdn7xYbPX8LZ8Fc93FNzP1FwlYA5yJoWo1U/T0SOAjyfK4B8eTW OKkQPdYHSX/Za45Ubk8P3fUWBn1deV1wapo+XMTY4gLVr/z2fE3KdxnKEgomYuYIiV CMcAD/GcKYJLHSB0N1G0wEosa4Tb4PFHlilJNeYHZAi9cWzzdSDoLbm5DVW1NV4/px uYm/p+11GqhcA== Message-ID: Date: Sun, 30 Jun 2024 16:15:35 +0200 Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net MIME-Version: 1.0 Subject: Re: [PHP-DEV] [RFC][Discussion] Enhance JSON error messages To: juan carlos morales Cc: "Gina P. Banyard" , PHP Internals List References: <66420855-9900-48a8-9964-b9dda81a8bdc@bastelstu.be> Content-Language: en-US In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit From: tim@bastelstu.be (=?UTF-8?Q?Tim_D=C3=BCsterhus?=) Hi On 6/30/24 15:43, juan carlos morales wrote: > So, what I see here in my shortexperiencie is an RFC with 3 Options That is not an option. Each RFC needs a clear primary vote that is a "Yes/No" vote. > 1) Enhance the error message we already have > > 2) keep json_last_error_msg as it is and add a new function > json_last_error_info function > > 3) both > Adjusting error messages to make them better is not something that requires an RFC. We do this all the time without an RFC. Here's an example PR: https://github.com/php/php-src/pull/14496 A new json_last_error_info() for easier programmatic access of the important bits can still be considered, but would not need an RFC either from my point of view. It's a simple and obvious addition. Those can be done without an RFC, unless someone complains. Best regards Tim Düsterhus