[wp-trac] [WordPress Trac] #57271: Cron unschedule / reschedule event errors

WordPress Trac noreply at wordpress.org
Mon Dec 5 23:01:44 UTC 2022


#57271: Cron unschedule / reschedule event errors
----------------------------------------+------------------------------
 Reporter:  domainsupport               |       Owner:  audrasjb
     Type:  defect (bug)                |      Status:  assigned
 Priority:  normal                      |   Milestone:  Awaiting Review
Component:  Cron API                    |     Version:  6.0
 Severity:  normal                      |  Resolution:
 Keywords:  has-patch needs-unit-tests  |     Focuses:
----------------------------------------+------------------------------

Comment (by peterwilsoncc):

 Replying to [comment:4 domainsupport]:
 > What you've explained sounds right ... BUT ... surely if events are
 attempting to unschedule when they don't exist and schedule when they do
 exist then this would suggest that the events are somehow running more
 than once (concurrently perhaps?) and have already unscheduled /
 rescheduled themselves?
 >
 > If not then what else could cause this behaviour? And surely preventing
 the error for this scenario won't actually be resolving the root of the
 issue?

 My first thought was concurrency too, but I can't figure out the best way
 to test that idea.

 The only other possible cause I could think of is if the event is been
 scheduled or unscheduled without plugins checking `wp_next_scheduled()`
 first. I did a quick scan of the plugin repository for the events recorded
 in the support ticket but couldn't see any likely causes initially.

 Were you seeing the error in local or development enviroments?

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/57271#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list