Issue Bug Closed

#90599AssetCollector: "Serialization of 'Closure' is not allowed" for uncached plugins

Christian Eßl 02/29/20, 11:57 updated 02/29/20, 21:34

Description

  • Install introduction package
  • Implement a ext:form form on a page and submit it.

leads to:

(1/1) Exception
Serialization of 'Closure' is not allowed

in /var/www/html/typo3/sysext/frontend/Classes/Http/RequestHandler.php line 199
        // Add previously generated page content within the <body> tag afterwards
        $pageRenderer->addBodyContent(LF . $pageContent);
        if ($controller->isINTincScript()) {
            // Store the serialized pageRenderer in configuration
            $controller->config['INTincScript_ext']['pageRenderer'] = serialize($pageRenderer);
            // Render complete page, keep placeholders for JavaScript and CSS
            return $pageRenderer->renderPageWithUncachedObjects($controller->config['INTincScript_ext']['divKey']);
        }
        // Render complete page

because the RequestHandler is trying to serialize $pageRenderer, but AssetCollector contains a closure.

In case of the introduction package, the asset collector contains two media files:
  • fileadmin/introduction/images/introduction-package.svg
  • fileadmin/introduction/images/introduction-package-inverted.svg

which contain both a TYPO3\CMS\Core\Resource\File and a TYPO3\CMS\Core\Resource\ProcessedFile object.
Removing these two files prevents the error.

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.