Warning: Undefined array key "title" in Drupal\update\ProjectSecurityRequirement::createFromProjectDataAndSecurityCoverageInfo()

Created on 4 January 2024, 11 months ago
Updated 17 July 2024, 4 months ago

Run update.php for drupal 10.2
Warning: Undefined array key "title" in Drupal\update\ProjectSecurityRequirement::createFromProjectDataAndSecurityCoverageInfo()
I debug and found that

Module annoucements feed (core Drupal 10.2) has no title
core/modules/update/src/ProjectSecurityRequirement.php line 103

if (isset($project_data['existing_version'])) {
      [$major, $minor] = explode('.', $project_data['existing_version']);
      $existing_version = "$major.$minor";
      $next_version = "$major." . ((int) $minor + 1);
      return new static($project_data['title'], $security_coverage_info, $existing_version, $next_version);
    }

🐛 Bug report
Status

Needs work

Version

11.0 🔥

Component
Other 

Last updated about 6 hours ago

Created by

🇫🇷France lazzyvn paris

Live updates comments and jobs are added and updated live.
  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

  • Needs issue summary update

    Issue summaries save everyone time if they are kept up-to-date. See Update issue summary task instructions.

Sign in to follow issues

Comments & Activities

Not all content is available!

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

  • Issue created by @lazzyvn
  • First commit to issue fork.
  • 🇮🇳India samir_shukla bareilly

    Hi, I have created patch for the issue. Please review.

  • Status changed to Needs review 11 months ago
  • Status changed to Needs work 10 months ago
  • 🇺🇸United States smustgrave

    Recommended to use MRs vs patches

    Tagging for issue summary as it should follow the standard issue template.

    Also will need a test case.

  • 🇮🇳India tanmayk Maharashtra

    As @smustgrave suggested, it needs issue summary with steps to reproduce the issue on fresh Drupal 10 install.

    This issue may happen if module, which have hook_requirements implemented, returns an array without title in it. This title is used on Status Report page ($phase == 'runtime').

    Do you have any contributed module installed which may have causing this issue? Or do you have custom modules installed as well? Try checking all entries on Status report page if it shows empty title somewhere. If you find it, please post a screenshot so we can figure out which module is causing this.

    @samir_shukla This should be fixed in respective module as I mentioned above & not in core unless any core module causing this. In any case, that's not correct place to do the change :)

  • 🇳🇱Netherlands ecvandenberg

    This issue has a solution in /project/drupal/issues/3132426 🐛 Notice: Undefined index: title in Drupal\update\ProjectSecurityRequirement Fixed

Production build 0.71.5 2024