Doesn't work when you schedule to publish for the second time and prevents node save

Created on 2 March 2024, 9 months ago
Updated 11 August 2024, 3 months ago

Problem/Motivation

When I schedule a content in state unpublished or draft for the first time it publishes fine but if I create a second draft and schedule it to be published again then it fails after the cron, and if I try to edit that page again I cannot save it and I get this error:
The content has either been modified by another user, or you have already submitted modifications. As a result, your changes cannot be saved.

Also, the schedule date and time which I added in the second time keeps showing in the page edit.

Steps to reproduce

  • Create a content with state Unpublished or draft and schedule it to be published after a minute.
  • Run the scheduler cron after a minute manually and it will publish the content.
  • You can also see in revisions tab the revision which has been created by the scheduler.
  • Edit the same content and add a new draft and schedule it to be published after a minutes.
  • After a minute run the scheduler cron manually and cron logs says that the content is published.
  • Check the content and you will see that it's still has a draft revision and the draft revision didn't get published.
  • Try to Edit the content and save it then you will get "The content has either been modified by another user, or you have already submitted modifications. As a result, your changes cannot be saved."
  • In the Scheduling options section you still see the entered schedule date and time and it didn't got cleared like when I ran the cron in the first time.
  • Check the revisions and you will not see a new resvision which has been created by the scheduler.
πŸ› Bug report
Status

Active

Version

3.0

Component

Code

Created by

πŸ‡¨πŸ‡¦Canada mahde Vancouver

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

Comments & Activities

  • Issue created by @mahde
  • πŸ‡¨πŸ‡¦Canada mahde Vancouver

    The problem was that I was saving the draft before the second schedule run without changing anything in the content and after the scheduler cron it's not creating a new revision for the Published version.
    When I updated the node title then the cron is creating the revision for the published.
    I think it should create the revision with "Published" state even if there is no updates in the content.

  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    Fixes will need to be against 3.0.x

Production build 0.71.5 2024