Project

General

Profile

Actions

Bug #105575

open

TaskSerializer::deserialize(): Argument #1 ($serializedTask) must be of type string, null given

Added by Lina Wolf 27 days ago. Updated 27 days ago.

Status:
New
Priority:
Should have
Assignee:
-
Category:
scheduler
Target version:
-
Start date:
2024-11-12
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
13
PHP Version:
8.2
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

(1/1) TypeError
TYPO3\CMS\Scheduler\Task\TaskSerializer::deserialize(): Argument #1 ($serializedTask) must be of type string, null given, called in /var/www/html/vendor/typo3/cms-scheduler/Classes/Controller/SchedulerModuleController.php on line 424

in /var/www/html/vendor/typo3/cms-scheduler/Classes/Task/TaskSerializer.php line 36

Happens in the scheduler in an older, updated instance where there might be data that is not expected.

$taskRecord = $this->taskRepository->findRecordByUid($taskUid); in line 408 is null as the record is not found but the try catch block expects an \OutOfBoundsException.

a) throw an out of bounds exception when a scheduler task is not found
b) If the task is found but does not have the key serialized_task_object fall back to an empty string as the methods expect a string. Maybe some kind of exception would be even better here.


Files

Bug105575.patch (1.76 KB) Bug105575.patch Lina Wolf, 2024-11-12 06:42
Actions #1

Updated by Lina Wolf 27 days ago

This patch solves it for me:

Actions

Also available in: Atom PDF