Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): bump rector/rector from 1.0.2 to ^1.2.0 (main) #9479

Merged
merged 1 commit into from
Jul 1, 2024

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Mar 19, 2024

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
rector/rector (source) ^1.0.2 -> ^1.2.0 age adoption passing confidence

Release Notes

rectorphp/rector (rector/rector)

v1.2.0

Compare Source

v1.1.1: Released Rector 1.1.1

Compare Source

[Performance] Fix huge performance hit by reverting children class detection (#​5995) - fixes https://github.com/rectorphp/rector/issues/8679, https://github.com/rectorphp/rector/issues/8638, https://github.com/rectorphp/rector/issues/8637


New Rules

  • [TypeDeclaration] Add ReturnTypeFromReturnCastRector (#​5905)
  • [TypeDeclaration] Add ReturnTypeFromSymfonySerializerRector (#​5908)
  • [TypeDeclaration] Add TypedPropertyFromJMSSerializerAttributeTypeRector (#​5909)
  • [TypeDeclaration] Add AddTypeFromResourceDocblockRector (#​5915)
  • [Php74] Add HebrevcToNl2brHebrevRector (#​5977)
  • [Php74] Add RestoreIncludePathToIniRestoreRector (#​5973)
  • [Carbon] Init set to migrate DateTime to Carbon (#​5868)
  • [Carbon] Add immutable support to other rules (#​5896)
  • Convert DateTimeImmutable to CarbonImmutable (#​5895)
  • Convert time() to Carbon::now()->timestamp (#​5901), Thanks @​kylekatarnls!

New Features and DX improvements 🥳

  • Add code quality levels (#​5910), Thanks @​carlos-granados!
  • [DX] Introduce set providers, to enable package + version based set registration (#​5976)
  • [DX] Report rules that registered in withSkip() but never registered in withRules() (#​5919)
  • [Set] Add new rector-preset set to have opiniated rector rules that can be enabled in rector-src and its extension (#​5924)
  • [DeadCode] Add RemoveUnusedPublicMethodParameterRector (#​5925)
  • [TypeDeclaration] Handle double declare(strict_types=1) addition on DeclareStrictTypesRector + IncreaseDeclareStrictTypesRector (#​5928)
  • [CodingStyle][Php80] Add join func call support on ConsistentImplodeRector (#​5958)
  • [CodeQuality] Add support for (), {}, [], <> delimiter on RegexPatternDetector (#​5957)
  • [TypeDeclaration] Add Static Call support on AddMethodCallBasedStrictParamTypeRector (#​5960)
  • [Config] Add withPhpPolyfill() method to load php polyfill set on RectorConfigBuilder (#​5983)
  • [DX] Add ->withPhpXSets() for PHP 7.4 and lower, improve ->withPreparedSets() (#​5984)
  • [config] Disable parallel on --debug (#​5904)
  • [Php80] Skip mixed doc with description and valid doc on MixedTypeRector (#​5906)
  • [DX] Add withPhpPolyfills() method to add polyfill rules (#​5981) https://github.com/rectorphp/rector-src/pull/5983
  • [DX] Ommit static functions/closure from coding-style, as often ignored and depends on personal preference (#​5916)
  • [DX] Ommit post-inc to pre-inc rule from coding-style as too opinionated (#​5917)
  • [DX] Remove UseIncrementAssignRector from coding-style set, as often ignored (#​5920)

Bugfixes 🐛

  • [AutoImport] No need RenamedClassesDataCollector usage on UsesClassNameImportSkipVoter (#​5921)
  • [Php81] Skip private method from instantiated class on FirstClassCallableRector (#​5929)
  • [NodeTypeCorrector] Directly use StringType on Intersection of strings on AccessoryNonEmptyStringTypeCorrector (#​5933)
  • [CodeQuality] Allow check in current Class_ with multiple props on CompleteDynamicPropertiesRector (#​5938)
  • [Naming] Handle rename property with only comment, without @​var doc on RenamePropertyToMatchTypeRector (#​5945)
  • Remove the renaming of apache_request_headers (#​5943), Thanks @​rhuijts!
  • [Naming] Handle nullable object @​var docblock on RenamePropertyToMatchTypeRector (#​5946)
  • [Php81] Skip param variable used in next stmt after coalesce on NewInInitializerRector (#​5971)
  • [Php71] Skip call abstract method on RemoveExtraParametersRector (#​5930)
  • [TypeDeclaration] Do not remove docblock with description on MergeDateTimePropertyTypeDeclarationRector (#​5931)
  • [DeadCode] Remove param docblock on RemoveUnusedPromotedPropertyRector when exists (#​5936)
  • [Cleanup] Remove deprecated AttributeKey::PARENT_NODE, remove deprecated NodeNameResolver::isCaseSensitiveName() (#​5939)
  • [NodeTypeResolver] Remove Property->type instanceof Node check on NodeTypeResolver->getType() (#​5947)
  • [BetterPhpDocParser] Remove unnecessary PrivatesAccessor usage on BetterTokenIterator and TokenIteratorFactory (#​5950)
  • [DeadCode] Skip dynamic variable on RemoveUnusedVariableAssignRector (#​5964)
  • [DeadCode] Reduce loop for used in next stmt on RemoveUnusedVariableAssignRector (#​5969)

Removed and Deprecated 💀

  • Remove deprecated and empty FinalizeClassesWithoutChildrenRector + FinalizePublicClassConstantRector (#​5980)
  • [DX] Soft-deprecate CallableThisArrayToAnonymousFunctionRector, as FirstClassCallableRector handles the same case better (#​5918)

v1.1.0: Released Rector 1.1.0

Compare Source

New Features 🥳

  • [PHPStan] Bump to PHPStan 1.11 (#​5883)

Bugfixes 🐛

  • [CodeQuality] Skip increment variable on else on TernaryFalseExpressionToIfRector (#​5867)
  • [CodeQuality] Skip on property and class const on CallableThisArrayToAnonymousFunctionRector (#​5869)
  • [NodeTypeResolver] Using built int ->isArray()->yes() on ArrayTypeAnalyzer::isArrayType() (#​5870)
  • Fix "method x was not found in reflection of class" (#​5871), Thanks @​staabm!
  • [NodeTypeResolver] Clean up array check on NameTypeResolver (#​5872)
  • [NodeTypeResolver] Clean up "this" from NameTypeResolver, as not from Name node (#​5873)
  • [TypeDeclaration] Skip array by doc with different assign on ReturnTypeFromStrictNewArrayRector (#​5875)
  • [TypeDeclaration] Skip possible array on StrictStringParamConcatRector (#​5876)
  • [Performance] Ensure call $reflector->reflectAllClasses() once on Worker take 3 (#​5878)
  • [Performance] Call cached class names collection on FamilyRelationsAnalyzer (#​5879)
  • [NodeTypeResolver] Clean up resolve cache class name key (#​5880)
  • [NodeTypeResolver] No need json_decode/json_encode for cache class name collection (#​5881)
  • [TypeDeclaration] Handle crash on interface Mixin on ReturnTypeFromStrictConstantReturnRector (#​5884)
  • [PHPStan] Handle PHPStan internal ShouldNotHappenException on FamilyRelationsAnalyzer and PHPStanNodeScopeResolver (#​5885)
  • [NodeTypeResolver] No need to resolve class name on anonymous classes (#​5886)
  • [PHPStan] Fix missingType.generics notice on phpstan.neon on PHPStan 1.11 (#​5888)
  • [TypeDeclaration] Skip unitialized property on EmptyOnNullableObjectToInstanceOfRector (#​5889)
  • [Php80] Skip remove non-mixed type doc on MixedTypeRector (#​5874)
  • [TypeDeclaration] Add test for nullable object usage on AddReturnTypeDeclarationRector (#​5887)
  • [Configuration] Add missing LevelSetList::UP_TO_PHP_84 on PhpLevelSetResolver::resolveFromPhpVersion() (#​5890)

v1.0.5: Released Rector 1.0.5

Compare Source

New Features 🥳

  • [TypeDeclarations] Add IncreaseDeclareStrictTypesRector to raise level of declare() coverage (#​5849)

Bugfixes 🐛

  • ExplicitReturnNullRector should skip never return (#​5802), Thanks @​staabm!
  • Make Compatible with phpstan 1.11.x code (#​5804)
  • [CodeQuality] Skip Always return in try catch with finally on ExplicitReturnNullRector (#​5807)
  • [CodeQuality] Skip never type on default switch on ExplicitReturnNullRector (#​5808)
  • [CodeQuality] Skip while(true) always returned on ExplicitReturnNullRector (#​5810)
  • [TypeDeclaration] Skip maybe not returned on while on ReturnUnionTypeRector (#​5812)
  • [Php81] Skip on property and class const on FirstClassCallableRector (#​5813)
  • [Php81] Skip __invoke() usage from non-class code on FirstClassCallableRector (#​5816)
  • [Php81] Skip always string if else DomElement on NullToStrictStringFuncCallArgRector (#​5822)
  • [TypeDeclaration] Handle crash on @​mixin usage on ReturnTypeFromStrictTypedCallRector (#​5823)
  • [Php81] Skip mixed type on ArrayDimFetch on NullToStrictStringFuncCallArgRector (#​5826)
  • Fix original quotes in PregReplaceEModifierRector (#​5827)
  • [CodeQuality] Skip $counter variable exists on ForRepeatedCountToOwnVariableRector (#​5828)
  • [Php81] Use PHPStan ParametersAcceptor to detect allowed argument types on NullToStrictStringFuncCallArgRector (#​5829)
  • [Renaming] Skip func call name on RenameClassRector (#​5833)
  • Support NullSafeMethod calls in unused-code analysis (#​5838), Thanks @​staabm!
  • Support NullSafeProperty fetches in unused-code analysis (#​5839), Thanks @​staabm!
  • Ignore phpdoc type in RecastingRemovalRector (#​5841), Thanks @​staabm!
  • [Naming] Skip DateTime as individual in name resolver (#​5842)
  • [Experiment] Rework child classes detection on DynamicSourceLocatorProvider (#​5735)
  • [Printer] Handle Strip left spaces from opening tags on namespaced PHP + HTML content (#​5851)
  • [CodeQuality] Fix tautology transformation on identical check on SimplifyTautologyTernaryRector (#​5854)
  • [CodeQuality] Skip dynamic second arg or has uppercase second arg on SimplifyStrposLowerRector (#​5855)
  • [NodeTypeResolver] Use existing DefaultReflector::reflectAllClasses() method on DynamicSourceLocatorProvider (#​5856)
  • [EarlyReturn] Skip with AssignOp on PreparedValueToEarlyReturnRector (#​5857)
  • [TypeDeclaration] Handle array with index assigned on TypedPropertyFromAssignsRector (#​5861)
  • [TypeDeclaration] Handle return by array shape type on AddArrowFunctionReturnTypeRector (#​5815)
  • [CodeQuality] Add Function_ and FuncCall support on OptionalParametersAfterRequiredRector (#​5835)
  • [Php83] Handle default native constant on AddTypeToConstRector (#​5843)
  • [PHP 7.2] Add error suppres support to each() rule (#​5844)
  • [TypeDeclaration] Skip more detailed type on AddMethodCallBasedStrictParamTypeRector (#​5866)
  • [DeadCode] Skip $this instanceof in Trait on RemoveAlwaysTrueIfConditionRector (#​5817)
  • [DeadCode] Skip $this in trait on RemoveDeadInstanceOfRector (#​5818)

v1.0.4: Released Rector 1.0.4

Compare Source

New Features and Changes 🥳

  • [Php84] Add ExplicitNullableParamTypeRector (#​5724)
  • [Transform] Adds ArrayDimFetchToMethodCallRector rule (#​5723), Thanks @​peterfox!
  • Add support for getOneOrNullResult() method in ChildDoctrineRepositoryClassTypeRector (#​5747)
  • Add boolean and support to RemoveDeadInstanceOfRector (#​5748)
  • [DeadCode] Add new rule - ReduceAlwaysFalseIfOrRector (rectorphp/rector-src@0dd1a43)
  • [CodeQuality] Add new rule - ExplicitReturnNullRector (#​5753)
  • [CodeQuality] Transform type|void docblock to type|null as well on ExplicitReturnNullRector after add return null (rectorphp/rector-src@576198c)
  • [CodeQuality] Add Function_ support on ExplicitReturnNullRector (#​5762)
  • [CodeQuality] Add Goto_ possible return null on SilentVoidResolver under Do_ (#​5773)
  • Add rector test suite to phpunit.xml or phpunit.xml.dist (#​5717), Thanks @​ghostwriter!
  • [Php82] Add VariableInStringInterpolationFixerRector (#​5781)
  • [DeadCode] Add RemoveUselessReadOnlyTagRector (rectorphp/rector-src@ef333de)

Bugfixes 🐛

  • [php84] Clean up contains null check type on ExplicitNullableParamTypeRector (#​5726)
  • Fixes for ArrayDimFetchToMethodCallRector (#​5727), Thanks @​peterfox!
  • Update ArrayDimFetchToMethodCall to use ObjectType (#​5728), Thanks @​peterfox!
  • [Configuration] Do not sets, skip, rules on empty array on RectorConfigBuilder (#​5731)
  • [Php81] Skip $this::class on trait on NullToStrictStringFuncCallArgRector (#​5732)
  • [Dep] Temporary pin to use nikic/php-parser 4.18.0 (#​5733)
  • Handle readonly class with attrs (#​5736), Thanks @​tugmaks!
  • [Scoper] Handle use nette/utils on php < 7.4 on 6th param on preg_replace_callback() (rectorphp/rector-src@fd9e172)
  • [Renaming][AutoImport] Handle after change annotation to attribute with rename on AnnotationToAttributeRector + RenameClassRector with auto import (#​5741)
  • [Php80] Skip var property usage on ClassPropertyAssignToConstructorPromotionRector (#​5744)
  • [Php80] Use identical compare on PromotedPropertyCandidateResolver (#​5745)
  • Fix ChildDoctrineRepositoryClassTypeRector for generic type (#​5746)
  • [DeadCode] Skip From docblock on ReduceAlwaysFalseIfOrRector (rectorphp/rector-src@f32dff3)
  • [CodeQuality] Skip if else return on ExplicitReturnNullRector (#​5755)
  • [CodeQuality] No need to re-update doc when already union null doc on ExplicitReturnNullRector (#​5757)
  • [CodeQuality] Skip __construct() method on ExplicitReturnNullRector (#​5758)
  • [CodeQuality] Move Yield_ and YieldFrom check to SilentVoidResolver (#​5759)
  • [CodeQuality] Skip do { } while always returned on ExplicitReturnNullRector (rectorphp/rector-src@cae0691)
  • [CodeQuality] Allow transform return; to return null; when there is other return with Expr on ExplicitReturnNullRector (#​5761)
  • [AutoImport] Allow auto import same namespace with sub use with docblock short name (rectorphp/rector-src@e3e741e)
  • [CodeQuality] Handle do { } while maybe returned on ExplicitReturnNullRector (#​5766)
  • More fixture on Do_ maybe returned (#​5767)
  • [DeadCode] Fix array callable with constructor args (#​5770), Thanks @​hogejiro!
  • [TypeDeclaration] Ensure always return with Expr on maybe continued in next stmt on SilentVoidResolver (#​5771)
  • [Scope] Fix resolve Scope from fluent call (#​5743)
  • Clean up scope skip scope check on ExprScopeFromStmtNodeVisitor (#​5776)
  • [NodeCollector] Fix non-string value on ArrayCallableMethodMatcher::resolveClassContextType() (#​5780)
  • [Printer] Apply configurable multiline on Fluent Method Call on print after method call created/re-printed (#​5779)
  • [TypeDeclaration] Handle initialized on getter on ReturnTypeFromStrictTypedPropertyRector (#​5784)
  • [TypeDeclaration] Handle in inner function on ReturnTypeFromStrictTernaryRector (#​5785)
  • [TypeDeclaration] Do not use Required::class reference on AutowiredClassMethodOrPropertyAnalyzer (#​5788)
  • [Performance][Php81] Early property promotion and readonly param check before changeable check on ReadOnlyPropertyRector (#​5791)
  • Fix removal of useless @​param tag when string|null insteadof ?string is used. (#​5684), Thanks @​arjenschol
  • [DeadCode] Clean up TypeHasher on Union Type (#​5792)
  • [NodeTypeResolver] Move UnionType doc vs FullyQualified native type as not equal to TypeComparator (#​5793)
  • Support @​immutable phpdoc in RestoreDefaultNullToNullableTypePropertyRector(#​5795), Thanks @​staabm
  • [CodeQuality] Skip Switch_ always returned on ExplicitReturnNullRector (#​5800)
  • [CodeQuality] Handle Switch maybe return on ExplicitReturnNullRector (#​5801)
  • [DeadCode] Skip use docblock on BooleanAnd check on RemoveDeadInstanceOfRector (#​5751)
  • [DeadCode] Skip isset() from property fetch from docblock on RemoveAlwaysTrueIfConditionRector (#​5754)

Removed 💀

  • [code-quality] Remove intval/strval from sets, as no clear difference and personal preference (#​5721)
  • [CodeQuality] Remove BoolvalToTypeCastRector and FloatvalToTypeCastRector as well from code-quality set (#​5722)
  • [CodingStyle] Remove usage of Reflection::expandClassName() from nette/utils 4.0 as cause bug on downgrade (#​5740)
  • [DeadCode] Skip implements interface on RemoveUnusedConstructorParamRector (#​5778)
  • [DeadCode] Skip Array Callable dynamic method using CLASS with constructor (no default args) on RemoveUnusedPrivateMethodRector (#​5774), Thanks @​hogejiro
  • [Php81] Remove @​readonly doc on transformation to native readonly on ReadOnlyPropertyRector (#​5789)
  • [DeadCode] Remove union with interface on RemoveUselessParamTagRector to make it consistent (#​5794)
  • [DeadCode] Skip property fetch on cond as may be overridden on RemoveAlwaysTrueIfConditionRector (#​5796)
  • [DeadCode] Skip @​param true on native bool type on RemoveUselessParamTagRector (#​5798)
  • ArgumentRemoverRectorTest: replace symfony\yaml reference with dummy (#​5799), Thanks @​janedbal!

v1.0.3: Released Rector 1.0.3

Compare Source

New Features and Improvements 🥳

  • [TypeDeclaration] Add ChildDoctrineRepositoryClassTypeRector (#​5695)
  • [TypeDeclaration] No need check parent method when method is private on AddVoidReturnTypeWhereNoReturnRector (#​5690)
  • [Php83] Add support +/- value on constant on AddTypeToConstRector (#​5694)
  • Add dump_node() helper function (#​5696)
  • [CodeQuality] Add Equal and NotEqual support on SimplifyIfReturnBoolRector (#​5697)
  • [CodeQuality] Add support for compare $this::class compare with string on UseIdenticalOverEqualWithSameTypeRector (#​5698)

Bugfixes 🐛

  • [Configuration] Fix parallel config always replaced by next config per-default true (#​5683)
  • [CodingStyle] Skip anonymous class on MakeInheritedMethodVisibilitySameAsParentRector (#​5688)
  • [Php80] Fix typo class name: DoctrineCoverterterAttributeDecorator -> DoctrineConverterAttributeDecorator (#​5689)
  • [Php81] Handle with attribute on ReadOnlyPropertyRector on property promotion (#​5692)
  • [Php72][TypeDeclaration] Fix infinite loop on ParseStrWithResultArgumentRector+DeclareStrictTypesRector (#​5699)
  • [CodeQuality] Skip sort/ksort on TernaryFalseExpressionToIfRector (#​5703)
  • fix: Strip left spaces from opening tags when comparing output for changes (#​5701), Thanks @​stilliard!
  • [CodingStyle] Skip implements interface on MakeInheritedMethodVisibilitySameAsParentRector (#​5707)
  • [CodeQuality] Skip throw after foreach with return in loop on SimplifyForeachToCoalescingRector (#​5714)
  • Skip mixed in ParamTypeByMethodCallTypeRector as not specific (#​5715)
  • [CodeQuality] Skip compare string with stringable object on UseIdenticalOverEqualWithSameTypeRector (#​5718)
  • [Php80] Skip ObjectType on ChangeSwitchToMatchRector (#​5719)

Configuration

📅 Schedule: Branch creation - "before 5am on wednesday" in timezone Europe/Vienna, Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR becomes conflicted, 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 has been generated by Mend Renovate. View repository job log here.

@renovate renovate bot requested a review from ChristophWurst as a code owner March 19, 2024 23:15
@renovate renovate bot enabled auto-merge (squash) March 19, 2024 23:15
@renovate renovate bot force-pushed the renovate/main-rector-rector-1.x branch from 1241b38 to f119691 Compare April 5, 2024 09:13
@renovate renovate bot changed the title chore(deps): bump rector/rector from 1.0.2 to ^1.0.3 (main) chore(deps): bump rector/rector from 1.0.2 to ^1.0.4 (main) Apr 5, 2024
@renovate renovate bot force-pushed the renovate/main-rector-rector-1.x branch from f119691 to f861d7d Compare May 10, 2024 06:04
@renovate renovate bot changed the title chore(deps): bump rector/rector from 1.0.2 to ^1.0.4 (main) chore(deps): bump rector/rector from 1.0.2 to ^1.0.5 (main) May 10, 2024
@renovate renovate bot force-pushed the renovate/main-rector-rector-1.x branch from f861d7d to 5a7b8b4 Compare May 18, 2024 15:03
@renovate renovate bot changed the title chore(deps): bump rector/rector from 1.0.2 to ^1.0.5 (main) chore(deps): bump rector/rector from 1.0.2 to ^1.1.0 (main) May 18, 2024
@renovate renovate bot force-pushed the renovate/main-rector-rector-1.x branch from 5a7b8b4 to 0f90756 Compare June 21, 2024 11:20
@renovate renovate bot changed the title chore(deps): bump rector/rector from 1.0.2 to ^1.1.0 (main) chore(deps): bump rector/rector from 1.0.2 to ^1.1.1 (main) Jun 21, 2024
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
@renovate renovate bot force-pushed the renovate/main-rector-rector-1.x branch from 0f90756 to 896fc6f Compare July 1, 2024 16:03
@renovate renovate bot changed the title chore(deps): bump rector/rector from 1.0.2 to ^1.1.1 (main) chore(deps): bump rector/rector from 1.0.2 to ^1.2.0 (main) Jul 1, 2024
@renovate renovate bot merged commit fefd2a7 into main Jul 1, 2024
36 checks passed
@renovate renovate bot deleted the renovate/main-rector-rector-1.x branch July 1, 2024 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants