[remove] Drop nette/utils set, deprecate withComposerBased(netteUtils:) argument - #8329
Merged
Conversation
…:) argument The only third-party-library rule in core, delivering a named-argument label on 2 methods of one package. The netteUtils: argument is kept as a no-op with a runtime warning, following the withAttributesSets() precedent.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Drops the nette/utils set and its single rule, and deprecates the
netteUtils:argument ofwithComposerBased().UtilsJsonStaticCallNamedArgRectorwas the only third-party-library rule in rector-src. Symfony, Doctrine and PHPUnit rules all live in their own packages; Nette had an exception with no package behind it. What it delivered:Readability only — the positional form still works on nette/utils 4.0, nothing was being repaired. For that, core carried 4 pieces of public API: the rule,
SetList::NETTE_UTILS_COMPOSER_BASED,config/set/nette-utils/, and awithComposerBased()argument. It was also registered in thenamed-argsset.Anyone who still wants it can register the rule directly.
Scope note: only the
netteUtils:argument is deprecated.withComposerBased()itself is untouched and keeps working fortwig,doctrine,phpunit,symfony,laravelanddrupal— 137 rules across the sibling packages implementComposerPackageConstraintInterfaceand depend on it.The argument stays as a no-op with a runtime warning, following the
withAttributesSets(symfonyRoute:)precedent:Changes:
rules/NetteUtils/+ its tests,config/set/nette-utils/,SetList::NETTE_UTILS_COMPOSER_BASEDconfig/set/named-args.phpOption::DEPRECATED_COMPOSER_BASED_ARGS+DeprecatedRulesReporter::reportDeprecatedComposerBasedArgs(), wired intoProcessCommandNetteClassName::JSONstays, it is still used byAddReturnDocblockForJsonArrayRector.