Review main Merged

17381[BUGFIX] Impossible to save the TCA configuration

Philipp Gampe CR +2 V +2 Easy +4 −1 updated 06/03/13, 20:49

Commit message

The configuration module allows to save changes to the TCA array.

If no extTablesDefinitionScript is defined, constant
TYPO3_extTableDef_script is defined as empty. This results in an
attempt to write to a directory (because the filename is empty).
This is not obvious as the constant is not needed much and the
error message is misleading.

Solution is to fall back to the default value during bootstrap if
extTablesDefinitionScript is not set in LocalConfiguration.php.

Review

  • Code review CR +2
    • Christian Kuhn +2
    • Anja Leichsenring +1
  • Verified V +2
    • Christian Kuhn +2
    • Anja Leichsenring +1

Files 1

Review log 17

  1. Christian Kuhn commented on patch set 1 02/02/13, 09:26

    I would prefer that you didn't submit this Imho, this is not broken: saving tca overrides in the configuration module saves changes to the defined $GLOBALS['TYPO3_CONF_VARS']['DB']['extTablesDefinitionScript'], which defaults to typo3conf/extTables.php and is defined in TYPO3_extTableDef_script While this code foo is not optimal, there is an important different between AdditionalConfiguration.php and extTables.php: The AdditionalConfiguration.php file is loaded before ext_tables.php files of extensions are loaded, and extTables.php is loaded after ext_tables.php of extensions are loaded. So, any patch in this area must not just switch from saving in extTables.php to AdditionalConfiguration.php Furthermore, saving different tca through the configuration module worked well for me, and i did not find any error. @philipp / @Mattias, did i miss something?
  2. Christian Kuhn commented on patch set 1 02/02/13, 09:26

    @Phillip: the variable is a standard setting that comes with all installations in former localconf.php. if you removed it, because it was of no use for you, there should be fallback code in bootstrap.
  3. Christian Kuhn commented on patch set 1 02/02/13, 09:26

    so, your real issue is, that the var is not set to some default, it is not within the configuration (defining some constant for that is evil anyway, but i think we're unable to get rid of that).
  4. Philipp Gampe commented on patch set 1 02/02/13, 09:26

    I get PHP Warning PHP Warning: fopen(/var/www/html/t3-playground/t3-git/typo3conf/): failed to open stream: Is a directory in /home/phil/t3-playground/t3-git/typo3/sysext/core/Classes/Utility/GeneralUtility.php line 2473
  5. Philipp Gampe commented on patch set 1 02/02/13, 09:26

    I would prefer that you didn't submit this TYPO3_extTableDef_script is not set for me ?!?
  6. Philipp Gampe commented on patch set 1 02/02/13, 09:26

    yes, I will refactor the patch accordingly and make sure that the constant is always set.
  7. Christian Kuhn uploaded patch set 3 02/02/13, 09:26

  8. Christian Kuhn commented on patch set 3 02/02/13, 09:26

    Verified; Looks good to me, but someone else must approve
  9. Philipp Gampe uploaded patch set 2 02/02/13, 09:26

  10. Mattias Nilsson commented on patch set 1 02/02/13, 09:26

    Verified; Looks good to me, but someone else must approve
  11. Anja Leichsenring commented on patch set 3 02/02/13, 09:26

    Verified; Looks good to me, but someone else must approve
  12. Mr. Jenkins commented on patch set 1 02/02/13, 09:26

  13. Mr. Jenkins commented on patch set 2 02/02/13, 09:26

  14. Mr. Jenkins commented on patch set 3 02/02/13, 09:26

  15. Christian Kuhn commented on patch set 3 V 0 02/02/13, 09:26

    by team member; Looks good to me, approved
  16. Christian Kuhn merged patch set 4 02/02/13, 09:26

  17. Helmut Hummel commented on patch set 4 04/03/13, 12:13

    Reverted This patchset was reverted in change: I2830cf9bfb711f2065cfa3e0e7ccd68cbb567539