Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:118495 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 52447 invoked from network); 26 Aug 2022 09:35:45 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 26 Aug 2022 09:35:45 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 67EBA1804A9 for ; Fri, 26 Aug 2022 02:35:45 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-ua1-f47.google.com (mail-ua1-f47.google.com [209.85.222.47]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Fri, 26 Aug 2022 02:35:45 -0700 (PDT) Received: by mail-ua1-f47.google.com with SMTP id q21so358062uam.13 for ; Fri, 26 Aug 2022 02:35:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc; bh=85KUFYPlVJqNGaE6qhldcqclDljjJeljtRRt/2SspAk=; b=dCnSa8+Bak5ayEGTUUDU3AGdBBFDcSwxahrgJviQXz1rDlazPUF+ZHjRWNoRH1tzvA Vwfsljjwnm2mPdGwchrbrslcSQ01AZKGw9N+Yl/w7aDuG3Y4oSzfhoKOmL6xsDI+/Z35 SW4yEy+AuLQjJpYC5Ptknz2Qu2h2EAG0QsiX2usHHPgp+YPl88AbJhMhiRu2UBPjgQ2o CnoXNe9fcwMnjj5dN76TKwAAslFXPP1cNzrW/R6b6acyXC8uZNg+6/NSGTcDL9JpcWfn IebLFbxJ1fX6eirTwz2QsVavE8SEa2QRpMB35NlOZDAoidjOKmgvbk+b+4hsw7YRfFkQ auNQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc; bh=85KUFYPlVJqNGaE6qhldcqclDljjJeljtRRt/2SspAk=; b=pkr+Ne1UM4rGsKoyBmEEK7vLb5y72f9khQ8RRluywX83AJstDxgVkWRfyKik6LN9Dx ZDUhG3Q4clMyCw14smyP418XPUrqHANeAv35wkJNJv55EU3VmPL8b+E1Ed+JtacvICpz ijd2afyDhuaftR6Ffp2AI5fcPZvM0A48/BVulAGoM0iA9Zh6ophaQxXodzpulxAl06qM rIzjsj7asnBp1maiL7AaoODejz+fxawuDDGBxWCeBBCJHolG5wh6myxwCzpeOVnlQKYu KDbsGJXdVSPSsMpnmlL0gCPrUJnb4QWmKIl4Lei0ch3YcbqqeflngEroZxSFyzCAeLWS mxxA== X-Gm-Message-State: ACgBeo04C9nXhGo41S5/bSmAMKCXUcnxWqojQIKzEoEfZv/Ng9ubMuJj HqkBp1u2gN/E3ME1XMOxGACvJjznL+UnTRzZmr8= X-Google-Smtp-Source: AA6agR6EIpehe6ROtqm79awiIUefEvxNcYhajsGzcl4rD9+d37wBne1EyLJuGQg59XEdiNQCsCJykj5gUYpqkw4YiRE= X-Received: by 2002:ab0:6609:0:b0:39f:64d0:2b6d with SMTP id r9-20020ab06609000000b0039f64d02b6dmr930498uam.16.1661506544773; Fri, 26 Aug 2022 02:35:44 -0700 (PDT) MIME-Version: 1.0 References: <8D53AD5B-7CFC-4820-9EE4-FEB365D327A8@woofle.net> In-Reply-To: Date: Fri, 26 Aug 2022 11:35:33 +0200 Message-ID: To: juan carlos morales Cc: Dusk , David Gebler , PHP Internals List Content-Type: multipart/alternative; boundary="00000000000064ae5105e721a3c1" Subject: Re: [PHP-DEV] RFC json_validate() - status: Under Discussion From: michal.brzuchalski@gmail.com (=?UTF-8?Q?Micha=C5=82_Marcin_Brzuchalski?=) --00000000000064ae5105e721a3c1 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Juan, pt., 26 sie 2022 o 11:26 juan carlos morales napisa=C5=82(a): > El vie, 26 ago 2022 a las 11:00, Micha=C5=82 Marcin Brzuchalski > () escribi=C3=B3: > > > > A `json_decode()` is a substitute that IMO solves 99% of use cases. > > If I'd follow your logic and accept every small addition that handles 1= % > of use cases, somebody will raise another RFC > > for simplexml_validate_string or yaml_validate and the next > PhpToken::validate. > > All above can be valid if we trust that people normally validate 300MB > payloads to do nothing if they DON'T fail and there is nothing strange > about that. > > > > Cheers, > > > > How can you make such an assertion in those numbers (99% of use cases > and son on, that you mention) ? Can you give us more information about > this assertions? > > I have provide real examples where the need to validate-only a > json-string is actually needed, also the need from our developers > community asking for this. > Your examples are a couple of functions. Assuming that they're heavily used is as true as my assumptions. Cheers, --00000000000064ae5105e721a3c1--