Deprecate hook_hook_info()

Created on 4 April 2014, about 10 years ago
Updated 8 March 2023, over 1 year ago

Objective

  1. #1892574: Remove hook_hook_info_alter() β†’ was removed a long time ago already.

  2. hook_hook_info() only exists for lazy-loading legacy hook implementation code.

  3. hook_hook_info() has architectural problems causing code to not be loaded (see related issues).

  4. ModuleHandler apparently maintains two cache items; one for 'module_implements', and another one just for 'hook_info'.

  5. Object-oriented code can be properly auto-loaded in D8.

Remaining implementations

  1. system_hook_info() (hook_token*())
  2. views_hook_info() (hook_views_*())

Proposed solution

  1. Remove hook_hook_info() + persistent caching from ModuleHandler.

  2. Convert remaining affected hook implementations...

    A) Either move them into .module files.

    B) Or find a simple object-oriented replacement pattern.

πŸ“Œ Task
Status

Active

Version

10.1 ✨

Component
ExtensionΒ  β†’

Last updated 3 days ago

No maintainer
Created by

πŸ‡©πŸ‡ͺGermany sun Karlsruhe

Live updates comments and jobs are added and updated live.
  • API clean-up

    Refactors an existing API or subsystem for consistency, performance, modularization, flexibility, third-party integration, etc. May imply an API change. Frequently used during the Code Slush phase of the release cycle.

  • VDC

    Related to the Views in Drupal Core initiative.

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.

Production build 0.69.0 2024