- Issue created by @Krizalys
- πΊπΈUnited States DamienMcKenna NH, USA
I think the best approach would be to add those properties to the backup_migrate_destination and backup_migrate_destination_filesource classes.
- Status changed to Needs review
over 1 year ago 1:57am 18 May 2023 - last update
over 1 year ago 26 pass - πΊπΈUnited States jacob.embree
Here's a starting point.
backup_migrate_item::to_array()
looks like it demands the#[AllowDynamicProperties]
attribute. - π³π±Netherlands BrankoC
According to https://www.php.net/manual/en/language.oop5.properties.php :
Dynamic properties are deprecated as of PHP 8.2.0. It is recommended to declare the property instead. To handle arbitrary property names, the class should implement the magic methods __get() and __set(). At last resort the class can be marked with the #[\AllowDynamicProperties] attribute.
(This is response to the person who was unsure about which PHP 8 version was causing the problem and also to highlight the available and the recommended solutions.)
- last update
about 1 year ago 23 pass, 10 fail - π¨π¦Canada awasson
The patch works perfectly for me.
I don't think the automated test against PHP 8.2 & MySQL 8, D7 is a representation of this patch and more than likely exposes other areas of the module that need to be updated for PHP 8.2 & MySQL 8.
I see no reason why this can't be set to Reviewed and Tested by the community so it can be rolled out but perhaps someone else can weigh in on it to see any issues.
Cheers,
Andrew - Status changed to RTBC
about 1 year ago 8:50pm 7 October 2023 - π¨π¦Canada danrod Ottawa
Tested patch as well in my D7 instance, worked as expected, no more warnings after this (attached screenshots), tested functionality too, moving this to RTBC.
- π³π΄Norway gisle Norway
Can confirm that patch in comment #4 fixes this with PHP 8.2.
- πΊπΈUnited States argiepiano
The fix provided in this issue actually misses a couple of properties in class
backup_migrate_filter_utils
:backup_migrate_filter_utils::saved_site_offline
backup_migrate_filter_utils::saved_site_offline_message
- First commit to issue fork.
- Merge request !37Issue #3350436: Deprecation messages with PHP 8: Creation of dynamic property.... β (Open) created by Anybody
- last update
about 1 year ago 21 pass, 3 fail - last update
about 1 year ago 21 pass, 3 fail - last update
about 1 year ago 21 pass, 3 fail - π©πͺGermany smitty
I applied the patch from #4 an the MR from #12 and all works fine now (php 8.2).
Thank you!
-
DamienMcKenna β
committed ffee1f9e on 7.x-3.x
Issue #3350436 by Anybody, jacob.embree, danrod, Krizalys, DamienMcKenna...
-
DamienMcKenna β
committed ffee1f9e on 7.x-3.x
- Status changed to Fixed
8 months ago 10:42am 14 April 2024 Automatically closed - issue fixed for 2 weeks with no activity.