Skip to content

chore(deps): bump rector/rector from 2.7.0 to 2.8.1 - #768

Open
dependabot[bot] wants to merge 1 commit into
masterfrom
dependabot/composer/rector/rector-2.8.1
Open

dependabot[bot] wants to merge 1 commit into
masterfrom
dependabot/composer/rector/rector-2.8.1

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Oct 30, 2026

Copy link
Copy Markdown
Contributor

Bumps rector/rector from 2.7.0 to 2.8.1.

Release notes

Sourced from rector/rector's releases.

Released Rector 2.8.1

Fixes

  • Fix crash cache due to PHPStan Turbo (#8850)

Released Rector 2.8

Faster runs, single-pass rules, and a leaner rule set 🚀

The Rector core engine is ~26 % faster (1.36x) with ~8 % less memory than 2.7.0.

If you run PHP 8.3+, it's 3x faster using PHPStan Turbo, the native parsing extension shipped with phpstan/phpstan:

Rev Core engine (time / peak RSS)
2.7.0 32.0s / 351 MB
2.8.0 23.6s / 324 MB
2.8.0 + PHPStan Turbo (PHP 8.3+) ~10.0s / ~317 MB

Turbo factor measured on this release via an A/B run on Rector's own rules/ (24-core host, PHP 8.4, cold, identical changed-file fingerprint): ~2.4x wall and ~2.6x worker CPU. Turbo speeds up PHPStan parsing in the workers, so the wall-time gain scales with the available core count.

This release is mostly about speed and reliability. A large performance campaign hoists cheap node guards in front of expensive reflection, scope and type lookups across hundreds of rules, replaces per-node config scans in configurable rules with keyed lookups, and resolves short names and unused imports in a single AST walk.

Rules now converge in a single pass: instead of a re-processing guard, the engine iterates rules to a fixed point and tests enforce idempotency, so a rule that changes a file produces the same result whether it runs once or many times.

We also trimmed the rule set: many niche, context-dependent rules that are not part of any set and rarely used are now deprecated. Deprecated rules still run and print a warning; they will be removed in a future major release. The goal is a smaller set of valuable, reliable rules for everyday upgrades.

New features 🥳

  • [CodeQuality] Add ExplicitNullableObjectInstanceRector, replacing 4 nullable-object instanceof rules (#8636)
  • [Console] Add --all option to list-rules to list every rule in core and rector-* packages (#8637)
  • [Console] Undeprecate the list-rules command (#8533)
  • Respect cgroup/CFS CPU quota when picking the parallel worker count (#8559)
  • Bump to PHPStan 2.3

Performance Improvements 🚀

  • Run the parallel workers with PHPStan Turbo, the native parsing extension shipped with phpstan/phpstan, on PHP 8.3+ - no main-process restart, the workers do the analysis (#8812) Thanks @​SanderMuller
  • Retarget class-level rules to a single Class_/ClassLike node and add getClassReflection() to AbstractRector: RemoveParentDelegatingClassMethodRector, ReturnTypeFromMockObjectRector, AddVoidReturnTypeWhereNoReturnRector and ChangeMethodVisibilityRector (#8824, #8827, #8828, #8830, #8831)
  • Hoist the repeated fully qualified name build in UseImportNameMatcher::resolveName() and resolve the parent class reflection by name in Php4ConstructorRector (#8841, #8838)
  • Drop scope attachment on pre/post increment expressions and remove an unneeded array_values() in BetterStandardPrinter::pArray() (#8814, #8821)
  • Hoist cheap name and structural guards before reflection, scope and type lookups across CodeQuality, DeadCode, CodingStyle, TypeDeclaration, Transform, EarlyReturn and legacy Php rules (#8664, #8666, #8667, #8668, #8669, #8670, #8671, #8672, #8661, #8663)
  • Replace per-node config scans with keyed lookups in configurable rules - method, property, rename, transform, arguments and removing rules (#8734, #8735, #8736, #8739, #8742, #8743, #8744, #8745)
  • Iterate rules to a fixed point with a content-cycle guard instead of a per-node re-processing guard, and enforce single-pass idempotency in tests (#8679, #8719, #8715, #8722)
  • Skip rules whose work depends on a docblock when the node has none (#8624, #8625, #8626, #8627, #8628, #8629, #8630, #8631, #8632)

... (truncated)

Commits
  • 10c9654 Rector 2.8.1
  • 9c52717 Updated Rector to commit 16d43affa9ae7eb56f5968cd80661d2e67d726b5
  • 2efbc12 Updated Rector to commit b256695c176251f1c9b6f9ae1f2690ff83efe08b
  • 8548f15 Rector 2.8.0
  • 2814c93 Updated Rector to commit 27281c6a12d9543776af93761a1fb59a6f2a19c6
  • d3ed939 Updated Rector to commit 70e25dc1079d716633245087f70338ed1d3ffa82
  • 9a73078 Updated Rector to commit 2c5dcce0a1307ffc7dc22617cf743f01d5314e19
  • eda83bd Updated Rector to commit 9e1036753fea86035fd93d5ca627810b3e7a5978
  • e86dc98 Updated Rector to commit 9c32a8d5b186055d1e162abe1d6171355abcff64
  • 457b20c Updated Rector to commit 016d7f2a9b15944c82bfc0f1fb6c1dff13ea22cb
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [rector/rector](https://github.com/rectorphp/rector) from 2.7.0 to 2.8.1.
- [Release notes](https://github.com/rectorphp/rector/releases)
- [Commits](rectorphp/rector@2.7.0...2.8.1)

---
updated-dependencies:
- dependency-name: rector/rector
  dependency-version: 2.8.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added the dependencies Dependency updates (Dependabot) label Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Dependency updates (Dependabot)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants