Score:3

Custom module name conflicts with unsupported contrib module -- how to avoid "This project is no longer supported" warning?

pl flag

This Drupal 9 site runs a fork of the search_file_attachments module, modified for custom purposes, and for Drupal 9 compatibility.

For some time now, the Available updates report has shown, for this module, the warning "Project not supported: This project is no longer supported, and is no longer available for download. Disabling everything included by this project is strongly recommended!"

I intend to keep running this module as I might any other custom module, and would like Drupal to stop warning about this, on the rationale that this is no longer a contributed module in need of update status monitoring.

I've tried removing the d.o packaging info:

diff --git a/search_api_attachments.info.yml b/search_api_attachments.info.yml
index 2b2d3cf..adec8e7 100644
--- a/search_api_attachments.info.yml
+++ b/search_api_attachments.info.yml
@@ -3,12 +3,7 @@ name: 'Search API Attachments - Custom Fork'
 description: 'Extract and index file fields content.'
 core: 8.x
 core_version_requirement: ^8 || ^9
-package: Search
 configure: search_api_attachments.admin_form
 dependencies:
   - search_api:search_api
 
-# Information added by Drupal.org packaging script on 2020-04-04
-version: '8.x-1.0-beta16-custom-1'
-project: 'search_api_attachments'
-datestamp: 1586010934

I've also tried removing the composer.json file.

Both of these were followed by drush cr and then manually checking for updates with the "Check manually" link on the Available updates report, but the warning persists.

Question: Other than renaming the module (which I assume would solve the problem but is work I'd like to avoid), can I somehow instruct Drupal to stop checking for updates on this module?

leymannx avatar
ne flag
You can also ask for co-maintainership and if the current maintainer isn't responding you can ask to take over the project. Would actually be better to get the D8+ version out instead of keeping it custom IMHO.
Score:3
so flag

The updates are checked via the core update module. The update.manager service allows a way to alter the list of projects it checks the data from via hook_update_projects_alter. Technically the following should work:

function MODULENAME_update_projects_alter(&$projects) {
  // Hide the forked module from the list.
  unset($projects['search_api_attachments']);
}

Please make sure you replace the MODULENAME with the actual module name where you are implementing this hook.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.