Use specific subject line in update emails

Created on 21 October 2012, about 12 years ago
Updated 29 May 2024, 6 months ago

Postponing on ๐Ÿ“Œ Add tests of new release emails Fixed

Problem/Motivation

I got an email titled New release(s) available for [my site's title]. However, the email body started with There was a problem checking available updates for Drupal.

Checking further, there were in fact no updates available.

  • If Drupal was unable to confirm the need for updates, the email title should not say "new releases available".
  • If Drupal has security updates pending, the email title should state that it is a security notice.

Steps to reproduce

Proposed resolution

When there is any security update available the subject contains "Security release(s) available for"
When all of the attempts to get release information fail, the subject contains "Failed to get release information for"
In all other cases the subject contains "New release(s) available for". In the case the body may still contain a message about failing to get release information.

Remaining tasks

Review
Commit

User interface changes

API changes

Data model changes

Release notes snippet

๐Ÿ› Bug report
Status

Needs work

Version

11.0 ๐Ÿ”ฅ

Component
Updateย  โ†’

Last updated 2 days ago

  • Maintained by
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States @tedbow
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States @dww
Created by

๐Ÿ‡บ๐Ÿ‡ธUnited States Aren Cambre

Live updates comments and jobs are added and updated live.
  • Needs backport to D7

    After being applied to the 8.x branch, it should be considered for backport to the 7.x branch. Note: This tag should generally remain even after the backport has been written, approved, and committed.

  • Novice

    It would make a good project for someone who is new to the Drupal contribution process. It's preferred over Newbie.

Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • Merge request !7253improve update status email subject โ†’ (Open) created by quietone
  • Status changed to Needs review 8 months ago
  • ๐Ÿ‡ณ๐Ÿ‡ฟNew Zealand quietone

    Converted latest patch to an MR and added tests.

    The test no longer uses exact counts for the calls to the mocked functions because they vary so much now. If exact counts are wanted they would have to be added to the data provider array. That doesn't seem necessary to me for this test.

  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    The test no longer uses exact counts for the calls to the mocked functions because they vary so much now.

    Should a follow up be opened to add back in a different way for performance measuring? Seems like coverage we could be losing.

  • Status changed to RTBC 8 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Ran the tests locally since I can't trigger test-only on the MR

    Failed asserting that two strings are identical.
    Expected :'Site notice for Test site'
    Actual :'New release(s) available for Test site'

    Change there seems fine so going to mark, but still wonder about a follow up.,

  • Status changed to Needs work 8 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States dww

    Hrm, "Site notice for @site_name" seems pretty unhelpful and very easy to ignore.

    I'm in favor of adding "security" to the subject in the case of missing security updates, but the other change here seems like a step backwards, not forwards.

    The original report was a complaint that it shouldn't say "New releases(s) available for @site_name" if there was a problem checking for updates. That could be fixed by checking the reason code (like we're now doing to detect missing security updates) and change the subject if it's an error to fetch.

    Also, if this is really a bug, the title of this issue probably shouldn't be "improve update status email subject". ๐Ÿ˜… If that's the scope of the issue, it should be a task, not a bug. And the new subject should actually be an improvement. ๐Ÿ˜‚

    IMHO, either we should focus on fixing the originally reported bug (that the subject shouldn't say "New release(s) available..." if there's a problem checking for updates), or we should change this to a task and make real improvements.

    Sorry,
    -Derek

  • Status changed to Needs review 7 months ago
  • ๐Ÿ‡ณ๐Ÿ‡ฟNew Zealand quietone

    @dww, thanks for the review.

    I am leaving this as a bug since it is odd to get a message with a subject that releases are available when the body says that there was trouble getting the release information. I have updated the proposed resolution with my idea for handing this.

  • Pipeline finished with Canceled
    7 months ago
    Total: 525s
    #146268
  • Pipeline finished with Success
    7 months ago
    Total: 1004s
    #146272
  • Status changed to Needs work 7 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Couldn't run test-only feature but ran locally shouldn't "contrib, fetch fail" and "core fetch fail" fail also?

  • Status changed to Needs review 7 months ago
  • ๐Ÿ‡ณ๐Ÿ‡ฟNew Zealand quietone

    In this case they should not fail. Prior to this change there were no tests for fetching failures. These test are showing that the existing behavior does not change when there are both updates and fetch failures. That is, the email subject will always announce that new releases are available even if there are fetch failures for another project.

  • Status changed to RTBC 7 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Thanks for following up #quietone. In that case believe this is good.

  • Status changed to Needs work 7 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States xjm

    Thanks @smustgrave for the manual testing and question; @quietone's response helped me understand the logic better.

    I've posted just a few small improvements to grammar on the MR, plus typehinted the rest of the test method. It's on the wobbly line for scope but we're allowed to break test hint signatures at any point, and it helped me understand the data provider structure for reviewing all the new cases. (Plus it will save work down the road.)

    Once those are fixed up I think this is ready.

  • ๐Ÿ‡บ๐Ÿ‡ธUnited States xjm

    Saving issue credits.

  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia pradhumanjainOSL

    pradhumanjain2311 โ†’ made their first commit to this issueโ€™s fork.

  • Status changed to Needs review 7 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States xjm

    Thanks @pradhumanjain2311 for your contributions. The point of suggestions is for the existing contributors to the issue to have a chance to +1 the reviewer's suggested changes. A person who has not otherwise contributed to the issue just clicking buttons to apply the suggestions does not really help move the issue forward. Therefore, I won't be crediting this contribution. In the future, you can receive credit by providing a review of an issue with open questions.

    Marking NR for one of the issue's contributors to review the applied suggestions.

  • Status changed to RTBC 7 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Does appear as suggestions were applied.

  • Status changed to Needs review 7 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States xjm

    @smustgrave, again, I don't need validation that the suggestions were applied -- I can see that from the tooling -- I need validation that they were good suggestions. Thanks! :)

  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Left comments on the threads

    3 agree, 1 I'm 50/50, 1 I made a suggestion.

  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    The 1 suggestion can be done probably directly from gitlab but didn't move to NW @xjm agree on it?

  • Status changed to Needs work 6 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Moving to NW for the 1 suggestion, which seems like a good task. Also could use a rebase being 300+ commits behind.

Production build 0.71.5 2024