Problem/Motivation

Track the steps needed to deprecate extension Shortcut. See Remove a core extension and move it to a contributed project of the deprecation policy.

The removal of extension Shortcut was approved in #3476880: [Policy] Move Shortcut module to contrib.

All the child issues here, except in the infrastructure project, are "11.5.0 release priority".

Remaining tasks

To find uses

$ git grep -lwi "shortcut" | grep -v core/modules/shortcut/ | grep -v core/assets | grep -v phpstan-baseline | grep -v MAINTAINERS

The issue to remove Shortcut has an MR and can help find what needs to be changed to deprecate Shortcut. #3586214: Remove the Shortcut module

See comments #16 and #17

  1. ✅ andypost and smustgrave are maintainers contrib version of the extension.
  2. ✅ Add the extension to the list of the Upcoming Deprecations.
  3. Move integrations implemented by other modules to the extension.
    Create child issues or child meta issues, as needed, to address the following points. Not all points will apply to all extensions.
  4. Do a thorough search of core for any remaining references to the extension. If references are found, outside of the extension, then create issues to remove the references. git grep -li shortcut | grep -v core/modules/shortcut
  5. Create the contrib project with a stable release, before the alpha version of the major release. Follow the process in Create the contrib project with a stable release for creating the sub tree split.
  6. Deprecate the core extension. #3569118: Deprecate the Shortcut module
  7. ✅ Open an issue, #3569119: Ensure that Shortcut does not get special core treatment
  8. Update the Deprecated and obsolete extensions

Comments

quietone created an issue. See original summary.

quietone’s picture

quietone’s picture

Issue summary: View changes
quietone’s picture

An initial list of tests where shortcut is probably installed.

$ git grep -il "'shortcut'" | grep -v phpstan-baseline | grep -v core/modules/shortcut | grep -v migrate_drupal | grep -v core/assets | grep Test.php
core/modules/block/tests/src/Functional/BlockInstallTest.php
core/modules/config_translation/tests/src/Functional/ConfigTranslationListUiTest.php
core/modules/filter/tests/src/Kernel/EntityLinksTest.php
core/modules/jsonapi/tests/src/Functional/JsonApiFilterRegressionTest.php
core/modules/jsonapi/tests/src/Functional/ShortcutSetTest.php
core/modules/jsonapi/tests/src/Functional/ShortcutTest.php
core/modules/migrate/tests/src/Kernel/Plugin/MigrationPluginListTest.php
core/modules/navigation/tests/src/Functional/NavigationShortcutsBlockTest.php
core/modules/navigation/tests/src/FunctionalJavascript/NavigationBlockUiTest.php
core/modules/system/tests/src/Functional/System/TrustedHostsTest.php
core/modules/system/tests/src/Functional/Theme/ToolbarClaroOverridesTest.php
core/modules/system/tests/src/Functional/UpdateSystem/UpdatePathTestBaseFilledTest.php
core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroBlockFilterTest.php
core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroEntityDisplayTest.php
core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroMenuUiJavascriptTest.php
core/tests/Drupal/FunctionalTests/Core/Recipe/StandardRecipeTest.php
core/tests/Drupal/FunctionalTests/Theme/ClaroTest.php
core/tests/Drupal/KernelTests/Core/Recipe/ConfigActionValidationTest.php
smustgrave’s picture

Love the shortcut module but happy to see what it becomes in contrib. If you need a volunteer I'd be happy if jibran isn't interested.

smustgrave’s picture

I got started on the recipes but got blocked on the standard profile ticket which may be blocked on migrations and test fixtures lol

andypost’s picture

@smustgrave I think you need to take over contrib module first https://www.drupal.org/project/shortcut

smustgrave’s picture

andypost’s picture

I finished test split and looking for reviews in #3569152: Move some test coverage to the Shortcut module

as the contrib name is blcoked probably it's a first time when we need to take new name in contrib ...

andypost’s picture

removed from Standard next is tests split #3569152: Move some test coverage to the Shortcut module

smustgrave’s picture

Andypost and myself have access to the contrib space now!

smustgrave’s picture

@quietone can steps related to migration be removed from the summary?

smustgrave’s picture

With regards to the recipe I created https://www.drupal.org/project/basic_shortcuts_recipe just like we did for the Contact recipe removal.

quietone’s picture

