Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:116387 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 22245 invoked from network); 15 Nov 2021 19:07:57 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 15 Nov 2021 19:07:57 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 93F8D1804AC for ; Mon, 15 Nov 2021 12:02:43 -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=-0.7 required=5.0 tests=BAYES_05,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 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-lf1-f50.google.com (mail-lf1-f50.google.com [209.85.167.50]) (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, 15 Nov 2021 12:02:43 -0800 (PST) Received: by mail-lf1-f50.google.com with SMTP id c32so46649686lfv.4 for ; Mon, 15 Nov 2021 12:02:43 -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=R/f3nFo7H88wdZcOAeG5I7WznVSMQ/aoK72QQP2iAyg=; b=CnwWOJDaWOLRgeOcALl1uonVQ0hIQdQGJ3d7ArGLF6GxOCJ4luc+cABDDAdDaPNVFf p8YNYqPHaNfUC3EX8NBffH+en2usXAOGPBOqX3DL89T/UPyc02NY4OApjOauhr/6xbZD 1fCwspsMd3f6tkf08zktulA2Bni1W6aCbxI6d2BpfSrRorW6SxnIUo3iWr+w+HB8Z/Eh 3WSyCxVujIFbp3hu1uFZSHZuqz37HOQ/O+pxuYB/1GgYCJPnYM+/E1nBJhPAzkViz3Pe uUC1W51GJBB1/n33oVR74wlVF9DlcaQd74sy6yoG097dKXHncPhk4qz78HzMwUg9+YBi +s7A== 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=R/f3nFo7H88wdZcOAeG5I7WznVSMQ/aoK72QQP2iAyg=; b=ps9kNmB0aJZ0ybeBOWe9a28d3VFEznQhYFU3SuWY2bOT+TuqVk8yUBO5gKDsSq4T5l NmFZrG/L/5xrtjLAiaCE3aO6mGMOcNytEhk/7j4QVNpPM0S/ewQSBhXMh4xjKuWTCrGy KiejNOUTPUu8Gxf3x4cCyxzRVLu3OqkaFKUcQFp3ueGQN3RexYR95Hirgp9SwNJA6jkr eoALra7OgbcKCYLf77l/yhdQBzk3zo7pcJsrUdo9fZOUWYpqL8TvjkjdMvyID3rXVoJh 1BKB3mIjkhdhXtIEeEs0boQusAgcCPuMGP5HGMnRlN3OLVe9E5xRilbQPSpx9L0KLkYQ od3g== X-Gm-Message-State: AOAM530+HAQd3V8dyDSrIXgp232gB8utOaM12ir/DQld50+ojesrlXVm ucPTIZF40C+j4eXhnKGK2RoRNyssYi3AETq3CTw= X-Google-Smtp-Source: ABdhPJwMWWXujDKY0Lbb8tZxXYUgUicR9pMdGlG6eVdXPAgO77lpo56qzSmRjW3oh30HUtPnfkAgNRPqcGYWGEx+R7s= X-Received: by 2002:a05:6512:3d1d:: with SMTP id d29mr1213471lfv.685.1637006561164; Mon, 15 Nov 2021 12:02:41 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: Date: Mon, 15 Nov 2021 14:02:29 -0600 Message-ID: To: Derick Rethans Cc: PHP internals , Nikita Popov Content-Type: multipart/alternative; boundary="00000000000092bfb105d0d94ab8" Subject: Re: [PHP-DEV] Re: [RFC] Deprecate dynamic properties From: neclimdul@gmail.com (James Gilliland) --00000000000092bfb105d0d94ab8 Content-Type: text/plain; charset="UTF-8" On Mon, Nov 15, 2021 at 3:53 AM Derick Rethans wrote: > Dear Internals, > > On Wed, 10 Nov 2021, Nikita Popov wrote: > > > On Wed, Aug 25, 2021 at 12:02 PM Nikita Popov > wrote: > > > > > This RFC takes the more direct route of deprecating this > > > functionality entirely. I expect that this will have relatively > > > little impact on modern code (e.g. in Symfony I could fix the vast > > > majority of deprecation warnings with a three-line diff), but may > > > have a big impact on legacy code that doesn't declare properties at > > > all. > > > > > > > I plan to open voting on this RFC soon. Most of the feedback was > > positive, apart from the initial choice of opt-int mechanism, and that > > part should be addressed by the switch to the > > #[AllowDynamicProperties] attribute. > > The voting is now open, but I think one thing was not taken into account > here, the many small changes that push work to maintainers of Open > Source library and CI related tools. > > In the last few years, the release cadence of PHP has increased, which > is great for new features. It however has not been helpful to introduce > many small deprecations and BC breaks in every single release. > > This invariably is making maintainers of Open Source anxious, and > frustrated as so much work is need to keep things up to date. I know > they are *deprecations*, and applications can turn these off, but that's > not the case for maintainers of libraries. > > Before we introduce many more of this into PHP 8.2, I think it would be > wise to figure out a way how to: > > - improve the langauge with new features > - keep maintenance cost for open source library and CI tools much lower > - come up with a set of guidelines for when it is necessary to introduce > BC breaks and deprecations. > > I am all for improving the language and making it more feature rich, but > we have not spend enough time considering the impacts to the full > ecosystem. > > I have therefore voted "no" on this RFC, and I hope you will too. > > cheers, > Derick > I appreciate that Derick. I know there have been some pretty big efforts required for some recent php updates in Drupal. And I've mentioned in a couple threads on Twitter but Drupal requires a pretty heavy change to support this. It adds properties to classes _outside_ its codebase which means none of the mitigations in the RFC apply. It was on my radar when the vote popped up because the system in question has long been known to be less than ideal but "php wouldn't ever remove this ancient feature right?" and every other option is just a ton more complicated. I've talked with some maintainers and it looks like we're going to deal with the cost of converting the system but if this dirty hack hadn't been on our radar it could have really hurt. Like maybe not getting the fix in place before the next major release in time for backwards compatibility commitments bad. So I worry what sort of earthquake this might trigger through libraries. Like, I'm pretty sure the OpenApiGenerator templates used dynamic properties for some things so how many little internal libraries are going to have to be regenerated? What other lightly maintained library are people going to be stuck waiting to update because someone's CI didn't catch the deprecation? I think this sort of change is probably for the better, but I worry about how disruptive this could end up being. --00000000000092bfb105d0d94ab8--