-
-
Notifications
You must be signed in to change notification settings - Fork 446
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
Allow Doctrine Annotations 2 #1596
Conversation
Regarding the Psalm failure: psalm/psalm-plugin-symfony#296 |
The stable deps jobs will remain red until Symfony makes another round of bugfix releases, see symfony/symfony#48718 |
Looks like the dependency was added one year ago as a quick fix for the CI: d7afbac I don't think it was reconsidered. It seems to be only used here: DoctrineBundle/DependencyInjection/Compiler/DoctrineOrmMappingsPass.php Lines 131 to 137 in d2088fc
I have no idea what uses that method though; looked in Symfony, couldn't find a reference. |
The quickest fix I could come up with in a PR to another bundle yesterday was to run
It's for apps/bundles that don't register their mapping files in an auto-mapped folder, you're not going to find too many uses of it TBH. |
I would also vote for removing the dep (or move it to req-dev if needed for tests) |
I agree with @nicolas-grekas |
I agree in principle, but if we simply remove it and install it in CI build, we wouldn't test for a case when it's not installed |
2.8.x...mbabker:DoctrineBundle:28.x is pretty ugly but it gets the test suite to run when the annotations package isn't installed (all of the skips are needed because the test fixtures use an annotation based bundle). |
Agree that the dependency on annotations should be removed. |
See #1598 for a full PR |
All right, let's continue there. Thanks for taking over. |
The bundle itself should be compatible with Annotations 2 right away.
However, I wonder if the Annotations package should remain a mandatory dependency. If we use the bundle to configure the DBAL without the ORM, requiring Annotations feels pointless. Moreover, in a PHP 8 project with native attributes, we don't necessarily need Annotations for the ORM either.