Project

General

Profile

Actions

Bug #90220

closed

Scheduler results in exception when used with sqlite

Added by Daniel Siepmann almost 5 years ago. Updated over 4 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Database API (Doctrine DBAL)
Target version:
-
Start date:
2020-01-27
Due date:
% Done:

100%

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

Description

Opening the scheduler module in TYPO3 Backend results in the following error:

(1/1) #1476107295 TYPO3\CMS\Core\Error\Exception

PHP Warning: count(): Parameter must be an array or an object that implements Countable in /home/daniels/Projects/own/website-typo3/project/private/typo3/sysext/scheduler/Classes/Scheduler.php line 130

The database entry is:

***************************[ 1. row ]***************************
uid                    | 3
crdate                 | 1580142884
disable                | 0
deleted                | 0
description            | 
nextexecution          | 1580146200
lastexecution_time     | 1580143156
lastexecution_failure  | 
lastexecution_context  | BE
serialized_task_object | O:45:"TYPO3\CMS\Reports\Task\SystemStatusUpdateTask":11:{s:20:"^@*^@notificationEmail";s:25:"***@example.com";s:18:"^@*^@notificationAll";b:0;s:12:"^@*^@schedul er";N;s:10:"^@*^@taskUid";i:3;s:11:"^@*^@disabled";b:0;s:19:"^@*^@runOnNextCronJob";b:0;s:12:"^@*^@execution";O:29:"TYPO3\CMS\Scheduler\Execution":6:{s:8:"^@*^@start";i:1580142861;s:6:"^@*^@end"; s:0:"";s:11:"^@*^@interval";i:0;s:11:"^@*^@multiple";s:1:"0";s:10:"^@*^@cronCmd";s:10:"30 * * * *";s:23:"^@*^@isNewSingleExecution";b:0;}s:16:"^@*^@executionTime";i:1580146200;s:14:"^@*^@descript ion";s:0:"";s:12:"^@*^@taskGroup";i:1;s:9:"^@*^@logger";N;}
serialized_executions  | 
task_group             | 1
(Escaped email, leading to invalid serialization above)

And structure:

+-----+------------------------+-------------------+---------+------------+----+
| cid | name                   | type              | notnull | dflt_value | pk |
+-----+------------------------+-------------------+---------+------------+----+
| 0   | uid                    | INTEGER           | 1       | <null>     | 1  |
| 1   | crdate                 | INTEGER UNSIGNED  | 1       | 0          | 0  |
| 2   | disable                | SMALLINT UNSIGNED | 1       | 0          | 0  |
| 3   | deleted                | SMALLINT UNSIGNED | 1       | 0          | 0  |
| 4   | description            | CLOB              | 0       | NULL       | 0  |
| 5   | nextexecution          | INTEGER UNSIGNED  | 1       | 0          | 0  |
| 6   | lastexecution_time     | INTEGER UNSIGNED  | 1       | 0          | 0  |
| 7   | lastexecution_failure  | CLOB              | 0       | NULL       | 0  |
| 8   | lastexecution_context  | VARCHAR(3)        | 1       | ''         | 0  |
| 9   | serialized_task_object | BLOB              | 0       | NULL       | 0  |
| 10  | serialized_executions  | BLOB              | 0       | NULL       | 0  |
| 11  | task_group             | INTEGER UNSIGNED  | 1       | 0          | 0  |
+-----+------------------------+-------------------+---------+------------+----+

at count(false)
in /home/daniels/Projects/own/website-typo3/project/private/typo3/sysext/scheduler/Classes/Scheduler.php line 130

}
}
}
$executionCount = count($executions);
if (count($serialized_executions) !== $executionCount) {
// if (is_array($serialized_executions) && count($serialized_executions) !== $executionCount) {
if ($executionCount === 0) {
$value = '';
} else {


Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #89697: Scheduler writes invalid 'serialized_task_object' to databaseClosed2019-11-17

Actions
Actions

Also available in: Atom PDF