[meta] Remove deprecated classes, methods, procedural functions and code paths outside of deprecated modules on the Drupal 11 branch

Created on 12 July 2022, over 2 years ago
Updated 22 July 2024, 5 months ago

Problem/Motivation

This issue deals with all of the deprecated code to be removed that are outside of deprecated modules: classes, methods, procedural functions and code paths that are not in wholly deprecated modules.

Some of these can just be deleted when 11.x opens, which might even be scriptable.

Proposed resolution

  • Open issues only if you are going to submit a patch for them. (We don't want lots of stub issues with no activity.) Look carefully for duplicates.
  • Tag the issues with "Deprecation removal" and file them against the 11.0.x branch. Deprecation Removal β†’
  • For large APIs, a single issue to remove the whole API is best. While we don't usually recommend scoping issues by module instead of concept β†’ , in this case, the API provided by a module can be considered a single API, especially for smaller modules. Issues can also be grouped by core subsystem namespace (e.g. things in core/lib/Drupal/Core/Foo/).
  • Remove only:
    • The module's own API.
    • Legacy tests of the removed API.

Remaining tasks

User interface changes

None.

API changes

Deprecated APIs will be removed.

Data model changes

None.

🌱 Plan
Status

Needs work

Version

11.0 πŸ”₯

Component
BaseΒ  β†’

Last updated about 2 hours ago

Created by

πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary

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.

  • πŸ‡¬πŸ‡§United Kingdom catch
  • πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary

    Updating title, tags and version number based on recent announcement at https://www.drupal.org/about/core/blog/new-drupal-core-branching-scheme-... β†’

  • πŸ‡³πŸ‡ΏNew Zealand quietone
  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    Didn't realize we this so closed 🌱 [META] Remove deprecated classes, methods, procedural functions and code paths outside of deprecated modules on the Drupal 11 branch Closed: duplicate as a duplicate and moved over all child issues from that meta to here.

  • Status changed to Active 10 months ago
  • πŸ‡³πŸ‡ΏNew Zealand quietone
  • πŸ‡³πŸ‡ΏNew Zealand quietone
  • πŸ‡³πŸ‡ΏNew Zealand quietone
  • πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary

    Great work on getting started with this :) According to my scripts, Feb 29 was the high point and its been going down steeply from there. Quite impressively!

  • πŸ‡«πŸ‡·France andypost

    Related also contains 10.1/10.2 deprecations 🌱 [meta] Remove dead code/unneeded compatibility layers now that PHP 8.1 is required Active

  • πŸ‡«πŸ‡·France andypost

    Filed another one πŸ“Œ Remove deprecated help_topics module Needs review

  • πŸ‡³πŸ‡ΏNew Zealand quietone
  • πŸ‡¬πŸ‡§United Kingdom catch
  • πŸ‡¬πŸ‡§United Kingdom catch

    Opened πŸ“Œ Remove deprecated code from field_ui Fixed .

  • πŸ‡¬πŸ‡§United Kingdom catch
  • πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary

    Even after the core module removals, this 97 mentions of @deprecated against Drupal 11 (and in two cases Drupal 10) remains. I think most bigger ones have issues above, but not all, in case someone wants to chip away at this :) (The list of E_USER_DEPRECATED is much longer, probably lots of these will remove many of that too).

    core/misc/ajax.js:   * @deprecated in drupal:8.6.0 and is removed from drupal:10.0.0.
    core/misc/ajax.js:   * @deprecated in drupal:8.6.0 and is removed from drupal:10.0.0.
    core/tests/Drupal/Tests/RandomGeneratorTrait.php:   * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0.
    core/tests/TestSuites/TestSuiteBase.php: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/tests/TestSuites/KernelTestSuite.php: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/tests/TestSuites/FunctionalJavascriptTestSuite.php: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/tests/TestSuites/BuildTestSuite.php: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/tests/TestSuites/UnitTestSuite.php: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/tests/TestSuites/FunctionalTestSuite.php: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/includes/bootstrap.inc: * @deprecated in drupal:8.3.0 and is removed from drupal:11.0.0.
    core/lib/Drupal/Core/Password/PhpassHashedPassword.php: * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. The
    core/lib/Drupal/Core/Logger/LoggerChannelFactory.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Asset/AssetCollectionOptimizerInterface.php:   * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. There is
    core/lib/Drupal/Core/Test/TestSetupTrait.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/lib/Drupal/Core/Config/ConfigEvents.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Config/TypedConfigManager.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Config/TypedConfigManager.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Config/TypedConfigManager.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Config/TypedConfigManager.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Datetime/Element/Datetime.php:   * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0.
    core/lib/Drupal/Core/Entity/Controller/EntityViewController.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Entity/EntityStorageInterface.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Entity/EntityStorageInterface.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Entity/EntityTypeManager.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0.
    core/lib/Drupal/Core/Render/Element/Ajax.php: * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Return an
    core/lib/Drupal/Core/Render/MetadataBubblingUrlGenerator.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Only string
    core/lib/Drupal/Core/Render/MetadataBubblingUrlGenerator.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Updater/Module.php:   * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Controller/ArgumentResolver/Psr7RequestValueResolver.php:   * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0.
    core/lib/Drupal/Core/Controller/ArgumentResolver/RouteMatchValueResolver.php:   * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0.
    core/lib/Drupal/Core/Url.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/lib/Drupal/Core/Url.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/lib/Drupal/Core/Routing/UrlGenerator.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Only string
    core/lib/Drupal/Core/Routing/UrlGenerator.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Utility/LinkGeneratorInterface.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use
    core/lib/Drupal/Core/Session/PermissionsHashGenerator.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/modules/update/src/Controller/UpdateController.php:   * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use
    core/modules/jsonapi/src/Controller/TemporaryJsonapiFileFieldUploader.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/jsonapi/src/Controller/TemporaryJsonapiFileFieldUploader.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/jsonapi/src/Controller/TemporaryJsonapiFileFieldUploader.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/jsonapi/src/Controller/TemporaryJsonapiFileFieldUploader.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/file.api.php: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use the
    core/modules/file/file.module: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use the
    core/modules/file/file.module: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use the
    core/modules/file/file.module: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use the
    core/modules/file/file.module: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use the
    core/modules/file/file.module: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use the
    core/modules/file/file.module: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use the
    core/modules/file/file.module: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/file.module: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/file.module: *  @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/src/Plugin/rest/resource/FileUploadResource.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/src/Plugin/rest/resource/FileUploadResource.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/src/Plugin/rest/resource/FileUploadResource.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/src/Plugin/rest/resource/FileUploadResource.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/src/Upload/UploadedFileInterface.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/src/Upload/UploadedFileInterface.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/src/Upload/UploadedFileInterface.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/file/src/Upload/FileUploadHandler.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0.
    core/modules/contextual/js/contextual.js:     * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/contextual.js:     * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/contextual.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/toolbar/models/StateModel.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/toolbar/views/AuralView.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/toolbar/views/VisualView.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/models/StateModel.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/contextual.toolbar.js:     * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is
    core/modules/contextual/js/views/KeyboardView.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/views/AuralView.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/views/RegionView.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/contextual/js/views/VisualView.js:   * @deprecated in drupal:9.4.0 and is removed from drupal:11.0.0. There is no
    core/modules/user/user.module: * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/modules/user/user.module: * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/modules/user/user.module: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use
    core/modules/user/user.module: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use
    core/modules/user/src/Form/UserLoginForm.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no replacement.
    core/modules/workspaces/src/Form/WorkspaceFormInterface.php: * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/workspaces/src/WorkspaceManagerInterface.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/workspaces/src/WorkspaceManagerInterface.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/workspaces/src/WorkspaceManagerInterface.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/modules/workspaces/src/WorkspaceAssociationInterface.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use the
    core/modules/field/tests/src/Traits/EntityReferenceTestTrait.php: * @deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use
    core/modules/system/system.install:  // @deprecated The sequences table has been deprecated in drupal:10.2.0 and is
    core/modules/system/tests/modules/deprecation_test/deprecation_test.module: * @deprecated in drupal:8.4.0 and is removed from drupal:9.0.0. This is
    core/modules/migrate/src/Plugin/migrate/id_map/Sql.php:   * @deprecated in drupal:9.5.0 and is removed from drupal:11.0.0. Use
    core/modules/migrate/src/Plugin/MigrationInterface.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/modules/migrate/src/Plugin/MigrationInterface.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/modules/migrate/src/Plugin/MigrationInterface.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/modules/migrate/src/Plugin/Migration.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no
    core/modules/path_alias/src/AliasManager.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use
    core/modules/taxonomy/src/Plugin/views/argument/Taxonomy.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/modules/taxonomy/src/Plugin/views/argument/IndexTidDepth.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. There is no
    core/modules/book/tests/src/Functional/BookTestTrait.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use
    core/modules/ckeditor5/src/Controller/CKEditor5ImageController.php:   * @deprecated in drupal:10.3.0 and is removed from drupal:11.0.0 without replacement.
    core/modules/views/js/ajax_view.js:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0.
    core/modules/views/src/Entity/Render/EntityTranslationRenderTrait.php:   * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Use
    core/modules/views/src/Ajax/ScrollTopCommand.php: * @deprecated in drupal:10.1.0 and is removed from drupal:11.0.0.
  • πŸ‡³πŸ‡ΏNew Zealand quietone

    The 2 in core/misc/ajax.js have an issue to add a deprecation notice, #2973400: Mark functions for wrapping Ajax response as deprecated β†’

  • πŸ‡¬πŸ‡§United Kingdom catch

    Path alias: πŸ“Œ Remove deprecated code from path_alias module Needs review .

  • πŸ‡«πŸ‡·France andypost

    it went down to 50 ATM and views/ui issue should be ready πŸ“Œ Removed deprecated code in views module Needs review

  • πŸ‡«πŸ‡·France andypost

    after file/view clean-up only 29 left

  • πŸ‡«πŸ‡·France andypost

    there's some deprecated found in responsive_image module

    $ git grep deprecate -- core/modules/responsive_image/
    core/modules/responsive_image/src/ResponsiveImageConfigUpdater.php:67:      @trigger_error(sprintf('The responsive image style multiplier re-ordering update for "%s" is deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Profile, module and theme provided Responsive Image configuration should be updated. See https://www.drupal.org/node/3274803', $responsive_image_style->id()), E_USER_DEPRECATED);
    core/modules/responsive_image/src/ResponsiveImageConfigUpdater.php:99:      @trigger_error(sprintf('The responsive image loading attribute update for "%s" is deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. Configuration should be updated. See https://www.drupal.org/node/3279032', $view_display->id()), E_USER_DEPRECATED);
    
  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    Modules appears to be done but still appear to have a few hundred mentions in the lib folder.

  • πŸ‡«πŸ‡·France andypost

    Needs separate issue

    composer/Plugin/Scaffold/Operations/ScaffoldFileCollection.php:157: is deprecated for 10.x \Drupal\Composer\Plugin\Scaffold\Operations\ScaffoldFileCollection::process()

    I bet we can find more starting with git grep deprecated -- core/tests

  • πŸ‡«πŸ‡·France andypost

    There's leftover in

    core/modules/system/config/schema$ ag deprecated
    system.schema.yml
    330:          deprecated: "The 'system.file:path.temporary' config property path is deprecated in drupal:8.8.0 and is removed from drupal 11.0.0. Use settings.php instead. See https://www.drupal.org/node/3039255."
    
  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    Just opened a bunch of tickets to cover deprecations in /lib

    Feel free to assign ones you are working on.

  • Status changed to RTBC 8 months ago
  • πŸ‡¬πŸ‡§United Kingdom catch

    I think we're done?

  • πŸ‡¬πŸ‡§United Kingdom longwave UK

    There's a few stragglers:

    core/scripts/drupal.sh
    16:trigger_error('drupal.sh is deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no replacement. See https://www.drupal.org/node/3241346', E_USER_DEPRECATED);
    
    core/tests/Drupal/FunctionalJavascriptTests/JSWebAssert.php
    105:      @trigger_error(sprintf('%s called unnecessarily in a test is deprecated in drupal:10.2.0 and will throw an exception in drupal:11.0.0. See https://www.drupal.org/node/3401201', __METHOD__), E_USER_DEPRECATED);
    
    core/tests/Drupal/FunctionalJavascriptTests/WebDriverTestBase.php
    146:          @trigger_error('The "chromeOptions" array key is deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Use "goog:chromeOptions instead. See https://www.drupal.org/node/3422624', E_USER_DEPRECATED);
    
    core/tests/Drupal/Tests/BrowserTestBase.php
    457:        @trigger_error('Pushing requests without a session onto the request_stack is deprecated in drupal:10.3.0 and an error will be thrown from drupal:11.0.0. See https://www.drupal.org/node/3337193', E_USER_DEPRECATED);
    
    core/tests/Drupal/Tests/UnitTestCase.php
    72:      @trigger_error('Accessing the randomGenerator property is deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use getRandomGenerator() instead. See https://www.drupal.org/node/3358445', E_USER_DEPRECATED);
    
  • Status changed to Needs work 7 months ago
  • πŸ‡ΊπŸ‡ΈUnited States xjm

    For #32.

  • πŸ‡«πŸ‡·France andypost

    Filed πŸ“Œ Remove core/scripts/drupal.sh Needs review

    remaining deprecation in test-suites according to #3443732-20: Remove deprecated PHPUnit test suites β†’

    This one will be eventually fixed in πŸ“Œ Upgrade PHPUnit to 10, drop Symfony PHPUnit-bridge dependency Fixed

  • πŸ‡«πŸ‡·France andypost

    There's one more deprecation leftover with own issue πŸ› Leftover D10 deprecations in ajax.js Needs work

  • πŸ‡«πŸ‡·France andypost

    updated IS with remaining issues

  • πŸ‡«πŸ‡·France andypost

    All child issues are done, the only remaining is πŸ› Leftover D10 deprecations in ajax.js Needs work

    So probably it could be closed

Production build 0.71.5 2024