[meta] Add compatibility for the latest major and minor versions of dependencies to Drupal 10

Created on 4 March 2022, over 2 years ago
Updated 19 August 2024, 3 months ago

Problem/Motivation

Before we can update our dependencies in Drupal 11, we need to add forward-compatibility with the new versions in Drupal 10.

Proposed resolution

Add compatibility for upcoming major versions of dependencies to Drupal 10 core minors, including addressing deprecations added in those versions.

  1. PHP

  2. Symfony 7

  3. PHPUnit

  4. Guzzle / PSR-7, PSR-17, and PSR-18

  5. jQuery 4

  6. Other dependencies

    Monitor other dependencies for new major versions and ensure forward-compatibility is added where possible.

🌱 Plan
Status

Fixed

Version

11.0 πŸ”₯

Component
OtherΒ  β†’

Last updated about 1 hour ago

Created by

πŸ‡ΊπŸ‡ΈUnited States xjm

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 States xjm
  • πŸ‡¬πŸ‡§United Kingdom catch
  • πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary

    Updating issue summary with issues already available.

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

    When doing a simple composer install followed up composer outdated a lot of stuff is listed (reorganized based on major/minor/patch):

    % composer install
    % composer outdated
    
    Direct dependencies required in composer.json
    ---------------------------------------------
    
    Major:
    phpunit/phpunit                    9.6.15  10.5.9  The PHP Unit Testing framework.
    symfony/phpunit-bridge             v6.4.1  v7.0.2  Provides utilities for PHPUnit, especially user deprecation notices management
    
    Minor:
    behat/mink                         v1.10.0 v1.11.0 Browser controller/emulator abstraction for PHP
    behat/mink-browserkit-driver       v2.1.0  v2.2.0  Symfony2 BrowserKit driver for Mink framework
    behat/mink-selenium2-driver        v1.6.0  v1.7.0  Selenium2 (WebDriver) driver for Mink framework
    
    Patch:
    mglaman/phpstan-drupal             1.2.4   1.2.6   Drupal extension and rules for PHPStan
    open-telemetry/exporter-otlp       1.0.0   1.0.3   OTLP exporter for OpenTelemetry.
    open-telemetry/sdk                 1.0.1   1.0.7   SDK for OpenTelemetry PHP.
    phpstan/phpstan                    1.10.48 1.10.57 PHPStan - PHP Static Analysis Tool
    symfony/lock                       v6.4.0  v6.4.2  Creates and manages locks, a mechanism to provide exclusive access to a shared resource
    symfony/var-dumper                 v6.4.0  v6.4.2  Provides mechanisms for walking through any arbitrary PHP variable
    
    Transitive dependencies not required in composer.json
    -----------------------------------------------------
    
    Major:
    doctrine/annotations               1.14.3  2.0.1   Docblock Annotations Parser
    doctrine/lexer                     2.1.0   3.0.0   PHP Doctrine Lexer parser library that can be used in Top-Down, Recursive Descent Parsers.
    nikic/php-parser                   v4.18.0 v5.0.0  A PHP parser written in PHP
    phpunit/php-code-coverage          9.2.29  10.1.11 Library that provides collection, processing, and rendering functionality for PHP code coverage informat...
    phpunit/php-file-iterator          3.0.6   4.1.0   FilterIterator implementation that filters files based on a list of suffixes.
    phpunit/php-invoker                3.1.1   4.0.0   Invoke callables with a timeout
    phpunit/php-text-template          2.0.4   3.0.1   Simple template engine.
    phpunit/php-timer                  5.0.3   6.0.0   Utility class for timing
    sebastian/cli-parser               1.0.1   2.0.0   Library for parsing CLI options
    sebastian/code-unit                1.0.8   2.0.0   Collection of value objects that represent the PHP code units
    sebastian/code-unit-reverse-lookup 2.0.3   3.0.0   Looks up which function or method a line of code belongs to
    sebastian/comparator               4.0.8   5.0.1   Provides the functionality to compare PHP values for equality
    sebastian/complexity               2.0.2   3.2.0   Library for calculating the complexity of PHP code units
    sebastian/diff                     4.0.5   5.1.0   Diff implementation
    sebastian/environment              5.1.5   6.0.1   Provides functionality to handle HHVM/PHP environments
    sebastian/exporter                 4.0.5   5.1.1   Provides the functionality to export PHP variables for visualization
    sebastian/global-state             5.0.6   6.0.1   Snapshotting of global state
    sebastian/lines-of-code            1.0.3   2.0.2   Library for counting the lines of code in PHP source code
    sebastian/object-enumerator        4.0.4   5.0.0   Traverses array structures and object graphs to enumerate all referenced objects
    sebastian/object-reflector         2.0.4   3.0.0   Allows reflection of object attributes, including inherited and non-public ones
    sebastian/recursion-context        4.0.5   5.0.0   Provides functionality to recursively process PHP variables
    sebastian/type                     3.2.1   4.0.0   Collection of value objects that represent the types of the PHP type system
    sebastian/version                  3.0.2   4.0.1   Library that helps with managing the version number of Git-hosted PHP projects
    
    Minor:
    composer/ca-bundle                 1.3.7   1.4.0   Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.
    mck89/peast                        v1.15.4 v1.16.0 Peast is PHP library that generates AST for JavaScript code
    open-telemetry/gen-otlp-protobuf   1.0.0   1.1.0   PHP protobuf files for communication with OpenTelemetry OTLP collectors/servers.
    open-telemetry/sem-conv            1.23.1  1.24.0  Semantic conventions for OpenTelemetry PHP.
    phpdocumentor/type-resolver        1.7.3   1.8.0   A PSR-5 based resolver of Class names, Types and Structural Element Names
    phpstan/phpdoc-parser              1.24.4  1.25.0  PHPDoc parser with support for nullable, intersection and generic types
    
    Patch:
    google/protobuf                    v3.25.1 v3.25.2 proto library for PHP
    open-telemetry/api                 1.0.0   1.0.2   API for OpenTelemetry PHP.
    open-telemetry/context             1.0.0   1.0.2   Context implementation for OpenTelemetry PHP.
    php-http/promise                   1.2.1   1.3.0   Promise used for asynchronous HTTP requests
    seld/jsonlint                      1.10.0  1.10.1  JSON Linter
    squizlabs/php_codesniffer          3.8.0   3.8.1   PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of codin...
    symfony/console                    v6.4.1  v6.4.2  Eases the creation of beautiful and testable command line interfaces
    symfony/dependency-injection       v6.4.1  v6.4.2  Allows you to standardize and centralize the way objects are constructed in your application
    symfony/event-dispatcher           v6.4.0  v6.4.2  Provides tools that allow your application components to communicate with each other by dispatching even...
    symfony/http-foundation            v6.4.0  v6.4.2  Defines an object-oriented layer for the HTTP specification
    symfony/http-kernel                v6.4.1  v6.4.2  Provides a structured process for converting a Request into a Response
    symfony/mailer                     v6.4.0  v6.4.2  Helps sending emails
    symfony/process                    v6.4.0  v6.4.2  Executes commands in sub-processes
    symfony/psr-http-message-bridge    v6.4.0  v6.4.2  PSR HTTP message bridge
    symfony/routing                    v6.4.1  v6.4.2  Maps an HTTP request to a set of configuration variables
    symfony/serializer                 v6.4.1  v6.4.2  Handles serializing and deserializing data structures, including object graphs, into array structures or...
    symfony/service-contracts          v3.4.0  v3.4.1  Generic abstractions related to writing services
    symfony/string                     v6.4.0  v6.4.2  Provides an object-oriented API to strings and deals with bytes, UTF-8 code points and grapheme clusters...
    symfony/translation-contracts      v3.4.0  v3.4.1  Generic abstractions related to translation
    symfony/validator                  v6.4.0  v6.4.2  Provides tools to validate values
    symfony/var-exporter               v6.4.1  v6.4.2  Allows exporting any serializable PHP data structure to plain PHP code
    

    When doing a composer update inbetween, only the major versions remain of course:

    % composer install
    % composer update
    % composer outdated
    
    Direct dependencies required in composer.json:
    phpunit/phpunit                    9.6.16 10.5.9  The PHP Unit Testing framework.
    symfony/phpunit-bridge             v6.4.2 v7.0.2  Provides utilities for PHPUnit, especially user deprecation notices management
    
    Transitive dependencies not required in composer.json:
    doctrine/annotations               1.14.3 2.0.1   Docblock Annotations Parser
    doctrine/lexer                     2.1.0  3.0.0   PHP Doctrine Lexer parser library that can be used in Top-Down, Recursive Descent Parsers.
    phpunit/php-code-coverage          9.2.30 10.1.11 Library that provides collection, processing, and rendering functionality for PHP code coverage information.
    phpunit/php-file-iterator          3.0.6  4.1.0   FilterIterator implementation that filters files based on a list of suffixes.
    phpunit/php-invoker                3.1.1  4.0.0   Invoke callables with a timeout
    phpunit/php-text-template          2.0.4  3.0.1   Simple template engine.
    phpunit/php-timer                  5.0.3  6.0.0   Utility class for timing
    sebastian/cli-parser               1.0.1  2.0.0   Library for parsing CLI options
    sebastian/code-unit                1.0.8  2.0.0   Collection of value objects that represent the PHP code units
    sebastian/code-unit-reverse-lookup 2.0.3  3.0.0   Looks up which function or method a line of code belongs to
    sebastian/comparator               4.0.8  5.0.1   Provides the functionality to compare PHP values for equality
    sebastian/complexity               2.0.3  3.2.0   Library for calculating the complexity of PHP code units
    sebastian/diff                     4.0.5  5.1.0   Diff implementation
    sebastian/environment              5.1.5  6.0.1   Provides functionality to handle HHVM/PHP environments
    sebastian/exporter                 4.0.5  5.1.1   Provides the functionality to export PHP variables for visualization
    sebastian/global-state             5.0.6  6.0.1   Snapshotting of global state
    sebastian/lines-of-code            1.0.4  2.0.2   Library for counting the lines of code in PHP source code
    sebastian/object-enumerator        4.0.4  5.0.0   Traverses array structures and object graphs to enumerate all referenced objects
    sebastian/object-reflector         2.0.4  3.0.0   Allows reflection of object attributes, including inherited and non-public ones
    sebastian/recursion-context        4.0.5  5.0.0   Provides functionality to recursively process PHP variables
    sebastian/type                     3.2.1  4.0.0   Collection of value objects that represent the types of the PHP type system
    sebastian/version                  3.0.2  4.0.1   Library that helps with managing the version number of Git-hosted PHP projects

    I spotchecked most of them. Most transitive dependencies are to be resolved in 🌱 [meta] Support PHPUnit 10 in Drupal 11 Active .

    The other direct dependency listed is symfony/phpunit-bridge which does not seem to be specific to phpunit 9 or 10, so theoretically v6 or v7 can work with phpunit 9 or 10 equally. This would probably need its own issue if one does not already exist (I did not find one, so will open one unless I find the existing one sooner).

    Then there is doctrine/annotations which we have πŸ“Œ Update doctrine/annotations to v2 Needs work for. That should transitively update doctrine/lexer as well.

    I think those are all for the backend dependencies.

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

    According to https://github.com/symfony/symfony/issues/49069 symfony/phpunit-bridge wrongly declared compatibility with phpunit 10 before, and now declares a conflict/limits to phpunit 9. It looks like there's been no movement on that issue for a year which is not very encouraging, we might have to push it forwards ourselves or make a replacement.

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

    Adding reference to the bridge issue.

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

    Opened 🌱 [meta] Support PHPUnit 11 in Drupal 10 Postponed for the new major of PHPUnit to be released this week, and adding it in the issue summary as well.

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

    Update jQuery section based on information @catch gathered earlier this month.

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

    jQuery 4 beta is out, update issue summary.

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

    I believe no forward compatibility is required for doctrine/annotations, it's an internal dependency only and our API on top is unchanged; in the unlikely event anyone is using the package directly they will have to make minor changes but I don't think it's worth trying to add a shim anywhere (and the changes are removing code rather than adding it, so we can't do anything in D10 anyway).

  • πŸ‡¬πŸ‡§United Kingdom longwave UK
  • Status changed to Fixed 4 months ago
  • πŸ‡ΊπŸ‡ΈUnited States xjm
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024