Passing generic $value parameter triggers error
>>> [!note] Migrated issue <!-- Drupal.org comment --> <!-- Migrated from issue #3571291. --> Reported by: [zdean](https://www.drupal.org/user/184610) >>> <h3 id="summary-problem-motivation">Problem/Motivation</h3> <p>Error: Unknown named parameter $value in Drupal\Core\Validation\ConstraintFactory-&gt;createInstance() (line 65 of /home/.../public_html/cms/web/core/lib/Drupal/Core/Validation/ConstraintFactory.php).</p> <h4 id="summary-steps-reproduce">Steps to reproduce</h4> <p>When I attempt to create a new content type using an Assistant, I am given this message: "Service error, please try again." Checking the logs shows the error message above</p> <h3 id="summary-proposed-resolution">Proposed resolution</h3> <p>The ConstraintFactory::createInstance() method in Drupal core now uses PHP named parameters. Older code often passed a generic $value parameter to validation constraints (like Regex), which those constraints no longer accept as a named argument. </p> <h3 id="summary-remaining-tasks">Remaining tasks</h3> <h3 id="summary-ui-changes">User interface changes</h3> <h3 id="summary-api-changes">API changes</h3> <h3 id="summary-data-model-changes">Data model changes</h3> > Related issue: [Issue #3565226](https://www.drupal.org/node/3565226)
issue