- Status changed to Needs work
over 1 year ago 6:56pm 5 September 2023
With translated nodes and revision enabled there are frequent issue with "Invalid transition" validation when changing a node status, even with the main admin account.
Still not sure exactly how to reproduce it with minimal effort but here is a way I reproduced it.
1. enable 2 languages and translation on the page content type
2. create a page as draft in default language
3. translate it in the second language and set it as draft
4. publish the default language page
5. archive the translated version
6. try to publish the translated version.
7. At that point you should get the error "You do not have access to transition from Archived to Published"
Use the same logic as the core content_moderation to load the original entity: https://git.drupalcode.org/project/drupal/-/blob/9.2.x/core/modules/cont...
The module currently already use the getLoadedRevisionId() to get the $original_entity, one missing thing is that just after it needs to check isDefaultTranslation() and do some magic after that.
Needs work
3.0
Code
The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.