These four tests remain

  • core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroBlockFilterTest.php
  • core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroEntityDisplayTest.php
  • core/tests/Drupal/FunctionalTests/Theme/ClaroTest.php
  • core/themes/admin/tests/src/Functional/AdminTest.php
quietone’s picture

$ git grep "'shortcut'" | grep -v core/modules/shortcut
core/modules/jsonapi/src/Access/TemporaryQueryGuard.php:      case 'shortcut':
core/modules/jsonapi/src/Hook/JsonapiHooks.php:   * Implements hook_jsonapi_ENTITY_TYPE_filter_access() for 'shortcut'.
core/modules/navigation/src/Plugin/Block/NavigationShortcutsBlock.php:    if (!$this->moduleHandler->moduleExists('shortcut')) {
core/modules/system/tests/src/Functional/UpdateSystem/UpdatePathTestBaseFilledTest.php:      'shortcut',
core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroBlockFilterTest.php:  protected static $modules = ['shortcut'];
core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroEntityDisplayTest.php:  protected static $modules = ['shortcut'];
core/tests/Drupal/FunctionalTests/Theme/ClaroTest.php:  protected static $modules = ['dblog', 'shortcut', 'pager_test'];
core/themes/default_admin/tests/src/Functional/AdminTest.php:    'shortcut',
quietone’s picture

Specifically for jsonapi

$ git grep -li shortcut core/modules/jsonapi/
core/modules/jsonapi/src/Access/TemporaryQueryGuard.php
core/modules/jsonapi/src/Hook/JsonapiHooks.php
core/modules/jsonapi/src/Query/Filter.php
core/modules/jsonapi/src/Query/Sort.php
core/modules/jsonapi/tests/src/Functional/WorkflowTest.php
core/modules/jsonapi/tests/src/Unit/Query/SortTest.php
quietone’s picture

Issue summary: View changes

And still more to review and possibly change.

$ git grep -li shortcut | grep -v core/modules/shortcut | grep -v core/assets/vendor | grep -v phpstan-baseline | grep -v core/.deprecation-ignore.txt | grep -v core/modules/json | grep -v core/MAINTAINERS.txt | nl
     1  core/config/schema/core.data_types.schema.yml
     2  core/lib/Drupal/Core/Entity/entity.api.php
     3  core/lib/Drupal/Core/Routing/PathChangedHelper.php
     4  core/lib/Drupal/Core/Routing/UrlGenerator.php
     5  core/lib/Drupal/Core/Theme/Icon/IconDefinitionInterface.php
     6  core/lib/Drupal/Core/Theme/ThemeManager.php
     7  core/modules/big_pipe/tests/modules/big_pipe_test/src/BigPipePlaceholderTestCases.php
     8  core/modules/ckeditor5/src/Hook/Ckeditor5Hooks.php
     9  core/modules/help/help_topics/core.ui_components.html.twig
    10  core/modules/navigation/config/install/navigation.block_layout.yml
    11  core/modules/navigation/src/Hook/NavigationHooks.php
    12  core/modules/navigation/src/NavigationServiceProvider.php
    13  core/modules/navigation/src/Plugin/Block/NavigationShortcutsBlock.php
    14  core/modules/navigation/src/ShortcutLazyBuilder.php
    15  core/modules/navigation/tests/navigation_test/src/Hook/NavigationTestHooks.php
    16  core/modules/navigation/tests/src/Functional/NavigationSafeBlockDefinitionTest.php
    17  core/modules/system/src/Form/ThemeSettingsForm.php
    18  core/modules/system/tests/src/Functional/System/ThemeTest.php
    19  core/modules/system/tests/src/Functional/UpdateSystem/UpdatePathTestBaseFilledTest.php
    20  core/modules/views/src/ManyToOneHelper.php
    21  core/modules/views/src/Plugin/views/HandlerBase.php
    22  core/modules/views/src/Plugin/views/ViewsHandlerInterface.php
    23  core/modules/views/src/Plugin/views/field/EntityField.php
    24  core/modules/views/src/Plugin/views/filter/FilterPluginBase.php
    25  core/modules/views/src/Plugin/views/sort/SortPluginBase.php
    26  core/modules/views/src/ViewExecutable.php
    27  core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroBlockFilterTest.php
    28  core/tests/Drupal/FunctionalJavascriptTests/Theme/ClaroEntityDisplayTest.php
    29  core/tests/Drupal/FunctionalTests/Theme/ClaroTest.php
    30  core/themes/claro/claro.info.yml
    31  core/themes/claro/claro.libraries.yml
    32  core/themes/claro/css/components/shortcut.css
    33  core/themes/claro/css/components/shortcut.pcss.css
    34  core/themes/default_admin/css/components/shortcut.css
    35  core/themes/default_admin/css/components/shortcut.pcss.css
    36  core/themes/default_admin/default_admin.info.yml
    37  core/themes/default_admin/default_admin.libraries.yml
    38  core/themes/default_admin/migration/css/base/gin.css
    39  core/themes/default_admin/migration/css/components/toolbar.css
    40  core/themes/default_admin/migration/css/layout/navigation.css
    41  core/themes/default_admin/migration/js/navigation.js
    42  core/themes/default_admin/migration/js/sidebar.js
    43  core/themes/default_admin/migration/media/sprite.svg
    44  core/themes/default_admin/templates/navigation/menu-region--top.html.twig
    45  core/themes/default_admin/tests/src/Functional/AdminTest.php
    46  core/themes/olivero/config/install/olivero.settings.yml
    47  core/themes/olivero/config/schema/olivero.schema.yml
    48  core/themes/olivero/css/components/page-title.css
    49  core/themes/olivero/css/components/page-title.pcss.css
    50  core/themes/olivero/src/Hook/OliveroHooks.php
    51  core/themes/stable9/css/shortcut/shortcut.icons.theme.css
    52  core/themes/stable9/css/shortcut/shortcut.theme.css
    53  core/themes/stable9/stable9.info.yml
quietone’s picture

Issue summary: View changes
quietone’s picture

Issue summary: View changes
quietone’s picture

Also installed in Claro and Default Admin. Oliver has a reference as well.

quietone’s picture

Issue summary: View changes
smustgrave’s picture

I think for the themes we did something for tour where we checked the theme and then loaded new libraries we added to the module for claro/olivero.

smustgrave’s picture

Okay it was actually the book module we were going to try a theme alter https://www.drupal.org/project/drupal/issues/3410216

But then we just ended up deleting it all the theme book stuff when we deleted the book module in https://www.drupal.org/project/drupal/issues/3423975

Not sure if it’s the same here.

andypost’s picture

quietone’s picture

Issue summary: View changes
quietone’s picture

Issue summary: View changes
quietone’s picture

Issue summary: View changes
Issue tags: +11.5.0 release priority
quietone’s picture

Issue summary: View changes
gábor hojtsy’s picture

I asked Claude about shortcut based on the only existing MR at #3581816: Move uses of Shortcut from Navigation to Shortcut so it uses that as a baseline. Used Sonnet 4.6. Of the findings it presented these seem to be not already covered in sub-issues:

  1. big_pipe/tests/.../BigPipePlaceholderTestCases.php:148 — Uses the shortcut route admin/config/user-interface/shortcut/manage/default/add-link-inline as a test URL. This will break when shortcut is removed and needs a replacement URL.
  2. default_admin CSS comments — Just documentation
gábor hojtsy’s picture

Added #3614946: Remove very tiny mention of shortcut module from Default Admin for default admin, it should be revisited if the styling needs changing or just the comment as proposed in the MR.

gábor hojtsy’s picture

Added #3614948: Remove use of Shortcut from BigPipePlaceholderTestCases for bigpipe which is a bit puzzling. I did not find apparent proof that the test actually enabled shortcut module but it tested with a shortcut module placeholder nonetheless. Reviews welcome :)

gábor hojtsy’s picture

Issue summary: View changes

Adding Bigpipe and Default Admin issue to summary too.

quietone’s picture

Issue summary: View changes

The issue to remove Search has an MR and can help find what needs to be changed to deprecate Search. #3586214: Remove the Shortcut module

quietone’s picture

Issue summary: View changes
quietone’s picture

Issue summary: View changes
quietone’s picture

Might be down to one issue before this can be deprecated.

quietone’s picture

Issue summary: View changes
quietone’s picture

I don't see any other instances of Shortcut to change. Does anyone see any?

@andypost and @smustgrave, I think it is time to make a stable release of the Shortcut contrib module.

quietone’s picture

Status: Active » Fixed

Thanks everyone! Another step to a leaner core!

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

quietone’s picture

Adding that #3569119: Ensure that Shortcut does not get special core treatment is fixed. That project migrated to GitLab and the links are no longer updated with the issue status.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.