Project

General

Profile

Actions

Bug #36234

closed

Uncaught TYPO3 Exception: Class t3lib_FlashMessage does not exist

Added by Ulfried Herrmann over 12 years ago. Updated over 9 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Frontend
Target version:
Start date:
2012-04-17
Due date:
% Done:

0%

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

Description

If 'displayErrors' is set to 1 in Install Tool a PHP notice may lead to an Uncaught TYPO3 Exception:

Uncaught TYPO3 Exception
Class t3lib_FlashMessage does not exist
ReflectionException thrown in file
/www/htdocs/xxx/typo3_src-4.7.0rc1/t3lib/class.t3lib_div.php in line 4844.

30 ReflectionClass::__construct("t3lib_FlashMessage")
  /www/htdocs/xxx/typo3_src-4.7.0rc1/t3lib/class.t3lib_div.php:
    04842:    array_shift($constructorArguments);
    04843:
    04844:    $reflectedClass = new ReflectionClass($finalClassName);
    04845:    $instance = $reflectedClass->newInstanceArgs($constructorArguments);
    04846:   } else {

29 t3lib_div::makeInstance("t3lib_FlashMessage", "PHP : Assigning the return value of new by referen…
    ...

This behaviour also occurs in TYPO3 version 4.7.


Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #23444: t3lib_error_Exception not available in some casesClosedSteffen Kamper2010-08-24

Actions
Actions #1

Updated by Martin Bless over 12 years ago

Confirmed for 4.5.15!

Actions #2

Updated by Markus Klein over 12 years ago

Please consider cleaning typo3temp/Cache/Code in order to renew the autoloader cache and tell us, whether this solved the issue.
Thanks.

Actions #3

Updated by Ulfried Herrmann over 12 years ago

Dear Markus,

I tried to reproduce this exception to test your suggestion - unfortunately without success at present. But I dimly remember the try to do this (and the exception remained), but I'm not sure.

Ulfried

Actions #4

Updated by Markus Klein over 12 years ago

So is this still an issue or not?
I'm a bit confused atm.

Actions #5

Updated by Ulfried Herrmann over 12 years ago

Dear Markus,

since I actually head this exception and Martin could confirm it I think it's still an issue. I'll keep trying to reproduce the behaviour in next days to tell you the preconditions for tracebility.

Best
Ulfried

Actions #6

Updated by Simon Apold over 12 years ago

Confirmed for 4.7.1 on my local dev environment (Win7 - XAMPP)
The error message appears in the workspace module.
Cleaning typo3temp/Cache/Code does not solve this Problem.

On our test machine (Linux) the workspace module shows a different error message (Class t3lib_lock does not exist).

Actions #7

Updated by Noel Bossart over 12 years ago

I can confirm this issue on multiple instances of the same website (multiple servers) $TYPO3_CONF_VARS['SYS']['displayErrors'] = '0'; solves the problem.

WorkSpaces
router Class t3lib_FlashMessage does not exist

Actions #8

Updated by Michael Bakonyi over 12 years ago

I can confirm this issue for 4.7.2

Actions #9

Updated by Philipp Wintermantel over 12 years ago

Michael Bakonyi wrote:

I can confirm this issue for 4.7.2

Also confirmed for 4.7.2.

In my case the error is caused by the fpdf extension which uses deprecated reference assigning. The error seems to be triggered when the errorHandler tries to collect PHP deprecated warnings.

Probably related to #23444

Actions #10

Updated by Steffen Gebert over 12 years ago

  • Status changed from New to Needs Feedback

It really looks like the t3lib_FlashMessage class isn't available, because the autoloader isn't initialised, while a message should be shown.

Could you give it a try and add

require_once (PATH_t3lib , 'class.t3lib_flashmessage.php');

to init.php for example here:

// *************************************************
// t3lib_div + extention management class included
// *************************************************
require_once(PATH_t3lib.'class.t3lib_div.php');        // The standard-library is included
require_once(PATH_t3lib.'class.t3lib_extmgm.php');    // Extension API Management library included

Actions #11

Updated by Philipp Wintermantel over 12 years ago

That would fix the issue indeed. Although the required classes must be included as well:

require_once (PATH_t3lib . 'message/class.t3lib_message_abstractmessage.php');
require_once (PATH_t3lib . 'class.t3lib_flashmessage.php');

Maybe even class.t3lib_message_errorpagemessage.php and class.t3lib_message_abstractstandalonemessage.php. But AbstractMessage was sufficient for my scenario.

Thanks for looking into it :-)

Actions #12

Updated by Sebastian Sommer over 12 years ago

Philipp Wintermantel wrote:

That would fix the issue indeed. Although the required classes must be included as well:

require_once (PATH_t3lib . 'message/class.t3lib_message_abstractmessage.php');
require_once (PATH_t3lib . 'class.t3lib_flashmessage.php');

Maybe even class.t3lib_message_errorpagemessage.php and class.t3lib_message_abstractstandalonemessage.php. But AbstractMessage was sufficient for my scenario.

Thanks for looking into it :-)

Thanks Philipp! Works for me :-)!

Actions #13

Updated by Ulfried Herrmann about 12 years ago

I can confirm that the solution posted here solves the problem indeed.
As Philipp wrote the fpdf extension caused the error in my case too.
Thanks to all who contributed!

Actions #14

Updated by Pascal Dürsteler about 12 years ago

I also get this error when loading the external class [[http://sourceforge.net/projects/phpexcelreader/]] in a controller action.

Loading

require_once (PATH_t3lib . 'message/class.t3lib_message_abstractmessage.php');
require_once (PATH_t3lib . 'class.t3lib_flashmessagequeue.php');
require_once (PATH_t3lib . 'class.t3lib_flashmessage.php');

solves the problem.

Actions #15

Updated by Andreas Mayer about 12 years ago

Can confirm this bug for Typo3/4.7.4.

Actions #16

Updated by Alexander Opitz over 11 years ago

  • Status changed from Needs Feedback to New
Actions #17

Updated by Mathias Schreiber almost 10 years ago

  • Target version set to 7.4 (Backend)
  • Is Regression set to No
Actions #18

Updated by Frederic Gaus almost 10 years ago

Unable to reproduce this on current master.

Actions #19

Updated by Riccardo De Contardi over 9 years ago

  • Status changed from New to Closed

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.

Actions

Also available in: Atom PDF