Project

General

Profile

Actions

Bug #81340

closed

TemplatePaths::fillDefaultsByPackageName does not sort paths correctly

Added by Claus Due over 7 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2017-05-24
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

The unfortunate series of events which lead to a problem:

  • TemplatePaths->fillDefaultsByPackageName($extKey) gets called
  • TemplatePaths->fillDefaultSByPackageName() calls getContextSpecificViewConfiguration()
  • TemplatePaths->getContextSpecificViewConfiguration() reads TS and returns combined fallback paths and TS-configured paths
  • TemplatePaths->fillFromConfigurationArray($resolvedPaths) gets called
  • TemplatePaths->fillFromConfigurationArray() calls TemplatePaths->extractPathArrays()
  • TemplatePaths->extractPathArrays() calls array_values

Result: when calling fillDefaultsByPackageName() TS paths do not get sorted correctly even though the right setTemplateRootPaths and so on get called. Normally these methods would indeed sort the paths correctly, but the array_values() part (Fluid standalone cares about order, not keys) causes the methods that do perform sorting, to receive an "already sorted" (=values only, numeric zero-index in order TS was declared) which of course does not get sorted further. Final result is that template overrides do not work if View was initialised with this method - which by the way should be the preferred way to initialise View template paths everywhere in TYPO3.


Related issues 1 (0 open1 closed)

Precedes TYPO3 Core - Bug #81677: TYPO3 Exception "Section "main" does not exist." under TYPO3 8.7.2 Closed2017-06-22

Actions
Actions #1

Updated by Gerrit Code Review over 7 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52938

Actions #2

Updated by Gerrit Code Review over 7 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52938

Actions #3

Updated by Gerrit Code Review over 7 years ago

Patch set 1 for branch TYPO3_8-7 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/53112

Actions #4

Updated by Anonymous over 7 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #5

Updated by Xavier Perseguers over 7 years ago

  • Precedes Bug #81677: TYPO3 Exception "Section "main" does not exist." under TYPO3 8.7.2 added
Actions #6

Updated by Gerrit Code Review over 7 years ago

  • Status changed from Resolved to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/53310

Actions #7

Updated by Claus Due about 7 years ago

  • Status changed from Under Review to Resolved

Merge event was not caught by Redmine. This one is solved :)

Actions #8

Updated by Benni Mack about 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF