I'm trying to migrate a typo3 7.6.32 installation to 8.7.24. After updating all extensions to the most recent versions and having the basic page setup and working, the ke_search extensions breaks on one specific page only.
Actual Error Message:
Argument 1 passed to TYPO3\CMS\Fluid\View\StandaloneView::setTemplateRootPaths() must be of the type array, null given, called in /var/www/web18/htdocs/relaunch2016_t3v8/typo3conf/ext/ke_search/pi1/class.tx_kesearch_pi1.php on line 95
TypeError thrown in file
/var/www/web18/htdocs/typo3_src-8.7.24/typo3/sysext/fluid/Classes/View/StandaloneView.php in line 178.
16 TYPO3\CMS\Fluid\View\StandaloneView::setTemplateRootPaths(NULL)
/var/www/web18/htdocs/relaunch2016_t3v8/typo3conf/ext/ke_search/pi1/class.tx_kesearch_pi1.php:
00093: {
00094: $this->searchFormView = GeneralUtility::makeInstance('TYPO3\\CMS\\Fluid\\View\\StandaloneView');
00095: $this->searchFormView->setTemplateRootPaths($this->conf['templateRootPaths']);
00096: $this->searchFormView->setPartialRootPaths($this->conf['partialRootPaths']);
00097: $this->searchFormView->setLayoutRootPaths($this->conf['layoutRootPaths']);
15 tx_kesearch_pi1::initFluidTemplate()
/var/www/web18/htdocs/relaunch2016_t3v8/typo3conf/ext/ke_search/pi1/class.tx_kesearch_pi1.php:
00067:
00068: // init template for pi1
00069: $this->initFluidTemplate();
00070:
00071: // hook for initials
This goes on for a few more lines but I believe the problem lies in this part.
I've tried this solution but to no avail. As far as I can tell (using the Typo3 Object Browser) the entire config is not being loaded for ke_search at all.
This is (part of) the original typoscript for 7.6:
plugin.tx_kesearch_pi1 {
templateRootPath = fileadmin/fluidtpl/_kesearch/Templates/
partialRootPath = fileadmin/fluidtpl/_kesearch/Partials/
layoutRootPath = fileadmin/fluidtpl/_kesearch/Layouts/
}
plugin.tx_kesearch_pi2 {
templateRootPath = fileadmin/fluidtpl/_kesearch/Templates/
partialRootPath = fileadmin/fluidtpl/_kesearch/Partials/
layoutRootPath = fileadmin/fluidtpl/_kesearch/Layouts/
}
Using the solution from the previously mentioned answer:
plugin.tx_kesearch_pi1 {
templateRootPaths {
5 = EXT:ke_search/Resources/Private/Templates/
}
partialRootPaths {
5 = EXT:ke_search/Resources/Private/Partials/
}
layoutRootPaths {
5 = EXT:ke_search/Resources/Private/Layouts/
}
}
plugin.tx_kesearch_pi2 {
templateRootPaths {
5 = EXT:ke_search/Resources/Private/Templates/
}
partialRootPaths{
5 = EXT:ke_search/Resources/Private/Partials/
}
layoutRootPaths {
5 = EXT:ke_search/Resources/Private/Layouts/
}
}
I also tried adding the previously used templates as a fallback but it didn't seem to be recognized at all. I also cleared the cache after every step but nothing changed, still the same error.
I was prepared having to change the old template files to a certain degree but at this point I can't even get the default templates to work.
I found the mistake: I had another typoscript somewhere down the tree that had overridden the templateRootPath, partialRootPath and layoutRootPath settings. After removing this culprit, everything worked as intended.