idea-php-symfony2-plugin icon indicating copy to clipboard operation
idea-php-symfony2-plugin copied to clipboard

Symfony: lowercase letters for service and parameter

Open garak opened this issue 7 years ago • 6 comments

Such rule should be deleted or at least adapted to allow keys like env(FOO) Symfony allows uppercase letters when using env vars in parameters since version 3.2

The inspection itself is pointing to correct documentation, but it's not up to date

garak avatar Jul 27 '18 09:07 garak

Also, since Symfony 3.4, A service name must be the same as the fully qualified class name (FQCN) of its class (e.g. App\EventSubscriber\UserSubscriber);, which is clearly using camel case.

scyrma avatar Nov 09 '18 01:11 scyrma

Any news oh this?

garak avatar Aug 05 '19 12:08 garak

Adding to the comment of @scyrma:

For me this happens only triggered when I'm decorating services and inject the decorated service as a constructor argument. As soon there is a .inner appended to the FQCN the rule is triggered.

m-vo avatar Oct 30 '19 08:10 m-vo

I think it will be as simple as removing these 3 files:

https://github.com/Haehnchen/idea-php-symfony2-plugin/blob/2ba11f4d4bd8a702ede291e68a0f66fa991eaa4f/src/test/java/fr/adrienbrault/idea/symfony2plugin/tests/dic/inspection/CaseSensitivityServiceInspectionTest.java

https://github.com/Haehnchen/idea-php-symfony2-plugin/blob/89b9f952d3d909c274201ba49e79d054ce079aff/src/main/java/fr/adrienbrault/idea/symfony2plugin/dic/inspection/CaseSensitivityServiceInspection.java

https://github.com/Haehnchen/idea-php-symfony2-plugin/blob/7b0b16bedf82a2978853de0576070993bc96aa75/src/main/resources/inspectionDescriptions/CaseSensitivityServiceInspection.html

And remove the inspection definition here: https://github.com/Haehnchen/idea-php-symfony2-plugin/blob/7b0b16bedf82a2978853de0576070993bc96aa75/src/main/resources/META-INF/plugin.xml#L314-L317

@garak Can you confirm that all the cases inside https://github.com/Haehnchen/idea-php-symfony2-plugin/blob/2ba11f4d4bd8a702ede291e68a0f66fa991eaa4f/src/test/java/fr/adrienbrault/idea/symfony2plugin/tests/dic/inspection/CaseSensitivityServiceInspectionTest.java are no longer valid for newer versions of Symfony?

ruudk avatar Nov 08 '19 18:11 ruudk

@ruudk I already provided all relevant informations in my first post

garak avatar Nov 08 '19 19:11 garak

Is there a reason why this is not resolved yet? Thanks.

johnnypea avatar Nov 05 '20 22:11 johnnypea