Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed issues related to twig/twig 3.15 in tests #455

Merged
merged 4 commits into from
Nov 19, 2024
Merged

Conversation

Steveb-p
Copy link
Contributor

🎫 Issue N/A

Description:

This PR fixes issues related to recent twig/twig 3.15 release, which changes how deprecation information should be passed into Twig Extensions.

To maintain compatibility with earlier Twig versions (most recent PHP 7.4 compatible version of Twig is 3.11) a specific class check is used.

Due to small differences in Twig output, snapshots of results for Twig templating is split between 8.0/7.4 versions where applicable.

For QA:

Documentation:

@Steveb-p Steveb-p requested a review from a team November 19, 2024 10:40
Copy link
Member

@alongosz alongosz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't it be better to have our own base class for extensions then? Not a huge fan of traits, especially the ones used in the object of the same base.

+1, given this is a quick fix for failing CI

@Steveb-p
Copy link
Contributor Author

Wouldn't it be better to have our own base class for extensions then? Not a huge fan of traits, especially the ones used in the object of the same base.

+1, given this is a quick fix for failing CI

I've considered making this an abstract. My argument against is that this is a particular behavior that will be gone with 5.0. By making it a trait, it will be more easily removed. Without touching the extension tree.

Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
4.8% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

@Steveb-p Steveb-p merged commit 2e22ceb into 4.6 Nov 19, 2024
20 of 21 checks passed
@Steveb-p Steveb-p deleted the fix-twig-upstream branch November 19, 2024 13:57
@Steveb-p
Copy link
Contributor Author

Merged up into main in 130a381.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants