In CronUpdateStage if postApply() fails no update email will be sent

Created on 13 June 2023, over 1 year ago
Updated 21 June 2023, over 1 year ago

Problem/Motivation

@omkar.podey noticed this in 🐛 [PP-1] \Drupal\automatic_updates\Validation\StatusCheckRequirements makes admin/reports/status 10x slower! Postponed

In \Drupal\automatic_updates\CronUpdateStage::handlePostApply() we have try catch that surrounds both $this->postApply(); and the sending of the email about the update being a success.

The problem with this is that if there is error in post apply there will be no email sent but your site would have already been updated

This affects DrushUpdateStage too because it does not override this method.

Steps to reproduce

Proposed resolution

Surround $this->postApply(); in its own try catch.

TBD: Should we have variation of the cron_successful if post-apply fails?

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Fixed

Version

3.0

Component

Code

Created by

🇺🇸United States tedbow Ithaca, NY, USA

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

Comments & Activities

Production build 0.71.5 2024