Drupal best practices

Created on 26 December 2017, almost 7 years ago
Updated 10 April 2023, over 1 year ago

Hey,

I checked the Drupal best practices and found the following issues :

 phpcs --standard=DrupalPractice --extensions=php,module,inc,install,test,profile,theme,info,txt,md .

FILE: /home/vagrant/Code/d8/modules/contrib/pathauto/pathauto.module
----------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------
 33 | WARNING | Global constants should not be used, move it to a
    |         | class or interface
----------------------------------------------------------------------


FILE: ...me/vagrant/Code/d8/modules/contrib/pathauto/src/AliasCleaner.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 32 WARNINGS AFFECTING 32 LINES
----------------------------------------------------------------------
 289 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 290 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 291 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 292 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 293 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 294 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 295 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 296 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 297 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 298 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 299 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 300 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 301 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 302 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 303 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 304 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 305 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 306 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 307 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 308 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 309 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 310 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 311 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 312 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 313 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 314 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 315 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 316 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 317 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 318 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 319 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
 320 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
----------------------------------------------------------------------


FILE: ...ode/d8/modules/contrib/pathauto/src/Form/PathautoAdminDelete.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 3 WARNINGS AFFECTING 3 LINES
----------------------------------------------------------------------
  59 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 135 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 139 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
----------------------------------------------------------------------


FILE: ...de/d8/modules/contrib/pathauto/src/Form/PathautoSettingsForm.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 6 WARNINGS AFFECTING 6 LINES
----------------------------------------------------------------------
  91 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 130 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 133 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 160 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 209 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 244 | WARNING | Unused variable $original_entity_types.
----------------------------------------------------------------------


FILE: ...nt/Code/d8/modules/contrib/pathauto/src/Form/PatternEditForm.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
----------------------------------------------------------------------
 132 | WARNING | Unused variable $condition_id.
 249 | WARNING | t() calls should be avoided in classes, use
     |         | dependency injection and $this->t() instead
----------------------------------------------------------------------


FILE: ...grant/Code/d8/modules/contrib/pathauto/src/PathautoGenerator.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 3 WARNINGS AFFECTING 3 LINES
----------------------------------------------------------------------
 253 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 254 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
 260 | WARNING | \Drupal calls should be avoided in classes, use
     |         | dependency injection instead
----------------------------------------------------------------------


FILE: ...d8/modules/contrib/pathauto/src/Tests/PathautoMassDeleteTest.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------
 174 | WARNING | Unused variable $id.
----------------------------------------------------------------------


FILE: ...8/modules/contrib/pathauto/src/Tests/PathautoTaxonomyWebTest.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------
 57 | WARNING | Unused variable $vocabulary.
----------------------------------------------------------------------


FILE: ...modules/pathauto_string_id_test/pathauto_string_id_test.info.yml
----------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------
 7 | WARNING | All dependencies must be prefixed with the project
   |         | name, for example "drupal:"
----------------------------------------------------------------------


FILE: ...o/tests/modules/pathauto_views_test/pathauto_views_test.info.yml
----------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------
 8 | WARNING | All dependencies must be prefixed with the project
   |         | name, for example "drupal:"
----------------------------------------------------------------------


FILE: ...modules/contrib/pathauto/tests/src/Kernel/PathautoKernelTest.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
----------------------------------------------------------------------
 367 | WARNING | There must be no blank line following an inline
     |         | comment
 406 | WARNING | Unused variable $vocab.
----------------------------------------------------------------------


FILE: .../modules/contrib/pathauto/tests/src/Kernel/PathautoTokenTest.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------
 54 | WARNING | Variable $values is undefined.
----------------------------------------------------------------------


FILE: ...dules/contrib/views_bulk_operations/src/Form/ConfigureAction.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------
 88 | WARNING | Unused variable $selection.
----------------------------------------------------------------------

Time: 2.5 secs; Memory: 26Mb

I'll try to fixed them and upload a patch for these issues.

📌 Task
Status

Needs work

Version

1.0

Component

Code

Created by

