Bug #59662

Problem with subsequent calls to $configurationManager->setLocalConfigurationValueByPath and 'LocalConfiguration invalid'

Added by Wolfgang Klinger almost 7 years ago. Updated over 6 years ago.

Must have
Target version:
Start date:
Due date:
% Done:


Estimated time:
TYPO3 Version:
PHP Version:
Is Regression:
Sprint Focus:


We ran into problems when using subsequent calls to

$configurationManager->setLocalConfigurationValueByPath('… any key …', '… some value …');

in AdditionalConfiguration.php.
The problem (it seems, I debugged it and came to this conclusion) is that LocalConfiguration.php is sometimes not fully written to disk when read in again.
As require(LocalConfiguration.php) … returns 1 instead of the configuration array if no return statement exists TYPO3 throws the following exception:

( ! ) Catchable fatal error: Argument 1 passed to TYPO3\CMS\Core\Utility\ArrayUtility::setValueByPath() must be an array, integer given, called in /private/var/www/typo3_src-6.2.3/typo3/sysext/core/Classes/Configuration/ConfigurationManager.php on line 229 and defined in /private/var/www/typo3_src-6.2.3/typo3/sysext/core/Classes/Utility/ArrayUtility.php on line 189
Call Stack
#    Time    Memory    Function    Location
1    0.0003    657712    {main}( )    ../backend.php:0
2    0.0004    672296    require_once( '/private/var/www/typo3_src-6.2.3/typo3/init.php' )    ../backend.php:27
3    0.0197    4797200    TYPO3\CMS\Core\Core\Bootstrap->loadConfigurationAndInitialize( ???, ??? )    ../init.php:61
4    0.0204    4838976    TYPO3\CMS\Core\Core\Bootstrap->populateLocalConfiguration( )    ../Bootstrap.php:227
5    0.0204    4838976    TYPO3\CMS\Core\Configuration\ConfigurationManager->exportConfiguration( )    ../Bootstrap.php:392
6    0.0225    5027640    require( '/private/var/www/…/typo3conf/AdditionalConfiguration.php' )    ../ConfigurationManager.php:286
7    0.0231    5091192    TYPO3\CMS\Core\Configuration\ConfigurationManager->setLocalConfigurationValueByPath( string(13), string(1) )    ../AdditionalConfiguration.php:46
8    0.0242    5094104    TYPO3\CMS\Core\Utility\ArrayUtility::setValueByPath( long, string(13), string(1), ??? )    ../ConfigurationManager.php:229

I solved it in our project by creating an array at first and then using setLocalConfigurationValuesByPathValuePairs once.
I think it needs some locking mechanism here.

Related issues

Related to TYPO3 Core - Bug #59845: Full system crash after installing extension on a live systemClosed2014-06-24

Related to TYPO3 Core - Bug #60294: If a local file storage is outside the document root, images are sometimes not shown if multiple images are on a page.Closed2014-07-13

Related to TYPO3 Core - Bug #59432: setLocalConfigurationValueByPath() writes LocalConfiguration.php on each requestRejected2014-06-10


Updated by Markus Klein almost 7 years ago

  • Assignee set to Christian Kuhn

@Christian: Can you please comment on that. thanks


Updated by Markus Klein almost 7 years ago

Wolfgang, looking at the trace: Are you writing to the LocalConfiguration in the AdditionalConfiguration file?


Updated by Markus Klein almost 7 years ago

  • Status changed from New to Needs Feedback

If so, take a look at my comment here: https://forge.typo3.org/issues/60294#note-11


Updated by Alexander Opitz over 6 years ago

  • Status changed from Needs Feedback to Closed
  • Assignee deleted (Christian Kuhn)

No feedback within the last 90 days => closing this issue.

If you think that this is the wrong decision or experience this issue again, then please write to the mailing list typo3.teams.bugs with issue number and an explanation or open a new ticket and add a relation to this ticket number.

Also available in: Atom PDF