Problem/Motivation

For Drupal 9

Class 'Twig_Extension' is deprecated
Deprecated: since Twig 2.7, use "Twig\Extension\AbstractExtension" instead

Proposed resolution

Use the new class names.
Note: Do not use this if your twig version is not >= 2.7 until the module drop support for Drupal 8

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

phoang created an issue. See original summary.

balintpekker’s picture

Status: Needs review » Reviewed & tested by the community

RTBC +1 on Twig ^3.1, D10.0.0-beta1, PHP 8.1.9

wim leers’s picture

Priority: Normal » Critical
wim leers’s picture

This is a trivial change, that Drupal core also did >3 years ago in #3041076: Update Drupal 9 to Twig 2.

This was a change in Drupal 9.0.x, so the failures on 9.3 and 9.4 are unrelated — as the pass on 9.2 proves. 👍

wim leers’s picture

Status: Reviewed & tested by the community » Closed (duplicate)
Related issues: +#3287235: Drupal 10 compatibility

Actually, this is being handled over in #3287235: Drupal 10 compatibility