Bug in the validation constraint "No transition exists to move from [EMPTY] to [STATE]."

Created on 6 May 2021, about 3 years ago
Updated 15 November 2023, 7 months ago

Problem/Motivation

I added the workflow to an existing content type with content created for it. Now it's impossible to save the node because there is no state transition from an empty value to a state.

Steps to reproduce

  1. Create a content type and add some content.
  2. Create a new workflow with some states
  3. Add a new workflow field to the content type
  4. Edit an existing node and try to select a state and save
  5. You will get an error like "No transition exists to move from [EMPTY] to [STATE]."

Proposed resolution

The easiest way would be to update the constraint to skip empty field values.

Remaining tasks

Update the code

User interface changes

N/A

API changes

N/A

Data model changes

N/A

πŸ› Bug report
Status

Needs work

Version

2.0

Component

Code

Created by

πŸ‡§πŸ‡ͺBelgium BramDriesen Belgium πŸ‡§πŸ‡ͺ

Live updates comments and jobs are added and updated live.
  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

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.

Production build 0.69.0 2024