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

DoctrineCommand class extends the deprecated ContainerAwareCommand class #863

Closed
javiereguiluz opened this issue Oct 11, 2018 · 3 comments
Closed

Comments

@javiereguiluz
Copy link
Contributor

Spotted while upgrading the Symfony Demo app to 4.2.x-dev:

The "Doctrine\Bundle\DoctrineBundle\Command\DoctrineCommand" class extends 
"Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand" that is
deprecated since Symfony 4.2, use Command instead.
@Ocramius
Copy link
Member

Ocramius commented Oct 12, 2018 via email

@chalasr
Copy link
Contributor

chalasr commented Oct 28, 2018

The type change is technically BC breaking, but who injects (or perform instanceof checks on) containeraware commands... DoctrineCommand could still provide the getContainer() and setContainer() methods for a time (forever if we don't want to make them to use true DI at some point), even implement ContainerAwareInterface.

I'd assume the BC break here. It has been done for swiftmailer-bundle in symfony/swiftmailer-bundle#262, I can do the PR in case we agree.

@chalasr
Copy link
Contributor

chalasr commented Nov 30, 2018

Fixed in #877

@alcaeus alcaeus closed this as completed Nov 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants