I ran into a a small problem after activating the TYPO3 debug mode in my ddev TYPO3 development installation. When opening the Configuration Presets again, I was greeted with the following error:

Screenshot of the TYPO3 install tool error box starting with “Something went wrong”. The full text follows below.

Something went wrong
Please use Check for broken extensions to see if a loaded extension breaks this part of the install tool and unload it.

The box below may additionally reveal further details on what went wrong depending on your debug settings. It may help to temporarily switch to debug mode using Settings > Configuration Presets > Debug settings.

If this error happens at an early state and no full exception back trace is shown, it may also help to manually increase debugging output in %config-dir%/system/settings.php:['BE']['debug'] => true, ['SYS']['devIPmask'] => '*', ['SYS']['displayErrors'] => 1,['SYS']['exceptionalErrors'] => 12290

Upon investigating the Ajax error shown below the message I saw it was throwing an exception:

Screenshot of the exception “#1476107295 TYPO3\\CMS\\Core\\Error\\Exception” with a PHP deprecation notice. The full text follows below.

/typo3/module/tools/settings
(1/1) #1476107295 TYPO3\CMS\Core\Error\Exception
PHP Runtime Deprecation Notice: str_contains(): Passing null to parameter #1 ($haystack) of type string is deprecated in /var/www/html/vendor/typo3/cms-install/Classes/Configuration/Image/ImageMagick6Preset.php line 85

Instead of increasing the debugging output as suggested, I guessed that – short of fixing the underlying function – deactivating deprecation notices would do the trick for now, hoping that the TYPO3 devs will fix this in an upcoming release. So I jumped into the console, navigated to /config/system and edited the file additional.php, and found the following lines:

/config/system/additional.php
'SYS' => [
	'trustedHostsPattern' => '.*.*',
	'devIPmask' => '*',
	'displayErrors' => 1,
],

A little addition, and everything worked out fine:

/config/system/additional.php
'SYS' => [
	'trustedHostsPattern' => '.*.*',
	'devIPmask' => '*',
	'displayErrors' => 1,
	'exceptionalErrors' => 8191
],

I might need to adjust this, if other errors show up, but for now it’s fine. On the downside I will not catch any deprecated stuff for now, but I can live with that.

Documentation used:

https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/Configuration/Typo3ConfVars/SYS.html#exceptionalerrors

https://www.php.net/manual/en/errorfunc.constants.php

Kommentare

Pseudonym genügt. Die Kommentare laufen auf meinem eigenen Server, mehr dazu im Datenschutz.