Migrated from Workbench -> different revision is shown in /admin/content and /node/123/edit (!)

Created on 13 July 2022, over 2 years ago
Updated 28 July 2024, 5 months ago

Problem/Motivation

After removing workbench moderation from my project and activating content moderation nearly everything works as expected. Only one thing is a problem. I have some nodes showing the wrong data in the edit form in /node/123/edit.

To make things clear, I'll first describe what I think the database tables mean:

  • node -> contains the given node record and in vid the revision taken
  • node_field_data -> contains the current revision
  • node_revision -> contains all revisions of a given node
  • node_field_revision -> contains all revisions of a given node plus field data

Now I have the following strange situation which cause can only be the content moderation since that's the only thing I changed.

db table "node":

db table "node_field_data":

db table "node_field_revision":

db table "node_revision":

Now the problem is that, even if the current revision is 37248 (as specified in db table node -> vid) and the latest revision (highest ID) is published, in the edit form in /node/123/edit the form loads the revision 37242. I found out that, if I change the field node_revision.revision_default from 0 to 1, it works as expected. But changing such things manually might not be a good idea I guess.

I suspect that content moderation "thinks" that there's a non-default revision to load. But in fact there *is* no revision which is more recent than 37248, so why does it load 37242?

If that's important: I also migrated the moderation states into the content_moderation_state revision tables but the situation doesn't differ if I do that migration or not. The problem seems to be located in content moderation.

Maybe anyone can point me into the right direction.

BIG thanks in advance!

Bye Defcon0

💬 Support request
Status

Closed: outdated

Version

11.0 🔥

Component
Content moderation 

Last updated 24 days ago

Created by

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.

Production build 0.71.5 2024