🇲🇦Morocco teeyo

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.

  • Issue was unassigned.
  • Status changed to Needs review over 1 year ago
  • 🇮🇳India Akshay kashyap

    Thanks for the work @RohitRawat676
    Applied Patch cleanly 39
    But few error showing when i run vendor/bin/phpcs --standard=Drupal,DrupalPractice modules/pathauto command so please fix all these coding standard issues.

    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/FunctionalJavascript/PathautoLocaleTest.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 6 ERRORS AFFECTING 6 LINES
    ---------------------------------------------------------------------------------------------------------------------------------------
      31 | ERROR | The array declaration extends to column 83 (the limit is 80). The array content should be split up over multiple lines
      45 | ERROR | Doc comment short description must be on a single line, further text should be a separate paragraph
      64 | ERROR | The array declaration extends to column 102 (the limit is 80). The array content should be split up over multiple lines
      82 | ERROR | The array declaration extends to column 97 (the limit is 80). The array content should be split up over multiple lines
      86 | ERROR | The array declaration extends to column 120 (the limit is 80). The array content should be split up over multiple lines
     203 | ERROR | The array declaration extends to column 133 (the limit is 80). The array content should be split up over multiple lines
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/FunctionalJavascript/PathautoUiTest.php
    ----------------------------------------------------------------------------------------------------
    FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
    ----------------------------------------------------------------------------------------------------
      60 | ERROR   | Doc comment is empty
      73 | ERROR   | Doc comment is empty
     111 | WARNING | Line exceeds 80 characters; contains 97 characters
    ----------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Functional/PathautoTestHelperTrait.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 17 ERRORS AFFECTING 17 LINES
    ---------------------------------------------------------------------------------------------------------------------------------------
      73 | ERROR | Doc comment is empty
      80 | ERROR | The array declaration extends to column 223 (the limit is 80). The array content should be split up over multiple lines
      83 | ERROR | Doc comment is empty
      94 | ERROR | Doc comment is empty
     105 | ERROR | Doc comment is empty
     112 | ERROR | Doc comment is empty
     123 | ERROR | Doc comment is empty
     134 | ERROR | Doc comment is empty
     147 | ERROR | Doc comment is empty
     156 | ERROR | Doc comment is empty
     164 | ERROR | Doc comment is empty
     172 | ERROR | Missing short description in doc comment
     173 | ERROR | Missing parameter comment
     175 | ERROR | Description for the @return value is missing
     189 | ERROR | Doc comment is empty
     203 | ERROR | Doc comment is empty
     218 | ERROR | Doc comment is empty
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Functional/PathautoNodeWebTest.php
    -----------------------------------------------------------------------------------------------------------------------------------------
    FOUND 4 ERRORS AND 2 WARNINGS AFFECTING 6 LINES
    -----------------------------------------------------------------------------------------------------------------------------------------
      30 | ERROR   | The array declaration extends to column 94 (the limit is 80). The array content should be split up over multiple lines
     182 | ERROR   | Missing short description in doc comment
     187 | ERROR   | The array declaration extends to column 89 (the limit is 80). The array content should be split up over multiple lines
     208 | WARNING | Line exceeds 80 characters; contains 92 characters
     225 | WARNING | Line exceeds 80 characters; contains 81 characters
     290 | ERROR   | The array declaration extends to column 125 (the limit is 80). The array content should be split up over multiple lines
    -----------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Functional/PathautoEnablingEntityTypesTest.php
    ------------------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    ------------------------------------------------------------------------------------------------------------------
     61 | ERROR | Doc comment short description must be on a single line, further text should be a separate paragraph
    ------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Functional/PathautoSettingsFormWebTest.php
    -------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    -------------------------------------------------------------------------------------------------------
     222 | ERROR | Type hint "array" missing for $settings
    -------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Functional/PathautoMassDeleteTest.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 4 ERRORS AFFECTING 3 LINES
    ---------------------------------------------------------------------------------------------------------------------------------------
     100 | ERROR | The array declaration extends to column 150 (the limit is 80). The array content should be split up over multiple lines
     163 | ERROR | The array declaration extends to column 111 (the limit is 80). The array content should be split up over multiple lines
     163 | ERROR | The array declaration extends to column 110 (the limit is 80). The array content should be split up over multiple lines
     194 | ERROR | The array declaration extends to column 98 (the limit is 80). The array content should be split up over multiple lines
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Functional/PathautoBulkUpdateTest.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 3 ERRORS AFFECTING 2 LINES
    ---------------------------------------------------------------------------------------------------------------------------------------
      73 | ERROR | Doc comment is empty
     108 | ERROR | The array declaration extends to column 102 (the limit is 80). The array content should be split up over multiple lines
     108 | ERROR | The array declaration extends to column 101 (the limit is 80). The array content should be split up over multiple lines
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Kernel/PathautoTokenTest.php
    -----------------------------------------------------------------------------------------------------------------------------------------
    FOUND 6 ERRORS AND 1 WARNING AFFECTING 7 LINES
    -----------------------------------------------------------------------------------------------------------------------------------------
      23 | ERROR   | Doc comment is empty
      41 | WARNING | Line exceeds 80 characters; contains 81 characters
      95 | ERROR   | The array declaration extends to column 156 (the limit is 80). The array content should be split up over multiple lines
      98 | ERROR   | The array declaration extends to column 125 (the limit is 80). The array content should be split up over multiple lines
     101 | ERROR   | The array declaration extends to column 298 (the limit is 80). The array content should be split up over multiple lines
     104 | ERROR   | The array declaration extends to column 251 (the limit is 80). The array content should be split up over multiple lines
     111 | ERROR   | Doc comment is empty
    -----------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Kernel/PathautoEntityWithStringIdTest.php
    ------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    ------------------------------------------------------------------------------------------------------
     78 | ERROR | Parameter tags must be defined first in a doc comment
    ------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/tests/src/Kernel/PathautoKernelTest.php
    -----------------------------------------------------------------------------------------------------------------------------------------
    FOUND 21 ERRORS AND 2 WARNINGS AFFECTING 22 LINES
    -----------------------------------------------------------------------------------------------------------------------------------------
      31 | ERROR   | Missing member variable doc comment
      31 | ERROR   | The array declaration extends to column 186 (the limit is 80). The array content should be split up over multiple lines
      33 | ERROR   | Missing member variable doc comment
      35 | ERROR   | Missing short description in doc comment
      40 | ERROR   | Missing short description in doc comment
      45 | ERROR   | Doc comment is empty
     280 | WARNING | Line exceeds 80 characters; contains 102 characters
     307 | ERROR   | The array declaration extends to column 116 (the limit is 80). The array content should be split up over multiple lines
     316 | ERROR   | The array declaration extends to column 130 (the limit is 80). The array content should be split up over multiple lines
     340 | ERROR   | Doc comment short description must be on a single line, further text should be a separate paragraph
     357 | WARNING | Line exceeds 80 characters; contains 83 characters
     367 | ERROR   | The array declaration extends to column 86 (the limit is 80). The array content should be split up over multiple lines
     386 | ERROR   | The array declaration extends to column 130 (the limit is 80). The array content should be split up over multiple lines
     388 | ERROR   | The array declaration extends to column 88 (the limit is 80). The array content should be split up over multiple lines
     400 | ERROR   | The array declaration extends to column 124 (the limit is 80). The array content should be split up over multiple lines
     404 | ERROR   | The array declaration extends to column 144 (the limit is 80). The array content should be split up over multiple lines
     426 | ERROR   | Doc comment is empty
     463 | ERROR   | The array declaration extends to column 92 (the limit is 80). The array content should be split up over multiple lines
     471 | ERROR   | The array declaration extends to column 94 (the limit is 80). The array content should be split up over multiple lines
     476 | ERROR   | The array declaration extends to column 95 (the limit is 80). The array content should be split up over multiple lines
     497 | ERROR   | The array declaration extends to column 110 (the limit is 80). The array content should be split up over multiple lines
     498 | ERROR   | The array declaration extends to column 110 (the limit is 80). The array content should be split up over multiple lines
     562 | ERROR   | The array declaration extends to column 86 (the limit is 80). The array content should be split up over multiple lines
    -----------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/Entity/PathautoPattern.php
    ---------------------------------------------------------------------------------
    FOUND 3 ERRORS AFFECTING 3 LINES
    ---------------------------------------------------------------------------------
     100 | ERROR | Missing short description in doc comment
     126 | ERROR | Missing short description in doc comment
     131 | ERROR | Missing short description in doc comment
    ---------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/PathautoWidget.php
    -------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    -------------------------------------------------------------------------
     35 | WARNING | Line exceeds 80 characters; contains 144 characters
    -------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/EventSubscriber/PathautoSettingsCacheTag.php
    ---------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    ---------------------------------------------------------------------------------------------------
     16 | ERROR | Missing short description in doc comment
    ---------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/Plugin/Deriver/EntityAliasTypeDeriver.php
    ------------------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    ------------------------------------------------------------------------------------------------
     23 | ERROR | Missing short description in doc comment
     35 | ERROR | Missing short description in doc comment
    ------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/Plugin/pathauto/AliasType/EntityAliasTypeBase.php
    -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    FOUND 3 ERRORS AFFECTING 2 LINES
    -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
     193 | ERROR | The array declaration extends to column 126 (the limit is 80). The array content should be split up over multiple lines
     297 | ERROR | The text '@deprecated Use \Drupal\pathauto\PathautoState::bulkDelete() instead.' does not match the standard format: @deprecated in %deprecation-version% and is removed from %removal-version%.
         |       | %extra-info%.
     297 | ERROR | Each @deprecated tag must have a @see tag immediately following it
    -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/Plugin/migrate/source/PathautoPattern.php
    --------------------------------------------------------------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    --------------------------------------------------------------------------------------------------------------------------------------------
      98 | ERROR | unserialize() is insecure unless allowed classes are limited. Use a safe format like JSON or use the allowed_classes option.
     117 | ERROR | unserialize() is insecure unless allowed classes are limited. Use a safe format like JSON or use the allowed_classes option.
    --------------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/AliasUniquifierInterface.php
    -----------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    -----------------------------------------------------------------------------------
     13 | WARNING | Line exceeds 80 characters; contains 81 characters
    -----------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/AliasTypeBatchUpdateInterface.php
    ----------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    ----------------------------------------------------------------------------------------
     22 | ERROR | Type hint "array" missing for $context
     30 | ERROR | Type hint "array" missing for $context
    ----------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/VerboseMessenger.php
    -------------------------------------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    -------------------------------------------------------------------------------------------------------------------------------------
     68 | ERROR | The array declaration extends to column 82 (the limit is 80). The array content should be split up over multiple lines
    -------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/PathautoFieldItemList.php
    --------------------------------------------------------------------------------
    FOUND 3 ERRORS AFFECTING 3 LINES
    --------------------------------------------------------------------------------
      7 | ERROR | Doc comment is empty
     12 | ERROR | Missing short description in doc comment
     32 | ERROR | Missing short description in doc comment
    --------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/AliasCleaner.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 33 ERRORS AFFECTING 33 LINES
    ---------------------------------------------------------------------------------------------------------------------------------------
     197 | ERROR | The array declaration extends to column 89 (the limit is 80). The array content should be split up over multiple lines
     295 | ERROR | The array declaration extends to column 106 (the limit is 80). The array content should be split up over multiple lines
     296 | ERROR | The array declaration extends to column 120 (the limit is 80). The array content should be split up over multiple lines
     297 | ERROR | The array declaration extends to column 93 (the limit is 80). The array content should be split up over multiple lines
     298 | ERROR | The array declaration extends to column 89 (the limit is 80). The array content should be split up over multiple lines
     299 | ERROR | The array declaration extends to column 90 (the limit is 80). The array content should be split up over multiple lines
     300 | ERROR | The array declaration extends to column 90 (the limit is 80). The array content should be split up over multiple lines
     301 | ERROR | The array declaration extends to column 94 (the limit is 80). The array content should be split up over multiple lines
     302 | ERROR | The array declaration extends to column 89 (the limit is 80). The array content should be split up over multiple lines
     303 | ERROR | The array declaration extends to column 93 (the limit is 80). The array content should be split up over multiple lines
     304 | ERROR | The array declaration extends to column 103 (the limit is 80). The array content should be split up over multiple lines
     305 | ERROR | The array declaration extends to column 102 (the limit is 80). The array content should be split up over multiple lines
     306 | ERROR | The array declaration extends to column 103 (the limit is 80). The array content should be split up over multiple lines
     307 | ERROR | The array declaration extends to column 103 (the limit is 80). The array content should be split up over multiple lines
     308 | ERROR | The array declaration extends to column 104 (the limit is 80). The array content should be split up over multiple lines
     309 | ERROR | The array declaration extends to column 93 (the limit is 80). The array content should be split up over multiple lines
     310 | ERROR | The array declaration extends to column 94 (the limit is 80). The array content should be split up over multiple lines
     311 | ERROR | The array declaration extends to column 92 (the limit is 80). The array content should be split up over multiple lines
     312 | ERROR | The array declaration extends to column 93 (the limit is 80). The array content should be split up over multiple lines
     313 | ERROR | The array declaration extends to column 96 (the limit is 80). The array content should be split up over multiple lines
     314 | ERROR | The array declaration extends to column 89 (the limit is 80). The array content should be split up over multiple lines
     315 | ERROR | The array declaration extends to column 95 (the limit is 80). The array content should be split up over multiple lines
     316 | ERROR | The array declaration extends to column 114 (the limit is 80). The array content should be split up over multiple lines
     317 | ERROR | The array declaration extends to column 91 (the limit is 80). The array content should be split up over multiple lines
     318 | ERROR | The array declaration extends to column 100 (the limit is 80). The array content should be split up over multiple lines
     319 | ERROR | The array declaration extends to column 89 (the limit is 80). The array content should be split up over multiple lines
     320 | ERROR | The array declaration extends to column 100 (the limit is 80). The array content should be split up over multiple lines
     321 | ERROR | The array declaration extends to column 101 (the limit is 80). The array content should be split up over multiple lines
     322 | ERROR | The array declaration extends to column 97 (the limit is 80). The array content should be split up over multiple lines
     323 | ERROR | The array declaration extends to column 98 (the limit is 80). The array content should be split up over multiple lines
     324 | ERROR | The array declaration extends to column 101 (the limit is 80). The array content should be split up over multiple lines
     325 | ERROR | The array declaration extends to column 89 (the limit is 80). The array content should be split up over multiple lines
     326 | ERROR | The array declaration extends to column 94 (the limit is 80). The array content should be split up over multiple lines
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/AliasUniquifier.php
    --------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    --------------------------------------------------------------------------
     105 | WARNING | Line exceeds 80 characters; contains 81 characters
    --------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/Commands/PathautoCommands.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 15 ERRORS AFFECTING 13 LINES
    ---------------------------------------------------------------------------------------------------------------------------------------
      65 | ERROR | Doc comment short description must start with a capital letter
      69 | ERROR | Parameter tags must be defined first in a doc comment
     100 | ERROR | The array declaration extends to column 110 (the limit is 80). The array content should be split up over multiple lines
     100 | ERROR | The array declaration extends to column 109 (the limit is 80). The array content should be split up over multiple lines
     107 | ERROR | Parameter $options is not described in comment
     112 | ERROR | Parameter tags must be defined first in a doc comment
     143 | ERROR | The array declaration extends to column 97 (the limit is 80). The array content should be split up over multiple lines
     143 | ERROR | The array declaration extends to column 96 (the limit is 80). The array content should be split up over multiple lines
     148 | ERROR | The array declaration extends to column 100 (the limit is 80). The array content should be split up over multiple lines
     170 | ERROR | Missing short description in doc comment
     183 | ERROR | Missing short description in doc comment
     197 | ERROR | Missing short description in doc comment
     201 | ERROR | @throws tag comment must end with a full stop
     216 | ERROR | Missing short description in doc comment
     220 | ERROR | @throws tag comment must end with a full stop
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/Form/PathautoBulkUpdateForm.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 1 LINE
    ---------------------------------------------------------------------------------------------------------------------------------------
     136 | ERROR | The array declaration extends to column 110 (the limit is 80). The array content should be split up over multiple lines
     136 | ERROR | The array declaration extends to column 109 (the limit is 80). The array content should be split up over multiple lines
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/Form/PatternEditForm.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 4 ERRORS AFFECTING 4 LINES
    ---------------------------------------------------------------------------------------------------------------------------------------
      25 | ERROR | Missing short description in doc comment
     124 | ERROR | The array declaration extends to column 86 (the limit is 80). The array content should be split up over multiple lines
     143 | ERROR | The array declaration extends to column 102 (the limit is 80). The array content should be split up over multiple lines
     226 | ERROR | The array declaration extends to column 93 (the limit is 80). The array content should be split up over multiple lines
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/Form/PathautoAdminDelete.php
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 7 ERRORS AFFECTING 6 LINES
    ---------------------------------------------------------------------------------------------------------------------------------------
      90 | ERROR | The array declaration extends to column 181 (the limit is 80). The array content should be split up over multiple lines
     128 | ERROR | The array declaration extends to column 97 (the limit is 80). The array content should be split up over multiple lines
     128 | ERROR | The array declaration extends to column 96 (the limit is 80). The array content should be split up over multiple lines
     134 | ERROR | The array declaration extends to column 100 (the limit is 80). The array content should be split up over multiple lines
     138 | ERROR | The array declaration extends to column 84 (the limit is 80). The array content should be split up over multiple lines
     139 | ERROR | The array declaration extends to column 100 (the limit is 80). The array content should be split up over multiple lines
     150 | ERROR | The array declaration extends to column 82 (the limit is 80). The array content should be split up over multiple lines
    ---------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/PathautoGeneratorInterface.php
    -------------------------------------------------------------------------------------
    FOUND 8 ERRORS AFFECTING 5 LINES
    -------------------------------------------------------------------------------------
     13 | ERROR | Doc comment short description must start with a capital letter
     13 | ERROR | Doc comment short description must end with a full stop
     18 | ERROR | Doc comment short description must start with a capital letter
     18 | ERROR | Doc comment short description must end with a full stop
     23 | ERROR | Doc comment short description must start with a capital letter
     23 | ERROR | Doc comment short description must end with a full stop
     53 | ERROR | Description for the @return value is missing
     81 | ERROR | Parameter comment must start with a capital letter
    -------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/AliasCleanerInterface.php
    --------------------------------------------------------------------------------
    FOUND 4 ERRORS AND 2 WARNINGS AFFECTING 4 LINES
    --------------------------------------------------------------------------------
      5 | ERROR   | Missing short description in doc comment
     16 | WARNING | Line exceeds 80 characters; contains 81 characters
     55 | WARNING | Line exceeds 80 characters; contains 81 characters
     96 | ERROR   | Type hint "array" missing for $replacements
     96 | ERROR   | Type hint "array" missing for $data
     96 | ERROR   | Type hint "array" missing for $options
    --------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/PathautoPatternInterface.php
    -----------------------------------------------------------------------------------
    FOUND 11 ERRORS AFFECTING 11 LINES
    -----------------------------------------------------------------------------------
      15 | ERROR | Description for the @return value is missing
      22 | ERROR | Missing parameter comment
      31 | ERROR | Description for the @return value is missing
      35 | ERROR | Missing short description in doc comment
      36 | ERROR | Description for the @return value is missing
      43 | ERROR | Description for the @return value is missing
      60 | ERROR | Description for the @return value is missing
     128 | ERROR | Description for the @return value is missing
     149 | ERROR | Description for the @return value is missing
     174 | ERROR | Missing parameter type
     177 | ERROR | Description for the @return value is missing
    -----------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/PathautoState.php
    ------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    ------------------------------------------------------------------------
      30 | ERROR | Missing short description in doc comment
     123 | ERROR | Description for the @return value is missing
    ------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/src/AliasStorageHelperInterface.php
    --------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    --------------------------------------------------------------------------------------
     105 | ERROR | Missing parameter type
     130 | ERROR | Type hint "array" missing for $pids
    --------------------------------------------------------------------------------------
    
    
    FILE: /home/gai/drupal-git/drupal/modules/pathauto/pathauto.api.php
    ----------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    ----------------------------------------------------------------------
     10 | ERROR | Missing short description in doc comment
    ----------------------------------------------------------------------
    
  • Status changed to Needs work over 1 year ago
  • 🇺🇸United States Webbeh Georgia, USA

    Please read the issue before contributing.

    Removing files uploaded in #39 (and other, non-interdiff patches) because, to reiterate again:

    As a friendly reminder, please post interdiffs between patches if you're conducting meaningful work, so maintainers and other users can understand the changes.

    Frankly, I recommend closing this issue as "Will Not Fix" and handling these outside of an issue, as this issue is largely a drive-by patch effort rather than coordinated efforts.

  • First commit to issue fork.
Production build 0.71.5 2024