Project

General

Profile

Actions

Bug #45073

closed

ClassLoader cache parsing error with comments

Added by Arne-Kolja Bachstein almost 12 years ago. Updated over 11 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
Caching
Target version:
-
Start date:
2013-02-01
Due date:
% Done:

0%

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

Description

This one occured for me using YAG (Yet Another Gallery), but rather seems to be a core bug.

In YAG the class PidDetector gets cached and the cached file is put in /typo3temp/Cache/Code/cache_store/ClassLoader_PidDetector_[…].php. But afterwards TYPO3 won't run any more, because there is a parsing error in the resulting file. The parsing error is related to erroneously stripped line endings in a few lines that have a // comment:

Original file:

$pagesRows = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
    'uid', //$select_fields,
    'pages', //$from_table,
    'module="yag"' //$where_clause,
);

Cached file:

$pagesRows = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
      'uid', //$select_fields, 'pages', //$from_table, 'module="yag"' //$where_clause, );

When removing the comments in the original file, the cached one works … but still line endings get stripped like they maybe shouldn't.


Files

phpinfo.pdf (274 KB) phpinfo.pdf Gerald Amrhein, 2013-04-17 09:49

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Feature #44378: TYPO3 6.0 is not compatible with Major Linux DistributionsClosedMichael Stucki2013-01-08

Actions
Actions #1

Updated by Arne-Kolja Bachstein almost 12 years ago

The parse errors are not only comment related and it's not only these line endings. I stumbled upon another one that seems to be related to that.

This time it is:

Before caching:

public function setFeUser(Tx_Extbase_Domain_Model_FrontendUser $feUser) {
    $this->feUser = $feUser;
}

After caching:

public function setFeUser(\TYPO3\CMS\Extbase\Domain\Model\FrontendUser $feUser) {
    $this->feUser = $feUser;
}

Again, of course this breaks the corresponding functionality completely, throwing an exception like this:

PHP Fatal error:  Declaration of Tx_Yag_Domain_Import_AbstractImporter::setFeUser() must be compatible with that of Tx_Yag_Domain_Import_ImporterInterface::setFeUser() in [path_to]/typo3temp/Cache/Code/cache_core/ClassLoader_AbstractImporter_[hash].php on line 35
Actions #2

Updated by Christian Kuhn almost 12 years ago

  • Status changed from New to Needs Feedback

You are using TYPO3 6.0 on php versions smaller than 5.3.7, right?

Actions #3

Updated by Arne-Kolja Bachstein almost 12 years ago

TYPO3 6.0.1 and PHP 5.3.3-7+squeeze14 here, you're right.

Just noticed that the PHP version is below the requirements … sorry, didn't know that. Is there a way to work around this or is it a hard requirement?

Actions #4

Updated by Christian Kuhn almost 12 years ago

could you please add the original class file to this issue here, please?

Actions #5

Updated by Gerald Amrhein over 11 years ago

Hello,
i got a similar warning in "Galerie - YAG Storage Folder"
PHP Warning: Creating default object from empty value in /var/www/amrhein.info/http/www3/typo3conf/ext/yag/Classes/Utility/HeaderInclusion.php line 190

System:
Typo3 6.0.2
Apache 2
PHP Version 5.4.14-1~lucid+1
Ubuntu 10.04 LTS hosted by "Host Europe" vServer L (small Power)
attached you find a phpinfo print

is there a solution available?

What is the couse of this warning?

Kind regards, Gerald

Actions #6

Updated by Alexander Opitz over 11 years ago

  • Status changed from Needs Feedback to Closed

@Gerald Amrhein

That's not the same issue, please open a new issue, if the problem persists with newer versions of TYPO3

@Arne-Kolja Bachstein

As there is no response in over 90 days, I'll closing this issue.

Actions

Also available in: Atom PDF