Updated Rector to commit 037153ba50e85666dc8bdc90f832ea4c0ff3677e

037153ba50 [DX] Fix missing Rector\RectorGenerator\Exception\ConfigurationException (#5558)
This commit is contained in:
Tomas Votruba 2024-02-04 21:53:39 +00:00
parent 8e25ebe2a2
commit 8cb186674a
3 changed files with 7 additions and 7 deletions

View File

@ -32,7 +32,7 @@ use Rector\Php80\ValueObject\DoctrineTagAndAnnotationToAttribute;
use Rector\PhpAttribute\NodeFactory\PhpAttributeGroupFactory; use Rector\PhpAttribute\NodeFactory\PhpAttributeGroupFactory;
use Rector\PhpDocParser\PhpDocParser\PhpDocNodeTraverser; use Rector\PhpDocParser\PhpDocParser\PhpDocNodeTraverser;
use Rector\Rector\AbstractRector; use Rector\Rector\AbstractRector;
use Rector\RectorGenerator\Exception\ConfigurationException; use Rector\Exception\Configuration\InvalidConfigurationException;
use Rector\ValueObject\PhpVersionFeature; use Rector\ValueObject\PhpVersionFeature;
use Rector\VersionBonding\Contract\MinPhpVersionInterface; use Rector\VersionBonding\Contract\MinPhpVersionInterface;
use Symplify\RuleDocGenerator\ValueObject\CodeSample\ConfiguredCodeSample; use Symplify\RuleDocGenerator\ValueObject\CodeSample\ConfiguredCodeSample;
@ -143,7 +143,7 @@ CODE_SAMPLE
public function refactor(Node $node) : ?Node public function refactor(Node $node) : ?Node
{ {
if ($this->annotationsToAttributes === []) { if ($this->annotationsToAttributes === []) {
throw new ConfigurationException(\sprintf('The "%s" rule requires configuration.', self::class)); throw new InvalidConfigurationException(\sprintf('The "%s" rule requires configuration.', self::class));
} }
$phpDocInfo = $this->phpDocInfoFactory->createFromNode($node); $phpDocInfo = $this->phpDocInfoFactory->createFromNode($node);
if (!$phpDocInfo instanceof PhpDocInfo) { if (!$phpDocInfo instanceof PhpDocInfo) {

View File

@ -19,12 +19,12 @@ final class VersionResolver
* @api * @api
* @var string * @var string
*/ */
public const PACKAGE_VERSION = 'ba1cad35898880f6de97c9743aab96d2ac90ba73'; public const PACKAGE_VERSION = '037153ba50e85666dc8bdc90f832ea4c0ff3677e';
/** /**
* @api * @api
* @var string * @var string
*/ */
public const RELEASE_DATE = '2024-02-05 04:08:15'; public const RELEASE_DATE = '2024-02-05 04:51:31';
/** /**
* @var int * @var int
*/ */

View File

@ -4,7 +4,7 @@ declare (strict_types=1);
namespace Rector\Util; namespace Rector\Util;
use RectorPrefix202402\Nette\Utils\Strings; use RectorPrefix202402\Nette\Utils\Strings;
use Rector\RectorGenerator\Exception\ConfigurationException; use Rector\Exception\Configuration\InvalidConfigurationException;
use Rector\ValueObject\Configuration; use Rector\ValueObject\Configuration;
/** /**
* @inspiration https://github.com/phpstan/phpstan-src/commit/ccc046ca473dcdb5ce9225cc05d7808f2e327f40 * @inspiration https://github.com/phpstan/phpstan-src/commit/ccc046ca473dcdb5ce9225cc05d7808f2e327f40
@ -26,7 +26,7 @@ final class MemoryLimiter
$memorySetResult = \ini_set('memory_limit', $memoryLimit); $memorySetResult = \ini_set('memory_limit', $memoryLimit);
if ($memorySetResult === \false) { if ($memorySetResult === \false) {
$errorMessage = \sprintf('Memory limit "%s" cannot be set.', $memoryLimit); $errorMessage = \sprintf('Memory limit "%s" cannot be set.', $memoryLimit);
throw new ConfigurationException($errorMessage); throw new InvalidConfigurationException($errorMessage);
} }
} }
private function validateMemoryLimitFormat(string $memoryLimit) : void private function validateMemoryLimitFormat(string $memoryLimit) : void
@ -36,6 +36,6 @@ final class MemoryLimiter
return; return;
} }
$errorMessage = \sprintf('Invalid memory limit format "%s".', $memoryLimit); $errorMessage = \sprintf('Invalid memory limit format "%s".', $memoryLimit);
throw new ConfigurationException($errorMessage); throw new InvalidConfigurationException($errorMessage);
} }
} }