Project

General

Profile

Actions

Bug #53777

closed

Exception: $toolbarItem "shortcuts" must implement interface backend_toolbarItem

Added by Stefan Neufeind over 10 years ago. Updated over 10 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2013-11-20
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.5
PHP Version:
5.5
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

Doing a clean install of 4.5.30 using the introduction-package at first it seems to work fine. Also the backend-login shows up fine. But upon trying to login I get:

Uncaught TYPO3 Exception
#1195126772: $toolbarItem "shortcuts" must implement interface backend_toolbarItem

UnexpectedValueException thrown in file
/var/www/html/typo3_src-4.5.30/typo3/backend.php in line 176.


Related issues 1 (0 open1 closed)

Is duplicate of TYPO3 Core - Bug #53682: Exception '$toolbarItem "shortcuts" must implement interface ...\ToolbarItemHookInterface'Closed2013-11-15

Actions
Actions #1

Updated by Stefan Neufeind over 10 years ago

  • PHP Version set to 5.5

Looks like an error with loading the classes? Hmm ...

This is on PHP 5.5.6. Same happens with introductionpackage for 4.5.20 or 4.5.31-dev (latest 4.5.x from git as of today) with also has autoload-fixes from Ernesto etc. Strange :-(

Actions #2

Updated by Markus Klein over 10 years ago

  • Status changed from New to Closed
Actions #3

Updated by Peter Niederlag over 10 years ago

  • Status changed from Closed to New

This is the API of ToolbarItemHookInterface (note it requires a reference to be passed in!):

TYPO3\CMS\Backend\Toolbar\ToolbarItemHookInterface::__construct(\TYPO3\CMS\Backend\Controller\BackendController &$backendReference = NULL);

Root Cause of the problem is the way TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance() passes the arguments to the constructor:

 $instance = $reflectedClass->newInstanceArgs($constructorArguments);

Basically for some reason php (under certain circumstances) fails to create the instance because the constructor argument is not a reference. The displayed Exeception just hides the real problem.

This problem is biting me for some days now on just about every installation on my local dev system using debian testing/unstable. I assume php somehow changed the way to handle references or the way to handle related errors. I could not nail it down to any specific change.

Actions #4

Updated by Peter Niederlag over 10 years ago

  • Status changed from New to Closed

closed again as duplicate of #53682

Actions

Also available in: Atom PDF