Error on adding causes The "0" plugin does not exist

Created on 11 November 2022, about 2 years ago
Updated 20 March 2023, almost 2 years ago

Problem/Motivation

Adding a further validation Contraint causes
Drupal\Component\Plugin\Exception\PluginNotFoundException: The "0" plugin does not exist.

Steps to reproduce

Add more validators. See examples in
[the project Git repository](https://git.drupalcode.org/project/personal_id/tree/8.x-1.x/src/Plugin/V...)

🐛 Bug report
Status

Needs review

Version

2.0

Component

Code

Created by

🇮🇹Italy afagioli Rome

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇮🇹Italy afagioli Rome

    This is happening when submitting personal_id field setting as [ /admin/config/people/accounts/fields/user.user.field_YOUR_COUNTRY_PERSONAL_CODE ]

    One of the field validation constrain option is not set, you submit the form, the "0" plugin_id is added as constrain, breaking the process.

    Attached patch fixes this

  • Status changed to Needs review almost 2 years ago
  • 🇫🇮Finland rpsu

    When this error happens when there are no constraints selected? I wonder if this actually hides a configuration error (PIC field but no validation for it) rather than fixes something.

  • 🇮🇹Italy afagioli Rome

    On my side, on a fresh install, this patch fixes the actual failure.

    Any other review to share here?

Production build 0.71.5 2024