Cron readiness check should not cause automated updates to not run

Created on 10 March 2025, 26 days ago

Problem/Motivation

I've got cron running every day on some cheap hosting I'm using to build a hobby Drupal CMS site. I don't need cron running more regularly than that and if an automatic update is available I'd like it to run at midnight and not during the day. But the update readiness checks don't allow me to configure it like this because

Your site does not pass some readiness checks for automatic updates. It cannot be automatically updated until further action is performed.
Cron has not run recently. For more information, see the online handbook entry for configuring cron jobs to run at least every 3 hours.

Steps to reproduce

Enable automatic updates and run cron less frequently than 3 hours.

Proposed resolution

This check is too harsh - sure recommend 3 hours and add a warning that this could be implemented but stopping automatic updates in this situation seems wrong.

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Active

Version

4.0

Component

Code

Created by

πŸ‡¬πŸ‡§United Kingdom alexpott πŸ‡ͺπŸ‡ΊπŸŒ

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

Merge Requests

Comments & Activities

  • Issue created by @alexpott
  • Merge request !1102Resolve #3511943 "Cron check" β†’ (Open) created by alexpott
  • πŸ‡¬πŸ‡§United Kingdom alexpott πŸ‡ͺπŸ‡ΊπŸŒ

    So we had

    
      /**
       * The error-level interval between cron runs, in seconds.
       *
       * If cron runs less frequently than this, an error will be raised during
       * validation. Defaults to 24 hours.
       *
       * @var int
       */
      private const ERROR_INTERVAL = 86400;
    
      /**
       * The warning-level interval between cron runs, in seconds.
       *
       * If cron runs less frequently than this, a warning will be raised during
       * validation. Defaults to 3 hours.
       *
       * @var int
       */
      private const WARNING_INTERVAL = 10800;
    

    in the code already. But we are only using the warning interval and issuing an error at that point. I've opened an MR to make the validator behave in the intended way.

  • Pipeline finished with Failed
    26 days ago
    Total: 775s
    #444612
Production build 0.71.5 2024