[Policy, no patch] How to deprecate access checks?

Created on 22 March 2019, over 5 years ago
Updated 7 April 2024, 8 months ago

Problem/Motivation

Per #2914486-119: Add granular permissions to the Layout Builder :

  1. +++ b/core/modules/layout_builder/src/Access/LayoutSectionAccessCheck.php
    @@ -27,6 +27,7 @@ class LayoutSectionAccessCheck implements AccessInterface {
    +    @trigger_error(__NAMESPACE__ . '\LayoutSectionAccessCheck is deprecated in Drupal 8.7.x and will be removed before Drupal 9.0.0. Use \Drupal\layout_builder\Access\LayoutBuilderAccessCheck instead. See https://www.drupal.org/node/3039551.', E_USER_DEPRECATED);
    

    This should say "deprecated in 8.7.0" (not 8.7.x).

    @todo Followup issue to talk about deprecations of access checks (and as compared to tagged services generally).

All known cases in Drupal core:

  1. \Drupal\layout_builder\Access\LayoutSectionAccessCheck #2914486: Add granular permissions to the Layout Builder
  2. \Drupal\Core\Access\CsrfRequestHeaderAccessCheck #2753681: Move CSRF header token out of REST module so that user module can use it, as well as any contrib module
  3. \Drupal\quickedit\Access\EditEntityFieldAccessCheck #2267621: Deprecate and rename EditEntityFieldAccessCheck now that the module is named Quick Edit
  4. \Drupal\workflows\WorkflowDeleteAccessCheck #2896726: Expand the entity access model for workflow states and transitions.

Proposed resolution

TBD

Remaining tasks

Determine if changes are needed on Drupal deprecation policy . If so, make them. Otherwise close this.

User interface changes

API changes

Data model changes

Release notes snippet

🌱 Plan
Status

Closed: outdated

Version

11.0 🔥

Component
Base 

Last updated about 1 hour ago

Created by

🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

Live updates comments and jobs are added and updated live.
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.71.5 2024