Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:120352 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 46851 invoked from network); 18 May 2023 21:56:13 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 18 May 2023 21:56:13 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 8A5A2180506 for ; Thu, 18 May 2023 14:56:10 -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=0.8 required=5.0 tests=BAYES_20,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE, MISSING_HEADERS,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-wr1-f46.google.com (mail-wr1-f46.google.com [209.85.221.46]) (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 ; Thu, 18 May 2023 14:56:10 -0700 (PDT) Received: by mail-wr1-f46.google.com with SMTP id ffacd0b85a97d-30626f4d74aso1728224f8f.0 for ; Thu, 18 May 2023 14:56:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684446969; x=1687038969; h=content-transfer-encoding:mime-version:message-id:references :in-reply-to:user-agent:subject:cc:from:date:from:to:cc:subject:date :message-id:reply-to; bh=Uu2CNncd3EDgxdVun/Jbbwy21kMqp6Kqc0QoHfU8umE=; b=VfKj/2OPgL1hze3rBK6bW8bcCoZP3WTX5fdNQlZ6XczGRLz8rc1P0N9L1xeEGVMkJX tCwpbs6FPpp7LRi59GPOrgPPjlJXlWodgEFgU26dultif8A+WY9zKqGsNssPVhRlSXuF zgIUhGSKMHZid7c+J7G9qVL6iQ9fFkZr4URpJOyOeRB9tE4mWyz0JAnCpC2L6ruPHkeW aI511VEHs1Dz6KkEB0Voq6SPI3uFW38RIBtkA2IsSLgJr/gzsozU9dK2voz8uUccaRsz YpxLZuOyeZdmF70GL+s+LFLL2xDhjXIrOyVbZWCIlmcUNBPM2RKGvB0D1oAely4MIjIc XXOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684446969; x=1687038969; h=content-transfer-encoding:mime-version:message-id:references :in-reply-to:user-agent:subject:cc:from:date:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=Uu2CNncd3EDgxdVun/Jbbwy21kMqp6Kqc0QoHfU8umE=; b=REdmOzLF6KNZ/V98zml73OjhnisutfFUSUH5iUbQF9P5sPzoydSsoi9Vpqg027nBTy 1dFuZHA0MMelcd+AUAtWAqRUnngHYjBLKtVUtBCf/6F3Y2Y3asqRmlKjQEjS1dUdO+Xd zXTmO8M3E6uAlbYxN0nvwLrszFp74PJ4wnknr3AxQ+a8spdgGrHtTMXXisPUxy/LC7I7 2ezqlPdNRjeQpMr6KLhnKDVaSLNvRJqgwoXGiJp38YULLdpkt7HXkvZ3MAAoUl29eVqL HhGK6KuViRjgYsaNhGFdfjX+/dgeRT1K3I9BwqJ15dq/+R+O42EHRN2Ig4h0Ceyndvt1 NYPQ== X-Gm-Message-State: AC+VfDz2M3sFAghY/9+Z+bnELxkjb6GNxgN7tSDsbXFzVJkW1SjcF+Mj YcxN3WXMDh74+FVg0Z76SigJsEzTJTo= X-Google-Smtp-Source: ACHHUZ6l7BzSOn9XLZZMLCG7lW4Dotgm1iJN95Ec/SlyUH1iFegVb077NetYrustf8/Thxnnh9gxcg== X-Received: by 2002:adf:f74d:0:b0:307:bd64:f5a4 with SMTP id z13-20020adff74d000000b00307bd64f5a4mr135796wrp.52.1684446968733; Thu, 18 May 2023 14:56:08 -0700 (PDT) Received: from [127.0.0.1] (cpc83311-brig21-2-0-cust191.3-3.cable.virginm.net. [86.20.40.192]) by smtp.gmail.com with ESMTPSA id w4-20020a5d4b44000000b00307a86a4bcesm3282574wrs.35.2023.05.18.14.56.08 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 18 May 2023 14:56:08 -0700 (PDT) Date: Thu, 18 May 2023 22:56:07 +0100 CC: PHP internals User-Agent: K-9 Mail for Android In-Reply-To: References: <000201d9897f$aa9f9fa0$ffdedee0$@roze.lv> Message-ID: <3021A824-1EDC-4523-814A-A0DA8187F068@gmail.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary=----0PXZPO96UPLBOFI7RF1FPFYS4N4YME Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] PHP Package for PHP From: rowan.collins@gmail.com (Rowan Tommins) ------0PXZPO96UPLBOFI7RF1FPFYS4N4YME Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 18 May 2023 20:15:44 BST, Deleu wrote: > I meant exactly the opposite=2E Monolog is an example of what PHP (is mi= ssing > =3D=3D=3D doesn't have enough of)=2E There's hardly any reason to re-rel= ease it > under the PHP umbrella=2E Monolog already won the log battle=2E I can't = say the > same for virtually anything else, to be honest=2E Some folks might say t= hat > Guzzle won the HTTP battle, I just disagree and think we could have > something better by default Let's look at HTTP clients then=2E PHP is certainly lacking a good one built in=2E Using streams with allow_u= rl_fopen is serviceable for fetching a page, but not much else; the curl fu= nctions are =2E=2E=2E embarrassing=2E On the other hand, Guzzle has gone through 7 major version bumps in 12 yea= rs, presumably believing that each improvement justified the disruption to = users=2E And even then, as you point out, Symfony decided to write their ow= n HttpClient component=2E Clearly, they didn't do that because they didn't = know Guzzle existed; presumably, they thought it still wasn't good enough= =2E An extension or library fully bundled with PHP would have no hope of compe= ting with that=2E A major version could only be made every 5 years, and eve= n then breaking changes have to be minimised, so we would really have one c= hance to somehow improve on what others have spent years refining=2E On the other hand, a clean API with a much smaller feature set, which coul= d be used on its own for simple use cases, and be the low level implementat= ion for Guzzle, Symfony HttpClient, etc, would be extremely useful=2E In ot= her words, an overhaul of the curl functions to give the same flexibility, = but an API that feels more native to PHP, rather than a thin wrapper around= the C functions of libcurl=2E Whether it would make sense to do that in PHP, I'm not so sure=2E It would= mean that any fundamentally new feature would need implementing twice: onc= e in C, in the existing clunky API, then again in PHP, to wrap it into a di= fferent style=2E On the other hand, it would make polyfilling the new API t= rivial, and have a wider pool of contributors who could work on it - as lon= g as they didn't hit a limitation that needed to be fixed in the C layer=2E Regards, --=20 Rowan Tommins [IMSoP] ------0PXZPO96UPLBOFI7RF1FPFYS4N4YME--