Skip to content

v4.1.1: [FIX] Wrap cached values as safe strings for PSR-16 compatibility

Choose a tag to compare

@GianfriAur GianfriAur released this 13 Apr 12:42
· 56 commits to master since this release
f311e0b

[v4.1.1] - 2026-04-13

Fixed

  • Cache serialization compatibility with restricted allowed_classes. cachedFetch() now wraps values as safe strings (base64-encoded serialized data) before storing them in the PSR-16 cache. The cache backend only ever sees plain strings, which are not subject to allowed_classes restrictions. This fixes the __PHP_Incomplete_Class error that occurred on cache hit when the backend called unserialize() with allowed_classes => false — most notably the default behavior in Laravel 13 (serializable_classes => false in config/cache.php). Legacy (unwrapped) cached values are handled transparently for backward compatibility. (#1, php-opcua/laravel-opcua#1)