Project

General

Profile

Bug #87312

Updated by Guido Schmechel over 5 years ago

*Content:* 

 * Given is a Symfony console command registered with "test:job" 
 * This job has one required argument "message" 
 * Activate two tasks in the scheduler, e.g. every two minutes 
 * TYPO Cronjob run every minute 
 * Task 1 with argument "hello", Task 2 with Argument "world" 

 *Error message* 

 <pre> 
 a:5:{s:4:"code";i:0;s:7:"message";s:42:"Not enough arguments (missing: "command").";s:4:"file";s:66:"project\vendor\symfony\console\Input\Input.php";s:4:"line";i:76;s:11:"traceString";s:2742:"#0 project\vendor\symfony\console\Input\Input.php(42): Symfony\Component\Console\Input\Input->validate() 
 #1 project\vendor\symfony\console\Input\ArrayInput.php(34): Symfony\Component\Console\Input\Input->__construct(Object(Symfony\Component\Console\Input\InputDefinition)) 
 #2 project\public\typo3\sysext\scheduler\Classes\Task\ExecuteSchedulableCommandTask.php(88): Symfony\Component\Console\Input\ArrayInput->__construct(Array, Object(Symfony\Component\Console\Input\InputDefinition)) 
 #3 project\public\typo3\sysext\scheduler\Classes\Scheduler.php(180): TYPO3\CMS\Scheduler\Task\ExecuteSchedulableCommandTask->execute() 
 #4 project\public\typo3\sysext\scheduler\Classes\Command\SchedulerCommand.php(145): TYPO3\CMS\Scheduler\Scheduler->executeTask(Object(TYPO3\CMS\Scheduler\Task\ExecuteSchedulableCommandTask)) 
 #5 project\public\typo3\sysext\scheduler\Classes\Command\SchedulerCommand.php(99): TYPO3\CMS\Scheduler\Command\SchedulerCommand->loopTasks() 
 #6 project\vendor\symfony\console\Command\Command.php(255): TYPO3\CMS\Scheduler\Command\SchedulerCommand->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) 
 #7 project\vendor\symfony\console\Application.php(901): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) 
 #8 project\vendor\symfony\console\Application.php(262): Symfony\Component\Console\Application->doRunCommand(Object(TYPO3\CMS\Scheduler\Command\SchedulerCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) 
 #9 project\vendor\symfony\console\Application.php(145): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) 
 #10 project\public\typo3\sysext\core\Classes\Console\CommandRequestHandler.php(63): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) 
 #11 project\public\typo3\sysext\core\Classes\Console\CommandApplication.php(48): TYPO3\CMS\Core\Console\CommandRequestHandler->handleRequest(Object(Symfony\Component\Console\Input\ArgvInput)) 
 #12 project\public\typo3\sysext\core\bin\typo3(23): TYPO3\CMS\Core\Console\CommandApplication->run() 
 #13 project\public\typo3\sysext\core\bin\typo3(24): {closure}() 
 #14 {main}";} 
 </pre> 

 *Problem description*: 

 *(Possible) Problemdescription:* 
 * TYPO3 processes the jobs sequentially 
 * First call is "scheduler:run" 
 * Second call is our Task 1  
 * vendor/symfony/console/Command/Command.php has no "command" and use it from the serialized task. So we have now "test:job" as command and "hello" as message. 
 * Third call (Task 2) has only the argument message "world" and TYPO3 runs the job without the command and save the trace in the database field

Back