Un warning PHP dans Batch.php avec spipmu et PHP 8.3
Bonjour,
En lançant la commande spipmu, j'ai cette erreur (autant de fois qu'il y a un site) :
Deprecated: Creation of dynamic property SplFileInfo::$host is deprecated in C:\laragon\usr\bin\spip-cli\src\Mutualisation\Command\Batch.php on line 152
Call Stack:
0.0002 495600 1. {main}() C:\laragon\usr\bin\spip-cli\bin\spipmu:0
0.0073 945312 2. Symfony\Component\Console\Application->run($input = ???, $output = ???) C:\laragon\usr\bin\spip-cli\bin\spipmu:23
0.0388 1385336 3. Symfony\Component\Console\Application->doRun($input = class Symfony\Component\Console\Input\ArgvInput { protected $definition = class Symfony\Component\Console\Input\InputDefinition { private $arguments = [...]; private $requiredCount = 0; private $lastArrayArgument = NULL; private $lastOptionalArgument = class Symfony\Component\Console\Input\InputArgument { ... }; private $options = [...]; private $negations = [...]; private $shortcuts = [...] }; protected $stream = NULL; protected $options = []; protected $arguments = ['glob' => '*', 'spip-cli-command' => 'oembed:migrer:videos-dist']; protected $interactive = TRUE; private $tokens = [0 => '*', 1 => 'oembed:migrer:videos-dist']; private $parsed = [] }, $output = class Symfony\Component\Console\Output\ConsoleOutput { private ${Symfony\Component\Console\Output\Output}verbosity = 32; private ${Symfony\Component\Console\Output\Output}formatter = class Symfony\Component\Console\Formatter\OutputFormatter { private $decorated = TRUE; private $styles = [...]; private $styleStack = class Symfony\Component\Console\Formatter\OutputFormatterStyleStack { ... } }; private ${Symfony\Component\Console\Output\StreamOutput}stream = resource(2) of type (stream); private $stderr = class Symfony\Component\Console\Output\StreamOutput { private ${Symfony\Component\Console\Output\Output}verbosity = 32; private ${Symfony\Component\Console\Output\Output}formatter = class Symfony\Component\Console\Formatter\OutputFormatter { ... }; private $stream = resource(3) of type (stream) }; private $consoleSectionOutputs = [] }) C:\laragon\usr\bin\spip-cli\vendor\symfony\console\Application.php:171
0.0444 1790064 4. Symfony\Component\Console\Application->doRunCommand($command = class Spip\Cli\Mutualisation\Command\Batch { private ${Symfony\Component\Console\Command\Command}application = class Spip\Cli\Mutualisation\Application { private ${Symfony\Component\Console\Application}commands = [...]; private ${Symfony\Component\Console\Application}wantHelps = FALSE; private ${Symfony\Component\Console\Application}runningCommand = ...; private ${Symfony\Component\Console\Application}name = 'Spip Cli Mu'; private ${Symfony\Component\Console\Application}version = '1.0.1'; private ${Symfony\Component\Console\Application}commandLoader = NULL; private ${Symfony\Component\Console\Application}catchExceptions = TRUE; private ${Symfony\Component\Console\Application}autoExit = TRUE; private ${Symfony\Component\Console\Application}definition = class Symfony\Component\Console\Input\InputDefinition { ... }; private ${Symfony\Component\Console\Application}helperSet = class Symfony\Component\Console\Helper\HelperSet { ... }; private ${Symfony\Component\Console\Application}dispatcher = NULL; private ${Symfony\Component\Console\Application}terminal = class Symfony\Component\Console\Terminal { ... }; private ${Symfony\Component\Console\Application}defaultCommand = 'list'; private ${Symfony\Component\Console\Application}singleCommand = FALSE; private ${Symfony\Component\Console\Application}initialized = TRUE; private ${Symfony\Component\Console\Application}signalRegistry = NULL; private ${Symfony\Component\Console\Application}signalsToDispatchEvent = [...]; protected $options = [...]; protected $container = class Spip\Cli\Container\Container { ... } }; private ${Symfony\Component\Console\Command\Command}name = 'Batch'; private ${Symfony\Component\Console\Command\Command}processTitle = NULL; private ${Symfony\Component\Console\Command\Command}aliases = []; private ${Symfony\Component\Console\Command\Command}definition = class Symfony\Component\Console\Input\InputDefinition { private $arguments = [...]; private $requiredCount = 0; private $lastArrayArgument = NULL; private $lastOptionalArgument = class Symfony\Component\Console\Input\InputArgument { ... }; private $options = [...]; private $negations = [...]; private $shortcuts = [...] }; private ${Symfony\Component\Console\Command\Command}hidden = FALSE; private ${Symfony\Component\Console\Command\Command}help = ''; private ${Symfony\Component\Console\Command\Command}description = 'Exécute une commande sur les sites d’une mutualisation'; private ${Symfony\Component\Console\Command\Command}fullDefinition = class Symfony\Component\Console\Input\InputDefinition { private $arguments = [...]; private $requiredCount = 0; private $lastArrayArgument = NULL; private $lastOptionalArgument = class Symfony\Component\Console\Input\InputArgument { ... }; private $options = [...]; private $negations = [...]; private $shortcuts = [...] }; private ${Symfony\Component\Console\Command\Command}ignoreValidationErrors = FALSE; private ${Symfony\Component\Console\Command\Command}code = NULL; private ${Symfony\Component\Console\Command\Command}synopsis = []; private ${Symfony\Component\Console\Command\Command}usages = []; private ${Symfony\Component\Console\Command\Command}helperSet = class Symfony\Component\Console\Helper\HelperSet { private $helpers = [...]; private $command = NULL }; protected $io = class Spip\Cli\Console\Style\SpipCliStyle { private ${Symfony\Component\Console\Style\OutputStyle}output = class Symfony\Component\Console\Output\ConsoleOutput { ... }; private ${Symfony\Component\Console\Style\SymfonyStyle}input = class Symfony\Component\Console\Input\ArgvInput { ... }; private ${Symfony\Component\Console\Style\SymfonyStyle}output = class Symfony\Component\Console\Output\ConsoleOutput { ... }; private ${Symfony\Component\Console\Style\SymfonyStyle}questionHelper = NULL; private ${Symfony\Component\Console\Style\SymfonyStyle}progressBar = NULL; private ${Symfony\Component\Console\Style\SymfonyStyle}lineLength = 120; private ${Symfony\Component\Console\Style\SymfonyStyle}bufferedOutput = class Symfony\Component\Console\Output\TrimmedBufferOutput { ... } }; protected $dir_sites = 'sites'; protected $connect = 'config/connect.php' }, $input = class Symfony\Component\Console\Input\ArgvInput { protected $definition = class Symfony\Component\Console\Input\InputDefinition { private $arguments = [...]; private $requiredCount = 0; private $lastArrayArgument = NULL; private $lastOptionalArgument = class Symfony\Component\Console\Input\InputArgument { ... }; private $options = [...]; private $negations = [...]; private $shortcuts = [...] }; protected $stream = NULL; protected $options = []; protected $arguments = ['glob' => '*', 'spip-cli-command' => 'oembed:migrer:videos-dist']; protected $interactive = TRUE; private $tokens = [0 => '*', 1 => 'oembed:migrer:videos-dist']; private $parsed = [] }, $output = class Symfony\Component\Console\Output\ConsoleOutput { private ${Symfony\Component\Console\Output\Output}verbosity = 32; private ${Symfony\Component\Console\Output\Output}formatter = class Symfony\Component\Console\Formatter\OutputFormatter { private $decorated = TRUE; private $styles = [...]; private $styleStack = class Symfony\Component\Console\Formatter\OutputFormatterStyleStack { ... } }; private ${Symfony\Component\Console\Output\StreamOutput}stream = resource(2) of type (stream); private $stderr = class Symfony\Component\Console\Output\StreamOutput { private ${Symfony\Component\Console\Output\Output}verbosity = 32; private ${Symfony\Component\Console\Output\Output}formatter = class Symfony\Component\Console\Formatter\OutputFormatter { ... }; private $stream = resource(3) of type (stream) }; private $consoleSectionOutputs = [] }) C:\laragon\usr\bin\spip-cli\vendor\symfony\console\Application.php:301
0.0444 1790064 5. Symfony\Component\Console\Command\Command->run($input = class Symfony\Component\Console\Input\ArgvInput { protected $definition = class Symfony\Component\Console\Input\InputDefinition { private $arguments = [...]; private $requiredCount = 0; private $lastArrayArgument = NULL; private $lastOptionalArgument = class Symfony\Component\Console\Input\InputArgument { ... }; private $options = [...]; private $negations = [...]; private $shortcuts = [...] }; protected $stream = NULL; protected $options = []; protected $arguments = ['glob' => '*', 'spip-cli-command' => 'oembed:migrer:videos-dist']; protected $interactive = TRUE; private $tokens = [0 => '*', 1 => 'oembed:migrer:videos-dist']; private $parsed = [] }, $output = class Symfony\Component\Console\Output\ConsoleOutput { private ${Symfony\Component\Console\Output\Output}verbosity = 32; private ${Symfony\Component\Console\Output\Output}formatter = class Symfony\Component\Console\Formatter\OutputFormatter { private $decorated = TRUE; private $styles = [...]; private $styleStack = class Symfony\Component\Console\Formatter\OutputFormatterStyleStack { ... } }; private ${Symfony\Component\Console\Output\StreamOutput}stream = resource(2) of type (stream); private $stderr = class Symfony\Component\Console\Output\StreamOutput { private ${Symfony\Component\Console\Output\Output}verbosity = 32; private ${Symfony\Component\Console\Output\Output}formatter = class Symfony\Component\Console\Formatter\OutputFormatter { ... }; private $stream = resource(3) of type (stream) }; private $consoleSectionOutputs = [] }) C:\laragon\usr\bin\spip-cli\vendor\symfony\console\Application.php:1040
0.0445 1792200 6. Spip\Cli\Mutualisation\Command\Batch->execute($input = class Symfony\Component\Console\Input\ArgvInput { protected $definition = class Symfony\Component\Console\Input\InputDefinition { private $arguments = [...]; private $requiredCount = 0; private $lastArrayArgument = NULL; private $lastOptionalArgument = class Symfony\Component\Console\Input\InputArgument { ... }; private $options = [...]; private $negations = [...]; private $shortcuts = [...] }; protected $stream = NULL; protected $options = []; protected $arguments = ['glob' => '*', 'spip-cli-command' => 'oembed:migrer:videos-dist']; protected $interactive = TRUE; private $tokens = [0 => '*', 1 => 'oembed:migrer:videos-dist']; private $parsed = [] }, $output = class Symfony\Component\Console\Output\ConsoleOutput { private ${Symfony\Component\Console\Output\Output}verbosity = 32; private ${Symfony\Component\Console\Output\Output}formatter = class Symfony\Component\Console\Formatter\OutputFormatter { private $decorated = TRUE; private $styles = [...]; private $styleStack = class Symfony\Component\Console\Formatter\OutputFormatterStyleStack { ... } }; private ${Symfony\Component\Console\Output\StreamOutput}stream = resource(2) of type (stream); private $stderr = class Symfony\Component\Console\Output\StreamOutput { private ${Symfony\Component\Console\Output\Output}verbosity = 32; private ${Symfony\Component\Console\Output\Output}formatter = class Symfony\Component\Console\Formatter\OutputFormatter { ... }; private $stream = resource(3) of type (stream) }; private $consoleSectionOutputs = [] }) C:\laragon\usr\bin\spip-cli\vendor\symfony\console\Command\Command.php:298
0.0515 2660488 7. Spip\Cli\Mutualisation\Command\Batch->getHosts($sites = [0 => class SplFileInfo { public $host = 'crossmedia.diocese-avignon.fr.localhost'; private $pathName = 'C:\\laragon\\_mutudio_\\sites\\crossmedia.diocese-avignon.fr'; private $fileName = 'crossmedia.diocese-avignon.fr' }, 1 => class SplFileInfo { public $host = 'diocese-avignon.fr.localhost'; private $pathName = 'C:\\laragon\\_mutudio_\\sites\\diocese-avignon.fr'; private $fileName = 'diocese-avignon.fr' }, 2 => class SplFileInfo { public $host = 'fmdialoguededieu.localhost'; private $pathName = 'C:\\laragon\\_mutudio_\\sites\\fmdialoguededieu'; private $fileName = 'fmdialoguededieu' }, 3 => class SplFileInfo { public $host = 'testinstallavignon.localhost'; private $pathName = 'C:\\laragon\\_mutudio_\\sites\\testinstallavignon'; private $fileName = 'testinstallavignon' }, 4 => class SplFileInfo { private $pathName = 'C:\\laragon\\_mutudio_\\sites\\trinitaires84'; private $fileName = 'trinitaires84' }]) C:\laragon\usr\bin\spip-cli\src\Mutualisation\Command\Batch.php:72```
Testé en SPIP 4.3.2 / PHP 8.3 / Windows avec SPIP-cli mis à jour