-
Notifications
You must be signed in to change notification settings - Fork 196
Description
php 8.2.14, fpm-fcgi, Apache/2.4.58 (Fedora Linux) OpenSSL/3.1.1
I am getting the error:
wikimedia/less.php/lib/Less/Parser.php:612 Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes)
The line in question is:
Line 612 in b01ecdd
| $cache = unserialize( file_get_contents( $cache_file ) ); |
For some reason it doesn't like unserializing some rules cached by
Line 641 in b01ecdd
| file_put_contents( $cache_file, serialize( $rules ) ); |
I have manually cleared out the cache files and tried again, resulting in the same issue. I have also updated to current (today) less.php code from GitHub.
I have not been able to track down the specific cached rules that result in the issue. I have a gut feeling it could be a cumulative memory leak rather than any specific rule, though no hard evidence to back that up.
For now, I have disabled reading the less parser cache (by hacking line 607 to 0 && file_exists) and everything works, albeit without the benefits of the cache.
The same .less source compiled under php8.1. But now results in the above under php8.2 (though there are some other environment differences, so php version may be a completely spurious clue).