Problem/Motivation

Method "Symfony\Component\Validator\Validator\ValidatorInterface::inContext()" will return "ContextualValidatorInterface" as of its next major version. Doing the same in implementation "Drupal\Core\TypedData\Validation\RecursiveValidator" will be required when upgrading.

Method "Symfony\Component\Validator\Validator\ValidatorInterface::startContext()" will return "ContextualValidatorInterface" as of its next major version. Doing the same in implementation "Drupal\Core\TypedData\Validation\RecursiveValidator" will be required when upgrading.

Steps to reproduce

Proposed resolution

Add the "ContextualValidatorInterface" type hint.

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

CommentFileSizeAuthor
#5 3231676-5.patch1.42 KBdaffie
#2 3231676-2.patch1.06 KBdaffie

Comments

daffie created an issue. See original summary.

daffie’s picture

Status: Active » Needs review
StatusFileSize
new1.06 KB

The fix.

catch’s picture

Status: Needs review » Reviewed & tested by the community

No references to RecursiveValidator in contrib so I think this is ready to go.

http://grep.xnddx.ru/search?text=RecursiveValidator&filename=

catch’s picture

Title: [Symfony 6] Add "ContextualValidatorInterface" type hint to Drupal\Core\TypedData\Validation\RecursiveValidator::inContext() » [Symfony 6] Add various type hints to Drupal\Core\TypedData\Validation\RecursiveValidator::inContext()
Status: Reviewed & tested by the community » Needs work

Marked #3231673: [Symfony 6] Add "ContextualValidatorInterface" type hint to Drupal\Core\TypedData\Validation\RecursiveValidator::startContext() as duplicate - let's consolidate these changes, since they conflict a separate patches.

daffie’s picture

Status: Needs work » Needs review
StatusFileSize
new1.42 KB
daffie’s picture

Title: [Symfony 6] Add various type hints to Drupal\Core\TypedData\Validation\RecursiveValidator::inContext() » [Symfony 6] Add various type hints to Drupal\Core\TypedData\Validation\RecursiveValidator::inContext() and ::startContext()
Issue summary: View changes
catch’s picture

Status: Needs review » Reviewed & tested by the community

Back to RTBC, thanks!

larowlan’s picture

Status: Reviewed & tested by the community » Fixed

Committed b800480 and pushed to 9.3.x. Thanks!

  • larowlan committed b800480 on 9.3.x
    Issue #3231676 by daffie: [Symfony 6] Add various type hints to Drupal\...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.