- Issue created by @agoradesign
- Status changed to Needs review
about 1 year ago 8:01pm 7 November 2023 - 🇬🇧United Kingdom 2dareis2do
Thanks.
This seems to work for me.
Interesting article on php 8.2. and dynamic properties here https://stitcher.io/blog/deprecated-dynamic-properties-in-php-82
- 🇬🇧United Kingdom 2dareis2do
Ok looking at https://github.com/drupal/drupal/blob/11.x/core/lib/Drupal/Core/StreamWr...
and other examples of Classes that implement StreamWrapperInterface, they all seem to use the same approach.
Here, HttpStreamWrapper, implements RemoteStreamWrapperInterface that also extends Drupal's StreamWrapperInterface.
https://github.com/drupal/drupal/blob/11.x/core/lib/Drupal/Core/StreamWr...
As properties should not be defined in contracts, this explains why it is not in the interface. That said properties can be added like so:
* * @see http://www.faqs.org/rfcs/rfc3986.html * @see http://bugs.php.net/bug.php?id=47070 * * @property resource $context * @property string $handle * @property string $uri * etc. */ interface StreamWrapperInterface extends PhpStreamWrapperInterface { ... }
https://stackoverflow.com/a/50102770/3592441
If required this could probably be added upstream.
This change looks good to me.
- Status changed to RTBC
10 months ago 2:25pm 8 February 2024 - 🇺🇸United States adam-delaney
Applying patch from #2 resolves this issue for me RTBC.
- 🇮🇳India manikandank03 Tamil Nadu
The patch #2 fix the issue and works fine for me, in PHP 8.2 and Drupal 10.2.
-
Dave Reid →
committed b7d6f776 on 2.x
Issue #3399953 by agoradesign: Fixed PHP 8.2 compatibility with creation...
-
Dave Reid →
committed b7d6f776 on 2.x
- Status changed to Fixed
5 months ago 5:28pm 1 July 2024 - 🇺🇸United States dave reid Nebraska USA
Committed and pushed #2 to 2.x. Will create a release shortly.
Automatically closed - issue fixed for 2 weeks with no activity.