Drupal coding standard issue

Created on 2 August 2022, over 2 years ago
Updated 10 July 2024, 9 months ago

$ phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml,twig etabs/

FILE: C:\xampp\htdocs\drupal-9\web\modules\contrib\etabs\etabs.module
----------------------------------------------------------------------------------
FOUND 3 ERRORS AFFECTING 2 LINES
----------------------------------------------------------------------------------
1 | ERROR | [x] Missing file doc comment
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
3 | ERROR | [x] Missing function doc comment
----------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal-9\web\modules\contrib\etabs\src\Plugin\Block\EtabsBlock.php
---------------------------------------------------------------------------------------------------
FOUND 10 ERRORS AND 2 WARNINGS AFFECTING 12 LINES
---------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
5 | WARNING | [x] Unused use statement
40 | ERROR | [x] Missing function doc comment
51 | ERROR | [x] Missing function doc comment
86 | ERROR | [x] Functions must not contain multiple empty lines in a row; found 2 empty lines
91 | WARNING | [x] A comma should follow the last multiline array item. Found: )
97 | ERROR | [x] Missing function doc comment
104 | ERROR | [x] Missing function doc comment
108 | ERROR | [x] Missing function doc comment
114 | ERROR | [ ] Missing short description in doc comment
132 | ERROR | [x] There must be exactly one blank line before the tags in a doc comment
153 | ERROR | [ ] Missing short description in doc comment
---------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 10 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal-9\web\modules\contrib\etabs\src\TabData.php
-----------------------------------------------------------------------------------------------------------
FOUND 17 ERRORS AND 1 WARNING AFFECTING 18 LINES
-----------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
12 | ERROR | [ ] Missing short description in doc comment
17 | ERROR | [ ] Missing member variable doc comment
19 | ERROR | [ ] Missing member variable doc comment
21 | ERROR | [ ] Missing member variable doc comment
23 | ERROR | [ ] Missing short description in doc comment
28 | ERROR | [ ] Missing member variable doc comment
30 | ERROR | [ ] Missing member variable doc comment
32 | ERROR | [x] Missing function doc comment
39 | ERROR | [x] Expected 1 blank line after function; 2 found
42 | ERROR | [ ] Missing short description in doc comment
56 | ERROR | [x] Missing function doc comment
60 | ERROR | [x] Missing function doc comment
64 | ERROR | [x] Missing function doc comment
68 | WARNING | [ ] Unused variable $entityType.
75 | ERROR | [x] Missing function doc comment
85 | ERROR | [ ] Inline doc block comments are not allowed; use "/* Comment */" or "// Comment" instead
99 | ERROR | [ ] Missing short description in doc comment
-----------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 7 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal-9\web\modules\contrib\etabs\templates\etabs.css
----------------------------------------------------------------------------------
FOUND 5 ERRORS AFFECTING 2 LINES
----------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
4 | ERROR | [x] Multiple selectors should each be on a single line
4 | ERROR | [x] Opening brace should be the last content on the line
4 | ERROR | [ ] Class definition is empty
4 | ERROR | [x] Closing brace of class definition must be on new line
----------------------------------------------------------------------------------
PHPCBF CAN FIX THE 4 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------

Time: 291ms; Memory: 10MB

🐛 Bug report
Status

Needs work

Version

1.0

Component

Code

Created by

🇮🇳India anoopsingh92 Rajasthan, India

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇮🇳India riddhi.addweb

    It seems like the patch MR1 does not work, it still gives me the phpcs errors:-

    FILE: /var/www/html/web/drupal10/web/modules/contrib/etabs/src/Plugin/Block/EtabsBlock.php
    -----------------------------------------------------------------------------------------------------------------------------
    FOUND 18 ERRORS AFFECTING 18 LINES
    -----------------------------------------------------------------------------------------------------------------------------
    32 | ERROR | [ ] Missing member variable doc comment
    34 | ERROR | [ ] Missing member variable doc comment
    36 | ERROR | [ ] Missing member variable doc comment
    38 | ERROR | [ ] Missing member variable doc comment
    40 | ERROR | [ ] Doc comment is empty
    56 | ERROR | [ ] Doc comment is empty
    86 | ERROR | [x] Doc comment short description must end with a full stop
    91 | ERROR | [x] Doc comment long description must end with a full stop
    102 | ERROR | [ ] Inline doc block comments are not allowed; use "/* Comment */" or "// Comment" instead
    121 | ERROR | [x] Doc comment short description must end with a full stop
    144 | ERROR | [x] Doc comment short description must end with a full stop
    166 | ERROR | [ ] Inline doc block comments are not allowed; use "/* Comment */" or "// Comment" instead
    168 | ERROR | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing parentheses
    204 | ERROR | [x] Missing function doc comment
    211 | ERROR | [ ] Doc comment is empty
    218 | ERROR | [ ] Doc comment is empty
    227 | ERROR | [ ] Missing short description in doc comment
    271 | ERROR | [ ] Missing short description in doc comment
    -----------------------------------------------------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 6 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    -----------------------------------------------------------------------------------------------------------------------------

    FILE: /var/www/html/web/drupal10/web/modules/contrib/etabs/src/TabData.php
    ----------------------------------------------------------------------------
    FOUND 13 ERRORS AND 1 WARNING AFFECTING 14 LINES
    ----------------------------------------------------------------------------
    10 | ERROR | [ ] Missing short description in doc comment
    19 | ERROR | [ ] Missing member variable doc comment
    21 | ERROR | [ ] Missing member variable doc comment
    23 | ERROR | [ ] Missing member variable doc comment
    25 | ERROR | [ ] Missing short description in doc comment
    30 | ERROR | [ ] Missing member variable doc comment
    32 | ERROR | [ ] Missing member variable doc comment
    43 | ERROR | [ ] Missing short description in doc comment
    57 | ERROR | [ ] Doc comment is empty
    64 | ERROR | [x] Missing function doc comment
    68 | ERROR | [x] Missing function doc comment
    72 | ERROR | [ ] Doc comment is empty
    80 | WARNING | [ ] Unused variable $entityType.
    88 | ERROR | [x] Doc comment short description must end with a full stop
    ----------------------------------------------------------------------------
    PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    ----------------------------------------------------------------------------

    FILE: /var/www/html/web/drupal10/web/modules/contrib/etabs/etabs.module
    -----------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    -----------------------------------------------------------------------
    1 | ERROR | [x] Missing file doc comment
    25 | ERROR | [x] Missing function doc comment
    -----------------------------------------------------------------------
    PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    -----------------------------------------------------------------------

Production build 0.71.5 2024