Bug #99475
closedImcomplete deprecation (without trigger etc.) of RenderingContext::getControllerContext and ControllerContext functions (v11)
0%
Description
No PHPDoc explanation, no triggering of deprecation notice for deprecation of RenderingContext::getControllerContext (v11)
1. no deprecation notice is triggered in- ControllerContext::getUriBuilder
- ControllerContext::getFlashMessageQueue
- RenderingContext::getControllerContext
Usually it is customary to trigger a E_USER_DEPRECATED if a deprecated function is used:
trigger_error('...', E_USER_DEPRECATED);
2. no explanation in PHPDoc
3. changelog a bit difficult to find, if you search for getControllerContext, you get no result, it might help to add the deprecated functions to the alread existing changelog
grep -r getControllerContext htdocs/typo3/sysext/core/Documentation/
htdocs/typo3/sysext/core/Documentation/Changelog/9.0/Breaking-82414-RemoveCMSBaseViewHelperClasses.rst::php:`$this->renderingContext->getControllerContext()`.
htdocs/typo3/sysext/core/Documentation/Changelog/8.5/Feature-78842-LetFluidtemplateMimicAnActualExtbaseWebRequest.rst: ->getControllerContext()
/**
* Get the controller context which will be passed to the ViewHelper
*
* @return ControllerContext The controller context to set
* @deprecated since v11, will be removed in v12
*/
public function getControllerContext()
Related patches, issues, changelogs¶
- patch: https://review.typo3.org/c/Packages/TYPO3.CMS/+/67075
- issue: #93036
- issue #95139
- changelog: https://docs.typo3.org/c/typo3/cms-core/main/en-us/Changelog/11.5/Deprecation-95139-ExtbaseControllerContext.html
in 9.x it was still recommended to use this function, see https://docs.typo3.org/c/typo3/cms-core/main/en-us/Changelog/9.0/Breaking-82414-RemoveCMSBaseViewHelperClasses.html#migration
Updated by Sybille Peters almost 2 years ago
- Related to Bug #99476: Add getRequest to RenderingContextInterface? (>= v11) added
Updated by Christian Kuhn almost 2 years ago
- Status changed from New to Needs Feedback
I'm unsure if we should still add trigger_error()'s to this in v11: One reason to get rid of ControllerContext was that it has been wired into RenderingContext and initialized always. This would have made RenderingContext always log deprecation messages, so we couldn't log deprecations in RenderingContext::getControllerContext. I'm not totally sure about ControllerContext::getUriBuilder and ControllerContext::getFlashMessageQueue anymore, but I assume similar difficulties. The class is annotated @deprecated in v11 and the extension scanner finds things, I hope that's enough without further fiddling on this in v11 adding the risk that new deprecations are thrown for existing v11 instances.
Is this fine with you?
Updated by Sybille Peters almost 2 years ago
- Status changed from Needs Feedback to Closed
Is this fine with you?
ok, closing