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

[full-ci] Adjust symfony deprecated #40521

Merged
merged 4 commits into from
Jan 10, 2023
Merged

Conversation

phil-davis
Copy link
Contributor

@phil-davis phil-davis commented Dec 1, 2022

Description

Some things have been deprecated in Symfony 4 and removed in Symfony 5. The new way of doing each thing is implemented in Symfony 4.4, so we can move to that, and then there will be no code to change again when moving up to Symfony 5. This is what I have found so far:

  1. Symfony\Component\EventDispatcher\Event is now Symfony\Contracts\EventDispatcher\Event

  2. stopPropagation() returns void. Classes that extend that need to have the return type declared.

  3. Symfony\Component\Translation\PluralizationRules is gone in Symfony 5. Symfony\Contracts\Translation\TranslatorTrait has the pluralization rules in function getPluralizationRule

Implement these changes now.

Related Issue

#39630

How Has This Been Tested?

CI

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Database schema changes (next release will require increase of minor version instead of patch)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Technical debt
  • Tests only (no source changes)

Checklist:

  • Code changes
  • Unit tests added
  • Acceptance tests added
  • Documentation ticket raised:
  • Changelog item, see TEMPLATE

@phil-davis phil-davis self-assigned this Dec 1, 2022
@phil-davis phil-davis force-pushed the adjust-symfony-deprecated branch from c2fe5c6 to e10036a Compare December 1, 2022 05:04
@owncloud owncloud deleted a comment from update-docs bot Dec 1, 2022
@phil-davis phil-davis marked this pull request as ready for review December 1, 2022 06:27
@phil-davis phil-davis force-pushed the adjust-symfony-deprecated branch from 2e1d116 to a91ea11 Compare December 28, 2022 07:07
@phil-davis phil-davis requested a review from IljaN December 28, 2022 07:07
@sonarcloud
Copy link

sonarcloud bot commented Jan 6, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

100.0% 100.0% Coverage
0.0% 0.0% Duplication

@phil-davis
Copy link
Contributor Author

@jvillafanez please review. IMO these are simple changes towards possibly going to Symfony5 "some day".

@phil-davis phil-davis merged commit b80392f into master Jan 10, 2023
@delete-merged-branch delete-merged-branch bot deleted the adjust-symfony-deprecated branch January 10, 2023 10:04
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.

2 participants