Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:116332 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 55441 invoked from network); 12 Nov 2021 16:53:35 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 12 Nov 2021 16:53:35 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 8530C1804B5 for ; Fri, 12 Nov 2021 09:47:34 -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.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,FREEMAIL_REPLY, HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE, SPF_PASS 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-f52.google.com (mail-ua1-f52.google.com [209.85.222.52]) (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 ; Fri, 12 Nov 2021 09:47:30 -0800 (PST) Received: by mail-ua1-f52.google.com with SMTP id v3so20366937uam.10 for ; Fri, 12 Nov 2021 09:47:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=PnUsqQ5w5jKDv919/33rfP/TyQt8w3RtUZbWDwKB/do=; b=a+mwQWeGxzrfe6XPSxua2mQZ2Gj0TeIOoUGVqkshS9O/TdlA/P5L3OPLHto3gkIgkH wx3DF4d1ZzU9ggkoQXqNz71SQyL7zXBAFMCbdBwQ+XHuFEJeCJ3aLQVyodNJqrYJU6gs Zl6+LxA2BxGQIOW5Lfx8jAKP43pmggEnOQh4baXb4yDo4gAjvUsi82qN/phk0IpgqP13 WwYv/mW6HL/51i6BzVsb+dim6Auhq6BgbrXzVne8DjF7z3EjeeMpNClsInyiIurBCKpV ErqPP9L/9AZii35JxMuXev1c+/isp+7eIPxegMTJn9RFO2oEfCAqz0t82TUC87J2CXai uk8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=PnUsqQ5w5jKDv919/33rfP/TyQt8w3RtUZbWDwKB/do=; b=EkJuRuv1UcSb1sKAr9qpyeDaj1jnlQgQo+sMl1oaR62BMTpiBsjBSUqqZ1Z5pA/qo7 6Cp8sTTxAo+Be/zxhggaOSIVIn+8uOwKRkGNHtw0y4gX2TPa5UZaEn41vROLn8Wvo6Au GBmpM9BzZw0EkYeOqG0so5jx1DVebSh2UGvVVUiUthK/yn6J4ONKEYJ7PUxlvYz/L/fz iFKYIbQYWsWg4sj5i3KF8nrZoWlc9Ua4IrBhhOEUAavUe9S/fWb+BGA5Rdt/x/5I1dM9 zVITThUHgLxIa7xdH43GCigLHEz63BnjtGb+myoCPcWgV15nmKMBk9ZhJGpg3y8HEYDZ +0TA== X-Gm-Message-State: AOAM532U4tNGC/+CkUNAp+Y11o0FLQKUSICG41bezsLmIuUjMB83h1jR GjhdqZ+febEcg5CQRdz0xhREUo+RAHCtS/+vU6fXPQ8e6W0= X-Google-Smtp-Source: ABdhPJyMf+skqoeTPR5RsRdqIhmmxB//ZUNxZrRi1LThKGOrCnHgULXu2ImrU0OYuImGcGYJSzDsR7UZwL9JF91O8ro= X-Received: by 2002:a67:ed07:: with SMTP id l7mr12202546vsp.40.1636739249969; Fri, 12 Nov 2021 09:47:29 -0800 (PST) MIME-Version: 1.0 References: <0A40B090-43E3-484F-B67F-175C3B8F7CD6@php.net> In-Reply-To: Date: Fri, 12 Nov 2021 12:47:17 -0500 Message-ID: To: Larry Garfield Cc: php internals Content-Type: multipart/alternative; boundary="00000000000095b60c05d09b0db9" Subject: Re: [PHP-DEV] [VOTE] Deprecate dynamic properties From: chasepeeler@gmail.com (Chase Peeler) --00000000000095b60c05d09b0db9 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, Nov 12, 2021 at 12:44 PM Larry Garfield wrote: > On Fri, Nov 12, 2021, at 10:56 AM, Nikita Popov wrote: > > On Fri, Nov 12, 2021 at 5:34 PM Nikita Popov > wrote: > > > >> On Fri, Nov 12, 2021 at 5:25 PM Ben Ramsey wrote: > >> > >>> > On Nov 12, 2021, at 10:10, Derick Rethans wrote: > >>> > > >>> > On 12 November 2021 13:07:42 GMT, Nikita Popov > > >>> wrote: > >>> >> Hi internals, > >>> >> > >>> >> I've opened the vote on > >>> >> https://wiki.php.net/rfc/deprecate_dynamic_properties. Voting will > >>> close > >>> >> 2021-11-26. > >>> > > >>> > I've voted no on this one. Not because I don't like the idea, but > >>> because I think the timeline for deprecation and removal is way too > fast. > >>> > > >>> > This is IMO not something important enough to cause a fairly large = BC > >>> break for, and it should wait until the last in the 8.x series before > we > >>> deprecate it. > >>> > > >>> > cheers > >>> > Derick > >>> > >>> > >>> I=E2=80=99ve voted no for the same reason. > >>> > >>> I like this change, but the deprecation in 8.2 seems too disruptive. > I=E2=80=99d > >>> rather promote our intent to deprecate this with a statement in the > >>> manual that says something like, =E2=80=9CThis feature will be deprec= ated in > >>> PHP 8.3 and removed in 9.0.=E2=80=9D > >> > >> > >> FWIW I think we should always deprecate things as soon as possible, to > >> give people the maximum amount of awareness and time to address the > issue > >> before the actual removal occurs. Most people will not be aware they > need > >> to take action if it's just a note in the manual. For that reason, I > find > >> it generally preferable to deprecate something closer to PHP 8.0 than = to > >> 8.4, which would be directly before a major version with limited time = to > >> act. Now, we don't usually tend to optimize for "time of deprecation" > >> because that requires planning deprecations many years in advance, but > if > >> the choice existed I'd always go for deprecating early in the major > release > >> cycle, rather than late. > >> > > > > Another thing I want to add here is that in this instance, I think that > the > > deprecation warning is really helpful for updating your code. It tells > you > > exactly which property on which class is being created dynamically, so > you > > can quickly go through these and add missing property declarations or > > #[AllowDynamicProperties] attributes. Without the deprecation warning i= n > > place, you need a static analyzer to find problematic cases. And of > course, > > that only works well if you already have a fully typed code base that i= s > > reasonably clean under static analysis. At the same time, this change i= s > > most likely to affect projects where this is not the case. If you are > > already using a static analyzer, you probably don't use dynamic > properties > > anyway, as these things tend to be incompatible. > > > > Regards, > > Nikita > > Also a reminder that deprecations are not errors; PHPUnit very recently > changed to not complain about deprecations by default. And anyone runnin= g > with deprecations on in production is doing it wrong and will get bitten > whenever the deprecation is enabled. > > I have to agree with Nikita here. Give people as much deprecation time a= s > possible; if people are misunderstanding deprecations and abusing them, > that's... a different problem that cannot be solved by not issuing > deprecations. > > --Larry Garfield > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: https://www.php.net/unsub.php > > I don't think this should be deprecated or removed at all. However, I agree that if it is going to be removed, the more time/versions that exists between deprecation and removal, the better. --=20 Chase Peeler chasepeeler@gmail.com --00000000000095b60c05d09b0db9--