$ php -v
PHP 7.3.9 (cli) (built: Aug 27 2019 22:52:39) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.9, Copyright (c) 1998-2018 Zend Technologies
Subject
Symfony 4.4 adds typehints throughout the codebase. The public API should remain backward-compatible. However \Sonata\Form\Validator\Constraints\InlineConstraint overrides the @internal __sleep method and breaks because of the change in signature. The AbstractAdmin attaches this inline constraint for each admin.
Steps to reproduce
Open a random page using \Sonata\Form\Validator\Constraints\InlineConstraint
Expected results
No compile errors
Actual results
Compile Error: Declaration of Sonata\Form\Validator\Constraints\InlineConstraint::__sleep() must be compatible with Symfony\Component\Validator\Constraint::__sleep(): array
Environment
Sonata packages
Symfony packages
PHP version
Subject
Symfony 4.4 adds typehints throughout the codebase. The public API should remain backward-compatible. However
\Sonata\Form\Validator\Constraints\InlineConstraint
overrides the@internal __sleep
method and breaks because of the change in signature. TheAbstractAdmin
attaches this inline constraint for each admin.Steps to reproduce
\Sonata\Form\Validator\Constraints\InlineConstraint
Expected results
No compile errors
Actual results