8000 [Fix pipeline] multiple_kernels.rst must respect doctor-rst by alamirault · Pull Request #18295 · symfony/symfony-docs · GitHub
[go: up one dir, main page]

Skip to content

[Fix pipeline] multiple_kernels.rst must respect doctor-rst #18295

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

alamirault
Copy link
Contributor
@alamirault alamirault commented May 7, 2023

#18186 (comment)

apps -> applications

ContainerConfigurator $container -> ContainerConfigurator $containerConfigurator

@carsonbot carsonbot added this to the 5.4 milestone May 7, 2023
@alamirault alamirault changed the title multiple_kernels.rst must respect doctor-rst [Fix pipeline] multiple_kernels.rst must respect doctor-rst May 7, 2023
@OskarStark
Copy link
Contributor

Not sure about the directory. I mean maybe we should keep/allow apps here.

I would not change the director structure just to make a tool happy, but if it doesn't matter and it is just an example and no best practice, we can rename it to applications directory

cc @nicolas-grekas @javiereguiluz

@nicolas-grekas
Copy link
Member

👎 on my side, the current names are better to me.

@alamirault
Copy link
Contributor Author

I reverted applications to apps and set violations in whitelist.

For doctor-rst, I think exclude all file is not good because it will hide other violations. I created PR OskarStark/doctor-rst#1395 in order to exclude some rules by file when is needed

@javiereguiluz
Copy link
Member

Antoine, thanks for fixing this and for the updates after the reviewers comments.

javiereguiluz added a commit that referenced this pull request May 9, 2023
…rst (alamirault)

This PR was squashed before being merged into the 5.4 branch.

Discussion
----------

[Fix pipeline] multiple_kernels.rst must respect doctor-rst

#18186 (comment)

`apps` -> `applications`

`ContainerConfigurator $container` -> `ContainerConfigurator $containerConfigurator`

Commits
-------

07f6609 [Fix pipeline] multiple_kernels.rst must respect doctor-rst
@javiereguiluz javiereguiluz force-pushed the hotfix/fix-doctor-rst-violations-multiple-kernel branch from 240ae8d to 07f6609 Compare May 9, 2023 09:11
@javiereguiluz
Copy link
Member

Note: GitHub shows this as closed, but it was merged. See e562839

@nicolas-grekas
Copy link
Member
nicolas-grekas commented May 9, 2023

I wouldn't have merged the change of var name, it's not consistent with the name in the recipe we used at the time:
https://github.com/symfony/recipes/blob/main/symfony/framework-bundle/4.4/src/Kernel.php

nor with the name in the trait we use now:
https://github.com/symfony/symfony/blob/6222f8eaf8498f75fcc018157386d7290a68d0bd/src/Symfony/Bundle/FrameworkBundle/Kernel/MicroKernelTrait.php#L49

and it's longer without adding much.

I'd propose reverting. Sorry...

@alamirault
Copy link
Contributor Author
alamirault commented May 9, 2023

For consistency we standardized the name of the ContainerConfigurator $containerConfigurator #17381 and ContainerBuilder $containerBuilder #17683 in all docs and doctor-rst ensure this naming.

If we revert this name, all doc must also be reverted IMO and not only this part

@javiereguiluz
Copy link
Member

@nicolas-grekas yes, I see that there's a minor inconsistency between the code and the docs about this variable name. We decided to make that change in the past (in the PRs mentioned by @alamirault) to make docs as self-explanatory and clear as possible.

Ideally, we'd like to make the same change in the code ... but we know that for code is not that important and also, changing the name in code is more troublesome than in docs. Thanks.

@nicolas-grekas
Copy link
Member

$containerConfigurator is not the name we recommend in config files either, see eg
https://github.com/symfony/symfony/blob/6.3/src/Symfony/Bundle/FrameworkBundle/Resources/config/console.php

I see no need for consistency between those two examples.

@nicolas-grekas
Copy link
Member

Sorry for the take but I would be fine reverting #17683 also. The previous contributors thoughts $container was an appropriate name, and I still agree with them today, no need for the extra word in the name IMHO.

@symfony symfony deleted a comment from javiereguiluz May 9, 2023
@alamirault alamirault deleted the hotfix/fix-doctor-rst-violations-multiple-kernel branch May 16, 2023 22:38
OskarStark added a commit that referenced this pull request May 19, 2023
This PR was merged into the 5.4 branch.

Discussion
----------

Use "$container" consistently

Takes the other road from #17683 as discussed in #18295

Using `$containerBuilder` and `$containerConfigurator` is unnecessarily long, consuming horizontal space without adding any clarity.

This als
69FA
o aligns the name `$container` with existing practice in the code and in recipes.

Commits
-------

26d021c Use "$container" consistently
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.

5 participants
0