-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[HttpKernel] New bundle path convention when AbstractBundle
is used
#46385
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
Conversation
What about looking for the |
I'm behind the intentions of this change, but this seems very unrelated to Also from a documentation point of view, this makes things harder to follow: "You can also extend from |
@wouter, I guess you're thinking a new method on the |
Looking at it as a documentation maintainer, I think it actually makes sense to rename And then find a way to make this change backwards compatible in 6.2 for |
@wouterj we are currently promoting the use of the new structure, but it is not mandatory at all, you can use the old structure also with this new The subject is mostly about how to determine the best bundle path when you're using the new/old structure. The old one is not deprecated at this moment, so we cannot deprecate the bundle path either. |
@kbond I've hesitated to do that. Even if it's not recommended you still can create bundles in your app. In that case, there is no composer.json at the bundle level and the algorithm may be lost with the project composer.json. |
Given that there is now an |
@wouterj I don't have any objection to renaming the class for the better. However, it's not the same scenario that |
I didn't know about this goal. If this is the case, I agree that a rename wouldn't make sense.
I must admit that I missed the check for the legacy structure, I'm less -1 know I understand the goal is to make a BC implementation (supporting both old and new structures).
Agreed. So I think it's safe to say that this new class wouldn't be used by a large part of the ecosystem before Symfony 5.4 reaches eom. This means we don't need to rush this change during RC phase, as we probably have time till 6.4 to polish features before a large part of the ecosystem is considering changing to Taking a bit more time here is also good to determine the roadmap for bundles in Symfony 6.x. E.g. if we want to deprecate |
For those cases, you can use the new
No breaks as they are not using the
Changing the
Yes, I expect at some point deprecating |
And then overriding Overall, I've removed my negative vote. I was misunderstanding |
If the extension class is not respecting the location and naming conventions, yes, you'll have to override @wouterj thanks to you for the discussion! |
Thank you @yceruto. |
Addressing this comment symfony/symfony-docs#16801 (comment)
Since Symfony 6.1 when any bundle starts using the new
AbstractBundle
and the bundle is placed in thesrc/
directory we automatically update this path to the parent directory, so we don't have to do it manually to use the modern bundle directory structure.As far as I can see, there is no BC break on this proposal as this is a new class introduced in 6.1 and you have to update your code to make this happen. I will add a note about this subject in the doc too.