Project

General

Profile

Actions

Bug #92015

closed

referenceindex:update ... Exception handler ... Too few arguments

Added by Horst Häberlen over 4 years ago. Updated over 4 years ago.

Status:
Rejected
Priority:
Should have
Assignee:
-
Category:
Backend API
Target version:
-
Start date:
2020-08-15
Due date:
% Done:

0%

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

Description

Upgrading from working 9.5.x Version to 10.4.6 leads to an reproducible error (upgraded twice from same sourec):

Core: Exception handler (WEB): Uncaught TYPO3 Exception: Too few arguments to function TYPO3\CMS\Core\Database\SoftReferenceIndex::__construct(), 0 passed in /home/xxx/typo3_src-10.4.6/typo3/sysext/core/Classes/Utility/GeneralUtility.php on line 3426 and exactly 1 expected | ArgumentCountError thrown in file /home/xxx/typo3_src-10.4.6/typo3/sysext/core/Classes/Database/SoftReferenceIndex.php in line 90. Requested URL: https://xxx/typo3/index.php?route=%2Frecord%2Fedit&token=--AnonymizedToken--&edit%5Btt_content%5D%5B-1743%5D=new&defVals%5Btt_content%5D%5BcolPos%5D=1&defVals%5Btt_content%5D%5Bsys_language_uid%5D=0&defVals%5Btt_content%5D%5BCType%5D=textpic&returnUrl=%2Ftypo3%2Findex.php%3Froute%3D%252Fmodule%252Fweb%252Flayout%26token%3Dfec4a465d4fea1152e47eee699cfc06e5531d578%26id%3D324 - {"TYPO3_MODE":"BE","exception":{}}

The error occurs when:
DB Testinng > updating SoftReferenceIndex
Insering/deleting/moving a content element

FE is working
Inserted content elements are visible in FE


Files

TYPO3 Exception.html (65.3 KB) TYPO3 Exception.html Horst Häberlen, 2020-08-17 00:04

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Feature #89733: Migrate various Signal Slots to PSR-14 eventsClosedBenni Mack2019-11-21

Actions
Actions #1

Updated by Christian Kuhn over 4 years ago

  • Related to Feature #89733: Migrate various Signal Slots to PSR-14 events added
Actions #2

Updated by Christian Kuhn over 4 years ago

Thanks for the report.

This is probably related to #89733, but I'm unable to reproduce.

Would you like to add some more reproduce information? Your current description is a bit sparse. Maybe we're able to reproduce the issue with a more detailed click-here-do-this-then-that description.

Actions #3

Updated by Christian Kuhn over 4 years ago

  • Status changed from New to Needs Feedback
Actions #4

Updated by Horst Häberlen over 4 years ago

Thanks for the quick response!

I try to give a little more info.

After the upgrade to 10.4.6 i stepped trough the upgrade wizzard. One problem with the extension weather2 i skipped by disabeling weather2.

Then i did a [php ...] referenceindex:update with the result Core: "Exception handler [...]" at the position "Update index of table tt_content".

Trying to run selective like in "typo3/sysext/lowlevel/README.rst" described, leads to the same error when at the command with --update-refindex parameter.

The Exception handler error occurs also when inserting a content element, but the creation of the content element was successfully.

I did the upgrade 3 times with the same results. I started to disable extensions, but i think there is no influence to referencindex. I switched to debug modus, but for me it did not help to find a solution.

What else of information do you need?

Actions #5

Updated by Christian Kuhn over 4 years ago

Weird. I actually suspect some third party (non-core) extension is doing funny things.

Could you go to:
Admin tools -> Settings -> Configuration Presets -> Debug settings -> Select and save "debug"?

This should give you a full backtrace when exceptions occur. This could help to see where your issue comes from.

Additionally, I still don't understand when exactly something goes wrong. You simply add some content element in page module, then save it, and then the exception pops up?

Actions #6

Updated by Horst Häberlen over 4 years ago

I have attached the full backtrace.

Yes, i add some content element e.g. text+media or text. When i save it, the exception pops up. If i delete a content element, the exception pops up.

But if i add only a headline, there is no error!

Actions #7

Updated by Benjamin Franzke over 4 years ago

  • Status changed from Needs Feedback to Rejected

Thank you for the backtrace which points out that third party extension EXT:rte_ckeditor_image has not been adapted for TYPO3 v10 (especially Symfony DI) yet.

It registers a custom softRefParser RteImagesSoftReferenceIndex in ext_localconf.php:
https://github.com/netresearch/t3x-rte_ckeditor_image/blob/master/ext_localconf.php#L4
which extends the TYPO3\CMS\Core\Database\SoftReferenceIndex class from TYPO3 core:
https://github.com/netresearch/t3x-rte_ckeditor_image/blob/master/Classes/Database/RteImagesSoftReferenceIndex.php#L22

Now, while TYPO3\CMS\Core\Database\SoftReferenceIndex relies on DI configuration, and TYPO3 core provides DI config for that service,
the extension EXT:rte_ckeditor_image did not configure Symfony DI for TYPO3 v10 yet (which is fine, as it does only promote TYPO3 v9 support in composer.json).

So, to fix this, a DI configuration would need to be added to EXT:rte_ckeditor_image:

EXT:rte_ckeditor_image/Configuration/Services.yaml

services:
  _defaults:
    autowire: true
    autoconfigure: true
    public: false

  Netresearch\RteCKEditorImage\:
    resource: '../Classes/*'

Actions #8

Updated by Horst Häberlen over 4 years ago

This is the solution.

Thank you!

Actions

Also available in: Atom PDF