Skip to content

chore(deps): update dependency rector/rector to v2.5.2#455

Open
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/rector-rector-2.x
Open

chore(deps): update dependency rector/rector to v2.5.2#455
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/rector-rector-2.x

Conversation

@renovate

@renovate renovate Bot commented Jun 20, 2026

Copy link
Copy Markdown
Contributor

This PR contains the following updates:

Package Change Age Confidence
rector/rector (source) 2.4.52.5.2 age confidence

Warning

Some dependencies could not be looked up. Check the Dependency Dashboard for more information.


Release Notes

rectorphp/rector (rector/rector)

v2.5.2: Released Rector 2.5.2

Compare Source

Bugfixes 🐛

  • Match class + path in unused-skip reporting — fix combined class => [paths] skips being wrongly flagged as unused (#​8073)
  • Mark skip used only when rule would change the file — a class/path skip counts as "used" only if the rule would actually touch that file, killing false "used" hits (#​8076)
  • Improve unused-skip resolver methods — cleaner resolution internals (#​8072)
  • Track used skips as class => [paths] map — richer per-path skip tracking backing the report (#​8074)

v2.5.1

Compare Source

v2.5.0: Released Rector 2.5

Compare Source

New Features 🥳 🎉 🎉 🎉

This release has 3 interesting new features. Let's look at them:

[dx] Report skips that never matched (#​8058)
  • What? - like PHPStan's reportUnusedIgnores, but for Rector ->withSkip(). Flags skip entries that never matched anything during the run, so you can delete stale skips.

  • Why? - skips rot. You skip a path/rule to dodge a problem, later the file moves or the rule stops firing there — the skip lingers forever,
    silently masking nothing. This surfaces dead skips so config stays honest.

// rector.php
return RectorConfig::configure()
    ->withSkip([
        SimplifyUselessVariableRector::class => [
            '*/src/Legacy/*',          // still matches — fine
            '*/NonexistentUnused/*',   // matches nothing — stale
        ],
    ])
    ->reportUnusedSkips();

Run output:

 [OK] Rector is done!
  
 [WARNING] This skip is unused, it never matched any element.
           You can remove it from "->withSkip()"

 * Rector\CodeQuality\Rector\FunctionLike\SimplifyUselessVariableRector => */NonexistentUnused/*

[dx] Removing unused imports by default (#​8047)

You can update your rector.php config:

 return RectorConfig::configure()
-    ->withImportNames(removeUnusedImports: true);
+    ->withImportNames();

In case it's not for you, turn it off:

 return RectorConfig::configure()
-    ->withImportNames();
+    ->withImportNames(removeUnusedImports: false);

[dx] Introducing Drupal composer-based sets (#​8041), Thanks @​bbrala!

If you're using Drupal Rector, you can now enable it's per-version sets via:

 return RectorConfig::configure()
+    ->withComposerBased(drupal: true);

To learn more about composer-based-sets, checkout the documentation.


New Rules 🎉
  • [php 8.4] [type-declaration] Add AddArrayAnyAllClosureParamTypeRector and NarrowArrayAnyAllNullableParamTypeRector (#​8049)
  • [code-quality] Add MoveInnerFunctionToTopLevelRector (#​8042)
  • [code-quality] Add NewArrayItemConcatAssignToAssignRector (#​8045)
  • [code-quality] Add FixClassCaseSensitivityVarDocblockRector (#​8046)
  • [polyfills] add missing polyfill to PHP 8.4 array functions (#​8052)
  • [rector] Add AddParamTypeToRefactorMethodRector if missing (#​8061)

Bugfixes 🐛

  • [internal] Streamline use imports management to FileNode (#​8040)
  • [PostRector] Do not keep an unused import matched only by a partial docblock name's tail (#​8043), Thanks @​ruudk!
  • [CodeQuality] Skip native function on MoveInnerFunctionToTopLevelRector (#​8044)
  • Fix --only runs caching files as unchanged, hiding pending changes from full runs (#​8029), Thanks @​SanderMuller!
  • [fix] Fix RemoveUnusedPrivateMethodRector for NeverType (#​8050)
  • [dead-code] Fix RemoveUnusedVariableAssignRector, allow for SplFileInfo as cleanup on purpose for gc (#​8054)
  • [fixes] Couple ClassPropertyAssignToConstructorPromotionRector, RemoveAlwaysTrueIfConditionRector and RemoveUnusedVariableAssignRector fixes (#​8055)
  • [TypeDeclaration][DeadCode] Skip class with Doctrine static function mapping (loadMetadata) in TypedPropertyFromAssignsRector and RemoveUnusedPrivatePropertyRector (#​8059)
  • [TypeDeclaration] Skip class with Doctrine static function mapping (loadMetadata) in TypedPropertyFromStrictConstructorRector (#​8060)

rectorphp/rector-doctrine 🟠

  • [NodeAnalyzer] Detect Doctrine static function mapping (loadMetadata) entity in DoctrineEntityDetector (736bf61)

v2.4.6: Released Rector 2.4.6

Compare Source

New Features 🥳

  • [deprecation] Add RenameDeprecatedMethodCallRector inferring rename from @​deprecated docblock (#​8015)
  • [sets] kick of named args set (#​8013)
# rector.php
return (RectorConfig::configure())
    ->withPreparedSets(namedArgs: true);

Bugfixes 🐛

  • [BetterPhpDocParser] Keep import referenced by @​see/@​uses tag with a trailing description (#​8039), Thanks @​ruudk!
  • [internals] skip and finalize beforeTraverse() and afterTraverse() as never used, use refactor() instead (#​7765)
  • [DeadCode] Skip (void) cast with #[NoDiscard] on target method call on RemoveDeadStmtRector (#​8038)
  • Bump composer/pcre to ^3.4.0 and phpstan/phpstan to ^2.2.2 (#​8037)
  • [CodeQuality] Handle crash on custom exception not autoloaded on ThrowWithPreviousExceptionRector (#​8036)
  • refactor: extract AutoloadFileParameterResolver from bin, add tests (#​8035), Thanks @​SanderMuller!
  • Fix cached results surviving a change of --autoload-file (#​8034), Thanks @​SanderMuller!
  • [CodingStyle] Remove AstResolver usage on ArrowFunctionAndClosureFirstClassCallableGuard (#​8031)
  • [DeadCode] Remove AstResolver on RemoveParentCallWithoutParentRector (#​8032)
  • [DeadCode] Skip with use of func_num_args() on RemoveNullArgOnNullDefaultParamRector (#​8030)
  • [Php70] Skip rewriting to $this on static method or static closure on StaticCallOnNonStaticToInstanceCallRector (#​8026)
  • [ci] add compat test (#​8025)
  • Fix ReplaceArgumentDefaultValueRector generating invalid self:: constant in unrelated classes (#​8023)
  • Fix RemoveDeadIfBlockRector dropping else block when merging empty if with elseif (#​8022)
  • Fix RemoveParentCallWithoutParentRector removing valid call when ancestor hierarchy is unresolvable (#​8018)
  • split of RemoveNullNamedArgOnNullDefaultParamRector to handle only named args (#​8014)
  • Add failing tests (#​8012), Thanks @​u01jmg3!
  • Update rector/swiss-knife version to ^2.4.1 (#​8011)

rectorphp/rector-symfony 🎶

  • [Symfony81] Add new rule for deprecated validator test usages (#​948), Thanks @​florianhofsaessC24!
  • fix: only convert Twig extensions fully reducible to AsTwig attributes (#​947)
  • [Symfony73] Sort optional parameters last in InvokableCommandInputAttributeRector (#​945)
  • Add PHPStan rule requiring nested set configs to be imported in parent set config (#​943)
  • [Symfony81] Add new rule for Security component (#​942), Thanks @​MrYamous!
  • Remove unused imports (#​941), Thanks @​MrYamous!
  • [Symfony81] Add new rule for Filesystem (#​940), Thanks @​MrYamous!

rectorphp/rector-phpunit 🟢

  • [PHPUnit12] Handle crash on property not exists on PropertyCreateMockToCreateStubRector (#​681)
  • [AnnotationsToAttributes] Convert external @​depends ClassName::method to #[DependsExternal] (#​679)
  • [PHPUnit12] Drop ConstraintValidatorTestCase from AllowMockObjectsWhereParentClassRector triggers (#​678)

rectorphp/rector-downgrade-php ⬇️

  • Add DowngradeDomNodeChildNodesForeachRector for null $childNodes before PHP 8.0 (#​379)
  • Update boundwize/structarmed version to ^0.9 (#​378)
  • Fix use of existing PhpAttributeAnalyzer service on AddReturnTypeWillChangeAttributeRector (#​377)
  • Remove no longer exists '--ansi' flag from swiss-knife (#​376)
  • [DowngradePhp81] Add AddReturnTypeWillChangeAttributeRector (#​372), Thanks @​jquiaios!

Configuration

📅 Schedule: (UTC)

  • Branch creation
    • Only on Sunday and Saturday (* * * * 0,6)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Enabled.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate Bot force-pushed the renovate/rector-rector-2.x branch 3 times, most recently from 90d3aeb to 6d31bb7 Compare June 20, 2026 18:06
@renovate renovate Bot changed the title chore(deps): update dependency rector/rector to v2.4.6 chore(deps): update dependency rector/rector to v2.5.0 Jun 20, 2026
@renovate renovate Bot force-pushed the renovate/rector-rector-2.x branch from 6d31bb7 to 130b2ee Compare June 21, 2026 13:27
@renovate renovate Bot changed the title chore(deps): update dependency rector/rector to v2.5.0 chore(deps): update dependency rector/rector to v2.5.1 Jun 21, 2026
@renovate renovate Bot force-pushed the renovate/rector-rector-2.x branch from 130b2ee to a3a29a9 Compare June 22, 2026 18:59
@renovate renovate Bot changed the title chore(deps): update dependency rector/rector to v2.5.1 chore(deps): update dependency rector/rector to v2.5.2 Jun 22, 2026
@renovate renovate Bot force-pushed the renovate/rector-rector-2.x branch 4 times, most recently from 107ec3e to ded2787 Compare June 27, 2026 18:36
@renovate renovate Bot force-pushed the renovate/rector-rector-2.x branch from ded2787 to 6714d86 Compare June 27, 2026 20:38
@github-actions

Copy link
Copy Markdown

Code Coverage

Package Line Rate Complexity Health
Command/AliasAddCommand.php 93% 12
Command/DKIMDisableCommand.php 96% 6
Command/DKIMSetupCommand.php 95% 16
Command/DomainAddCommand.php 94% 6
Command/FetchmailAccountAddCommand.php 93% 9
Command/InitSetupCommand.php 100% 13
Command/RedisSyncCommand.php 90% 4
Command/SystemCheckCommand.php 94% 24
Command/Trait/ConnectionCheckTrait.php 73% 3
Command/UserAddCommand.php 80% 11
Command/VersionCheckCommand.php 100% 13
Controller/Admin/AliasCrudController.php 79% 11
Controller/Admin/DKIMCrudController.php 100% 6
Controller/Admin/DashboardController.php 97% 10
Controller/Admin/DnsWizardAction.php 94% 7
Controller/Admin/DomainCrudController.php 100% 5
Controller/Admin/Observability/DovecotStatsController.php 100% 22
Controller/Admin/Observability/RspamdStatsController.php 98% 11
Controller/Admin/UserCrudController.php 81% 18
Controller/Autoconfig/AutoconfigAction.php 100% 4
Controller/Autoconfig/AutodiscoverAction.php 100% 4
Controller/Security/LoginAction.php 100% 3
Controller/Security/LogoutAction.php 100% 1
Controller/User/ChangePasswordAction.php 96% 6
Controller/User/FetchmailAccountController.php 70% 16
Controller/User/MobileConfigAction.php 67% 4
DependencyInjection/Compiler/AppSecretGeneratorCompilerPass.php 100% 7
Entity/Alias.php 100% 9
Entity/DkimInfoTrait.php 100% 6
Entity/Domain.php 100% 13
Entity/FetchmailAccount.php 100% 17
Entity/User.php 88% 30
Exception/DKIM/DomainKeyNotFoundException.php 0% 0
Exception/DomainNotFoundException.php 100% 1
Exception/Dovecot/DoveadmAuthenticationException.php 0% 0
Exception/Dovecot/DoveadmConnectionException.php 0% 0
Exception/Dovecot/DoveadmException.php 0% 0
Exception/Dovecot/DoveadmResponseException.php 0% 0
Factory/UserFactory.php 100% 5
Form/Type/ChangePasswordType.php 100% 2
Form/Type/OAuthRegisterType.php 100% 2
Kernel.php 0% 1
Repository/AliasRepository.php 100% 1
Repository/DomainRepository.php 100% 1
Repository/FetchmailAccountRepository.php 100% 1
Repository/UserRepository.php 85% 4
Service/ApplicationVersionService.php 100% 8
Service/ConnectionCheckService.php 100% 28
Service/DKIM/Config/Manager.php 100% 2
Service/DKIM/Config/MapGenerator.php 100% 7
Service/DKIM/DKIMStatus.php 100% 5
Service/DKIM/DKIMStatusService.php 100% 7
Service/DKIM/DomainKeyReaderService.php 100% 4
Service/DKIM/FormatterService.php 100% 1
Service/DKIM/KeyGenerationService.php 100% 3
Service/DKIM/KeyPair.php 100% 3
Service/DKIM/RuntimeDataLoader.php 100% 3
Service/DnsWizard/Check/ARecordCheck.php 100% 10
Service/DnsWizard/Check/AaaaRecordCheck.php 100% 10
Service/DnsWizard/Check/AutodiscoveryRecordCheck.php 100% 28
Service/DnsWizard/Check/DkimRecordCheck.php 100% 8
Service/DnsWizard/Check/DmarcRecordCheck.php 100% 10
Service/DnsWizard/Check/DnsCheckInterface.php 0% 0
Service/DnsWizard/Check/MxRecordCheck.php 100% 10
Service/DnsWizard/Check/PtrRecordCheck.php 100% 8
Service/DnsWizard/Check/SpfRecordCheck.php 100% 10
Service/DnsWizard/DnsLookupInterface.php 0% 0
Service/DnsWizard/DnsWizardRow.php 100% 1
Service/DnsWizard/DnsWizardStatus.php 0% 0
Service/DnsWizard/DnsWizardValidator.php 100% 6
Service/DnsWizard/ExpectedHostIps.php 100% 2
Service/DnsWizard/HostIpResolver.php 98% 17
Service/DnsWizard/NativeDnsLookup.php 70% 44
Service/DnsWizard/Scopes.php 0% 1
Service/Dovecot/DTO/DoveadmHealthDto.php 100% 7
Service/Dovecot/DTO/HealthStatus.php 0% 0
Service/Dovecot/DTO/RateSeriesDto.php 100% 9
Service/Dovecot/DTO/StatsDumpDto.php 67% 9
Service/Dovecot/DoveadmHttpClient.php 81% 76
Service/Dovecot/DovecotChartFactory.php 99% 9
Service/Dovecot/DovecotRateCalculator.php 100% 21
Service/Dovecot/DovecotStatsSampler.php 97% 17
Service/FetchmailAccount/AccountData.php 100% 1
Service/FetchmailAccount/AccountWriter.php 75% 4
Service/FetchmailAccount/RedisKeys.php 75% 4
Service/FetchmailAccount/RuntimeData.php 0% 0
Service/FetchmailAccount/RuntimeDataLoader.php 100% 4
Service/GitHubTagService.php 100% 8
Service/MobileConfig/MobileConfigService.php 89% 14
Service/Rspamd/DTO/ActionDistributionDto.php 91% 9
Service/Rspamd/DTO/ActionThresholdDto.php 100% 1
Service/Rspamd/DTO/HealthDto.php 100% 7
Service/Rspamd/DTO/HistoryRowDto.php 100% 1
Service/Rspamd/DTO/KpiValueDto.php 14% 7
Service/Rspamd/DTO/RspamdSummaryDto.php 100% 1
Service/Rspamd/DTO/SymbolCounterDto.php 100% 1
Service/Rspamd/DTO/TimeSeriesDto.php 100% 5
Service/Rspamd/RspamdChartFactory.php 96% 24
Service/Rspamd/RspamdClientException.php 100% 5
Service/Rspamd/RspamdConstants.php 0% 1
Service/Rspamd/RspamdControllerClient.php 94% 33
Service/Rspamd/RspamdStatsService.php 87% 117
Service/Security/Roles.php 0% 1
Service/Security/User/OAuth/AccountConnector.php 100% 3
Service/Security/User/OAuth/DenyRegistrationSubscriber.php 100% 5
Service/Security/User/OAuth/RegistrationFormHandler.php 100% 6
Service/Security/User/OAuth/UserProvider.php 100% 18
Service/Security/Voter/DomainAdminVoter.php 100% 10
Service/Security/Voter/FetchmailAccountVoter.php 100% 8
Service/UserChangeListener.php 100% 5
Subscriber/DKIM/ConfigSyncSubscriber.php 100% 5
Subscriber/DKIM/CreatePrivateKeyOnActivationSubscriber.php 92% 8
Twig/VersionExtension.php 100% 9
Validator/DomainName.php 100% 1
Validator/DomainNameValidator.php 74% 12
Summary 92% (2841 / 3077) 1067

Minimum allowed line rate is 60%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants