moodlehq / moodle-cs

Moodle Coding Style

Home Page:https://github.com/moodlehq/moodle-cs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ERROR | Missing member variable doc comment (moodle.Commenting.VariableComment.Missing) reporting on constructor parameters.

gjb2048 opened this issue · comments

In https://github.com/moodlehq/moodle-cs/releases/tag/v3.4.2 the sniff "Add new moodle.Commenting.VariableComment sniff to check that the @var tag and its types are used correctly." was added. This appears to be incorrectly reporting an issue with constructor parameters:

Screenshot 2024-03-31 114122

given the line numbers, you can match against https://github.com/gjbarnard/moodle-theme_foundation/blob/MOODLE_403/classes/admin_setting_configcolourpicker.php#L32-L60 being the code:

Screenshot 2024-03-31 114558

No matter what I do to the documentation comments of the actual member variables, I can't solve this! Do I need to add some sort of reference to the inherited member variables?

If you'd like a core file to test against, then use the lib/adminlib.php file:

Screenshot 2024-03-31 115017

being the code:

Screenshot 2024-03-31 115115

in Moodle 2023100903.11 4.3.3+ (Build: 20240326).

I realise that this is Windows, however, first spotted GitHub actions given moodlehq/moodle-plugin-ci@c3f7ea8#diff-d2ab9925cad7eac58e0ff4cc0d251a937ecf49e4b6bf57f8b95aab76648a9d34R58.

Hi @gjb2048 ,

thanks for the report. I’m closing this as dupe of #142 , where it’s being investigated.

Ciao :-)