Skip to content

Commit df3e89e

Browse files
committed
Merge branch '5.4' into 6.0
* 5.4: [Security][WIP] Add authenticators info to the profiler [Translation] Use symfony default locale when pulling translations from providers added missing translations for Bosnian (bs) Add the missing greek translations for security core and validator component [HttpKernel] Fix return types in `EventDataCollector` Do not call substr_count() if ip is null to avoid deprecation warning in PHP 8.1 [Security][Validator] Add missing translations for Slovenian (sl) [Messenger] Add worker metadata inside logs [Messenger] Log when worker should stop and when `SIGTERM` is received cs fix [Security][Validator] Add missing translations for Finnish (fi) [VarDumper] returns a 500 when dd() is executed chore(VarDumper): declare that dd() never returns [MonologBridge] Deprecate the Swiftmailer handler [Cache] Commit items implicitly only when deferred keys are requested [MonologBridge] Deprecates ResetLoggersWorkerSubscriber Fix "can not" spelling [HttpClient] fix missing kernel.reset tag on TraceableHttpClient services [Form] Fix ChoiceType Extension to effectively set and use the translator Added new CssColor constraint
2 parents 6d4b8b3 + b076aa9 commit df3e89e

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

Process.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -523,7 +523,7 @@ public function disableOutput(): static
523523
throw new RuntimeException('Disabling output while the process is running is not possible.');
524524
}
525525
if (null !== $this->idleTimeout) {
526-
throw new LogicException('Output can not be disabled while an idle timeout is set.');
526+
throw new LogicException('Output cannot be disabled while an idle timeout is set.');
527527
}
528528

529529
$this->outputDisabled = true;
@@ -788,7 +788,7 @@ public function getTermSignal(): int
788788
$this->requireProcessIsTerminated(__FUNCTION__);
789789

790790
if ($this->isSigchildEnabled() && -1 === $this->processInformation['termsig']) {
791-
throw new RuntimeException('This PHP has been compiled with --enable-sigchild. Term signal can not be retrieved.');
791+
throw new RuntimeException('This PHP has been compiled with --enable-sigchild. Term signal cannot be retrieved.');
792792
}
793793

794794
return $this->processInformation['termsig'];
@@ -992,7 +992,7 @@ public function setTimeout(?float $timeout): static
992992
public function setIdleTimeout(?float $timeout): static
993993
{
994994
if (null !== $timeout && $this->outputDisabled) {
995-
throw new LogicException('Idle timeout can not be set while the output is disabled.');
995+
throw new LogicException('Idle timeout cannot be set while the output is disabled.');
996996
}
997997

998998
$this->idleTimeout = $this->validateTimeout($timeout);
@@ -1101,7 +1101,7 @@ public function getEnv(): array
11011101
*/
11021102
public function setEnv(array $env): static
11031103
{
1104-
// Process can not handle env values that are arrays
1104+
// Process cannot handle env values that are arrays
11051105
$env = array_filter($env, function ($value) {
11061106
return !\is_array($value);
11071107
});
@@ -1135,7 +1135,7 @@ public function getInput()
11351135
public function setInput(mixed $input): static
11361136
{
11371137
if ($this->isRunning()) {
1138-
throw new LogicException('Input can not be set while the process is running.');
1138+
throw new LogicException('Input cannot be set while the process is running.');
11391139
}
11401140

11411141
$this->input = ProcessUtils::validateInput(__METHOD__, $input);
@@ -1452,7 +1452,7 @@ private function doSignal(int $signal, bool $throwException): bool
14521452
{
14531453
if (null === $pid = $this->getPid()) {
14541454
if ($throwException) {
1455-
throw new LogicException('Can not send signal on a non running process.');
1455+
throw new LogicException('Cannot send signal on a non running process.');
14561456
}
14571457

14581458
return false;

Tests/ProcessTest.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ public function testLiveStreamAsInput()
276276
public function testSetInputWhileRunningThrowsAnException()
277277
{
278278
$this->expectException(LogicException::class);
279-
$this->expectExceptionMessage('Input can not be set while the process is running.');
279+
$this->expectExceptionMessage('Input cannot be set while the process is running.');
280280
$process = $this->getProcessForCode('sleep(30);');
281281
$process->start();
282282
try {
@@ -938,7 +938,7 @@ public function testExitCodeIsAvailableAfterSignal()
938938
public function testSignalProcessNotRunning()
939939
{
940940
$this->expectException(LogicException::class);
941-
$this->expectExceptionMessage('Can not send signal on a non running process.');
941+
$this->expectExceptionMessage('Cannot send signal on a non running process.');
942942
$process = $this->getProcess('foo');
943943
$process->signal(1); // SIGHUP
944944
}
@@ -1057,7 +1057,7 @@ public function testEnableOrDisableOutputAfterRunDoesNotThrowException()
10571057
public function testDisableOutputWhileIdleTimeoutIsSet()
10581058
{
10591059
$this->expectException(LogicException::class);
1060-
$this->expectExceptionMessage('Output can not be disabled while an idle timeout is set.');
1060+
$this->expectExceptionMessage('Output cannot be disabled while an idle timeout is set.');
10611061
$process = $this->getProcess('foo');
10621062
$process->setIdleTimeout(1);
10631063
$process->disableOutput();
@@ -1066,7 +1066,7 @@ public function testDisableOutputWhileIdleTimeoutIsSet()
10661066
public function testSetIdleTimeoutWhileOutputIsDisabled()
10671067
{
10681068
$this->expectException(LogicException::class);
1069-
$this->expectExceptionMessage('timeout can not be set while the output is disabled.');
1069+
$this->expectExceptionMessage('timeout cannot be set while the output is disabled.');
10701070
$process = $this->getProcess('foo');
10711071
$process->disableOutput();
10721072
$process->setIdleTimeout(1);

0 commit comments

Comments
 (0)