Repository navigation
#279 - Mark the classes not meant to be extended @final and the infrastructure classes @internal - #295
Merged
Conversation
…structure classes @internal - @Final since 5.4 (final in v6.0) on the engine (ProcessManager, the registries, ContextualOptionResolver), the models (ProcessState, ProcessHistory, SubprocessInstance, the configurations, the events, the Filesystem files) and the concrete tasks and transformers: extending them triggers a deprecation with the Symfony DebugClassLoader. - Stay open: the abstract classes, interfaces, traits, exceptions and the file tasks extended by other tasks (FileReaderTask, LineReaderTask, FolderBrowserTask, CsvReaderTask, InputCsvReaderTask, CsvResource). - TaskRegistry, not released yet, is final. - @internal on the extension, Configuration, the commands, DataQueueEventListener, PhpFunctionProvider, the Monolog processors, ProcessLogger and TaskLogger. - Good practices: extend the bundle without inheriting its classes. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
njoubert-cleverage
force-pushed
the
279
branch
from
October 15, 2026 12:18
fe6144d to
8c977a4
Compare
4 tasks
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.
Description
v5 step of #279 (Symfony BC promise): define the public API with
@final/@internal, giving one minor version of notice before v6.0 turns@finalintofinal. #279 stays open for the v6 step.Changes
@final since 5.4(107 classes): the engine (ProcessManager,ProcessConfigurationRegistry,TransformerRegistry,ContextualOptionResolver), the models (ProcessState,ProcessHistory,SubprocessInstance,ProcessConfiguration,TaskConfiguration, the events,ConstraintLoader, theFilesystemfiles) and the concrete tasks and transformers. Extending one of them from another package triggers a deprecation with the SymfonyDebugClassLoader(symfony/error-handler, debug mode).AbstractConfigurableTask,AbstractIterableOutputTask,AbstractCsvTask,AbstractCsvResourceTask,Logger\AbstractLogger…), interfaces, traits, exceptions, and the classes actually extended by other classes of the bundle:FileReaderTask,LineReaderTask,FolderBrowserTask,CsvReaderTask,InputCsvReaderTask,Filesystem\CsvResource. The bridge bundles only extendAbstractConfigurableTask(checked in archive, cache, doctrine, flysystem, rest, soap, ui), andProcessStateis only instantiated byProcessManager.TaskRegistry(Fetch tasks from a service locator instead of the service container (v5 step of #114) #275, not released yet) is directlyfinal.@internal(13 classes):CleverAgeProcessExtension,Configuration, the 3 commands,DataQueueEventListener,PhpFunctionProvider, the Monolog processors (AbstractProcessor,ProcessProcessor,TaskProcessor,TransformerProcessor),ProcessLoggerandTaskLogger(only injected inProcessManager). The compiler passes andUnavailable*services already were.@deprecatedclasses (InputAggregatorTask,RegistryCompilerPass,CheckSerializerCompilerPass) are left as is.@final, PHPStan reports two return types that are too wide (ProcessState::getContextualizedOptions(): ?array,PregFilterTransformer::transform(): array|string|null). Narrowing them would break the child classes until they are really final, so they are ignored with a@phpstan-ignore return.unusedTypecomment, to narrow in v6.0.Checks
955 tests, PHPStan, PHP-CS-Fixer, Rector OK.
Requirements
Breaking changes
None:
@final/@internalare annotations. Extending a@finalclass triggers a deprecation; it will be afinalclass in v6.0 (#279).🤖 Generated with Claude Code