Fix the issues reported by phpcs

Created on 6 February 2023, almost 2 years ago
Updated 13 September 2024, 2 months ago

GitLab CI reports PHP_CodeSniffer warnings/errors which should be fixed.

FILE: ...odules/custom/jsonrpc-3436320/tests/src/Functional/ResponseHeadersTest.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
 16 | ERROR | Missing member variable doc comment
    |       | (Drupal.Commenting.VariableComment.Missing)
--------------------------------------------------------------------------------
FILE: ...eb/modules/custom/jsonrpc-3436320/tests/src/Functional/JsonRpcTestBase.php
--------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
--------------------------------------------------------------------------------
 15 | WARNING | The class short comment should describe what the class does and
    |         | not simply repeat the class name
    |         | (Drupal.Commenting.ClassComment.Short)
--------------------------------------------------------------------------------
FILE: ...s/issue/jsonrpc-3436320/web/modules/custom/jsonrpc-3436320/src/Handler.php
--------------------------------------------------------------------------------
FOUND 0 ERRORS AND 3 WARNINGS AFFECTING 3 LINES
--------------------------------------------------------------------------------
 155 | WARNING | [x] '@TODO: Remove the following when PHP7 is the minimum
     |         |     supported version.' should match the format '@todo Fix
     |         |     problem X here.'
     |         |     (Drupal.Commenting.TodoComment.TodoFormat)
 218 | WARNING | [x] 'TODO: Add cacheability metadata here.' should match the
     |         |     format '@todo Fix problem X here.'
     |         |     (Drupal.Commenting.TodoComment.TodoFormat)
 219 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
     |         |     (Drupal.Commenting.InlineVariableComment.VarInline)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...436320/web/modules/custom/jsonrpc-3436320/src/Shaper/RpcRequestFactory.php
--------------------------------------------------------------------------------
FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
--------------------------------------------------------------------------------
  12 | ERROR   | [x] Use statements should be sorted alphabetically. The first
     |         |     wrong one is Drupal\jsonrpc\ParameterDefinitionInterface.
     |         |     (SlevomatCodingStandard.Namespaces.AlphabeticallySortedUses.IncorrectlyOrderedUses)
 106 | ERROR   | [x] Use null coalesce operator instead of ternary operator.
     |         |     (SlevomatCodingStandard.ControlStructures.RequireNullCoalesceOperator.NullCoalesceOperatorNotUsed)
 177 | WARNING | [x] 'TODO: Wrap other shaper transformations in a similar way
     |         |     for nicer' should match the format '@todo Fix problem X
     |         |     here.' (Drupal.Commenting.TodoComment.TodoFormat)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...320/web/modules/custom/jsonrpc-3436320/src/Plugin/JsonRpcMethodManager.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
--------------------------------------------------------------------------------
  7 | ERROR   | [x] Use statements should be sorted alphabetically. The first
    |         |     wrong one is Drupal\Core\Cache\CacheBackendInterface.
    |         |     (SlevomatCodingStandard.Namespaces.AlphabeticallySortedUses.IncorrectlyOrderedUses)
 41 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
    |         |     (Drupal.Commenting.InlineVariableComment.VarInline)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...jsonrpc-3436320/web/modules/custom/jsonrpc-3436320/src/Object/Response.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
 58 | ERROR | Parameter $headers is not described in comment
    |       | (Drupal.Commenting.FunctionComment.ParamMissingDefinition)
--------------------------------------------------------------------------------
FILE: ...rpc-3436320/web/modules/custom/jsonrpc-3436320/src/Object/ParameterBag.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
 49 | ERROR | [x] Use null coalesce operator instead of ternary operator.
    |       |     (SlevomatCodingStandard.ControlStructures.RequireNullCoalesceOperator.NullCoalesceOperatorNotUsed)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...ue/jsonrpc-3436320/web/modules/custom/jsonrpc-3436320/src/Object/Error.php
--------------------------------------------------------------------------------
FOUND 2 ERRORS AFFECTING 2 LINES
--------------------------------------------------------------------------------
 22 | ERROR | Missing member variable doc comment
    |       | (Drupal.Commenting.VariableComment.Missing)
 30 | ERROR | Missing member variable doc comment
    |       | (Drupal.Commenting.VariableComment.Missing)
--------------------------------------------------------------------------------
FILE: ...dules/custom/jsonrpc-3436320/src/Annotation/JsonRpcParameterDefinition.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
 72 | ERROR | [x] Use null coalesce operator instead of ternary operator.
    |       |     (SlevomatCodingStandard.ControlStructures.RequireNullCoalesceOperator.NullCoalesceOperatorNotUsed)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: .../jsonrpc-3436320/modules/jsonrpc_core/tests/src/Functional/PluginsTest.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
 15 | ERROR | Missing member variable doc comment
    |       | (Drupal.Commenting.VariableComment.Missing)
--------------------------------------------------------------------------------
FILE: ...0/modules/jsonrpc_core/tests/src/Functional/MaintenanceModeEnabledTest.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
 15 | ERROR | Missing member variable doc comment
    |       | (Drupal.Commenting.VariableComment.Missing)
--------------------------------------------------------------------------------
FILE: ...jsonrpc-3436320/modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Plugins.php
--------------------------------------------------------------------------------
FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
--------------------------------------------------------------------------------
 63 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
    |         |     (Drupal.Commenting.InlineVariableComment.VarInline)
 65 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
    |         |     (Drupal.Commenting.InlineVariableComment.VarInline)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...3436320/modules/jsonrpc_core/src/Plugin/jsonrpc/Method/ListPermissions.php
--------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
--------------------------------------------------------------------------------
 37 | WARNING | [x] 'TODO: Fix the schema.' should match the format '@todo Fix
    |         |     problem X here.' (Drupal.Commenting.TodoComment.TodoFormat)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...m/jsonrpc-3436320/modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Cache.php
--------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
--------------------------------------------------------------------------------
 16 | WARNING | The class short comment should describe what the class does and
    |         | not simply repeat the class name
    |         | (Drupal.Commenting.ClassComment.Short)
--------------------------------------------------------------------------------
FILE: ...320/modules/jsonrpc_core/src/Plugin/jsonrpc/Method/AddPermissionToRole.php
--------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
--------------------------------------------------------------------------------
 31 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
    |         |     (Drupal.Commenting.InlineVariableComment.VarInline)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
Time: 395ms; Memory: 6MB

 
 

šŸ“Œ Task
Status

Fixed

Version

2.0

Component

Code

Created by

šŸ‡ÆšŸ‡µJapan ptmkenny

Live updates comments and jobs are added and updated live.
  • Coding standards

    It involves compliance with, or the content of coding standards. Requires broad community agreement.

Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @ptmkenny
  • Merge request !4Issue #3339557: Fix coding standards ā†’ (Merged) created by ptmkenny
  • šŸ‡ÆšŸ‡µJapan ptmkenny

    The MR fixes all errors listed in the IS.

  • Status changed to Needs review over 1 year ago
  • šŸ‡®šŸ‡¹Italy apaderno Brescia, šŸ‡®šŸ‡¹
  • Status changed to RTBC over 1 year ago
  • šŸ‡µšŸ‡­Philippines paraderojether

    Hi ptmkenny

    I reviewed MR!4, and verified it fixes all the error reported by the phpcs. Drupal core 9.5.8, JSON-RPC 2.x-dev.

    I added screenshots for reference.
    Thank You.

  • Status changed to Needs work over 1 year ago
  • šŸ‡®šŸ‡¹Italy apaderno Brescia, šŸ‡®šŸ‡¹
  • Open in Jenkins ā†’ Open on Drupal.org ā†’
    Core: 10.0.7 + Environment: PHP 8.1 & MariaDB 10.3.22
    last update over 1 year ago
    4 pass
  • Status changed to Needs review over 1 year ago
  • Status changed to Needs work 6 months ago
  • šŸ‡µšŸ‡­Philippines clarkssquared

    Hi

    I applied the updated MR !4 and there's still a PHPCS error below:

    āžœ  jsonrpc git:(2.x) curl https://git.drupalcode.org/project/jsonrpc/-/merge_requests/4.diff | patch -p1
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100 10938    0 10938    0     0  16218      0 --:--:-- --:--:-- --:--:-- 16374
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/AddPermissionToRole.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Cache.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/ListPermissions.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Plugins.php'
    patching file 'modules/jsonrpc_core/tests/src/Functional/MaintenanceModeEnabledTest.php'
    patching file 'modules/jsonrpc_core/tests/src/Functional/PluginsTest.php'
    patching file 'src/Annotation/JsonRpcParameterDefinition.php'
    patching file 'src/Handler.php'
    patching file 'src/Object/Error.php'
    patching file 'src/Object/ParameterBag.php'
    patching file 'src/Object/Response.php'
    patching file 'src/Plugin/JsonRpcMethodManager.php'
    patching file 'src/Shaper/RpcRequestFactory.php'
    patching file 'tests/src/Functional/JsonRpcTestBase.php'
    patching file 'tests/src/Functional/ResponseHeadersTest.php'
    āžœ  jsonrpc git:(2.x) āœ— ..
    āžœ  contrib git:(master) āœ— phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml jsonrpc
    
    FILE: ...9/d9-local/web/modules/contrib/jsonrpc/src/Plugin/JsonRpcMethodManager.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     7 | ERROR | [x] Use statements should be sorted alphabetically. The first
       |       |     wrong one is Drupal\Core\Cache\CacheBackendInterface.
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: ...s/d9/d9-local/web/modules/contrib/jsonrpc/src/Shaper/RpcRequestFactory.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     12 | ERROR | [x] Use statements should be sorted alphabetically. The first
        |       |     wrong one is Drupal\jsonrpc\ParameterDefinitionInterface.
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    Time: 646ms; Memory: 12MB
    
    āžœ  contrib git:(master) āœ— 
    

    Below is the full PHPCS result before and after applying the MR !4

    āžœ  contrib git:(master) āœ— phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml jsonrpc 
    
    FILE: ...local/web/modules/contrib/jsonrpc/tests/src/Functional/JsonRpcTestBase.php
    --------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     15 | WARNING | The class short comment should describe what the class does and
        |         | not simply repeat the class name
    --------------------------------------------------------------------------------
    
    
    FILE: ...l/web/modules/contrib/jsonrpc/tests/src/Functional/ResponseHeadersTest.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     16 | ERROR | Missing member variable doc comment
    --------------------------------------------------------------------------------
    
    
    FILE: ...c/modules/jsonrpc_core/tests/src/Functional/MaintenanceModeEnabledTest.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     15 | ERROR | Missing member variable doc comment
    --------------------------------------------------------------------------------
    
    
    FILE: .../contrib/jsonrpc/modules/jsonrpc_core/tests/src/Functional/PluginsTest.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     15 | ERROR | Missing member variable doc comment
    --------------------------------------------------------------------------------
    
    
    FILE: ...rpc/modules/jsonrpc_core/src/Plugin/jsonrpc/Method/AddPermissionToRole.php
    --------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     31 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: ...s/contrib/jsonrpc/modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Cache.php
    --------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     16 | WARNING | The class short comment should describe what the class does and
        |         | not simply repeat the class name
    --------------------------------------------------------------------------------
    
    
    FILE: ...contrib/jsonrpc/modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Plugins.php
    --------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
    --------------------------------------------------------------------------------
     63 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
     65 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: ...jsonrpc/modules/jsonrpc_core/src/Plugin/jsonrpc/Method/ListPermissions.php
    --------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     37 | WARNING | [x] 'TODO: Fix the schema.' should match the format '@todo Fix
        |         |     problem X here.'
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: ...ng-subing/Projects/d9/d9-local/web/modules/contrib/jsonrpc/src/Handler.php
    --------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 3 WARNINGS AFFECTING 3 LINES
    --------------------------------------------------------------------------------
     155 | WARNING | [x] '@TODO: Remove the following when PHP7 is the minimum
         |         |     supported version.' should match the format '@todo Fix
         |         |     problem X here.'
     218 | WARNING | [x] 'TODO: Add cacheability metadata here.' should match the
         |         |     format '@todo Fix problem X here.'
     219 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: ...9/d9-local/web/modules/contrib/jsonrpc/src/Plugin/JsonRpcMethodManager.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
    --------------------------------------------------------------------------------
      7 | ERROR   | [x] Use statements should be sorted alphabetically. The first
        |         |     wrong one is Drupal\Core\Cache\CacheBackendInterface.
     41 | WARNING | [x] Inline @var declarations should use the /** */ delimiters
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: .../web/modules/contrib/jsonrpc/src/Annotation/JsonRpcParameterDefinition.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     72 | ERROR | [x] Use null coalesce operator instead of ternary operator.
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: ...s/d9/d9-local/web/modules/contrib/jsonrpc/src/Shaper/RpcRequestFactory.php
    --------------------------------------------------------------------------------
    FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
    --------------------------------------------------------------------------------
      12 | ERROR   | [x] Use statements should be sorted alphabetically. The first
         |         |     wrong one is Drupal\jsonrpc\ParameterDefinitionInterface.
     106 | ERROR   | [x] Use null coalesce operator instead of ternary operator.
     177 | WARNING | [x] 'TODO: Wrap other shaper transformations in a similar way
         |         |     for nicer' should match the format '@todo Fix problem X
         |         |     here.'
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: ...g/Projects/d9/d9-local/web/modules/contrib/jsonrpc/src/Object/Response.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     58 | ERROR | Parameter $headers is not described in comment
    --------------------------------------------------------------------------------
    
    
    FILE: ...bing/Projects/d9/d9-local/web/modules/contrib/jsonrpc/src/Object/Error.php
    --------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    --------------------------------------------------------------------------------
     22 | ERROR | Missing member variable doc comment
     30 | ERROR | Missing member variable doc comment
    --------------------------------------------------------------------------------
    
    
    FILE: ...ojects/d9/d9-local/web/modules/contrib/jsonrpc/src/Object/ParameterBag.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     49 | ERROR | [x] Use null coalesce operator instead of ternary operator.
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    Time: 712ms; Memory: 12MB
    
    āžœ  contrib git:(master) āœ— cd jsonrpc 
    āžœ  jsonrpc git:(2.x) curl https://git.drupalcode.org/project/jsonrpc/-/merge_requests/4.diff | patch -p1
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100 10938    0 10938    0     0  16218      0 --:--:-- --:--:-- --:--:-- 16374
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/AddPermissionToRole.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Cache.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/ListPermissions.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Plugins.php'
    patching file 'modules/jsonrpc_core/tests/src/Functional/MaintenanceModeEnabledTest.php'
    patching file 'modules/jsonrpc_core/tests/src/Functional/PluginsTest.php'
    patching file 'src/Annotation/JsonRpcParameterDefinition.php'
    patching file 'src/Handler.php'
    patching file 'src/Object/Error.php'
    patching file 'src/Object/ParameterBag.php'
    patching file 'src/Object/Response.php'
    patching file 'src/Plugin/JsonRpcMethodManager.php'
    patching file 'src/Shaper/RpcRequestFactory.php'
    patching file 'tests/src/Functional/JsonRpcTestBase.php'
    patching file 'tests/src/Functional/ResponseHeadersTest.php'
    āžœ  jsonrpc git:(2.x) āœ— ..
    āžœ  contrib git:(master) āœ— phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml jsonrpc
    
    FILE: ...9/d9-local/web/modules/contrib/jsonrpc/src/Plugin/JsonRpcMethodManager.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     7 | ERROR | [x] Use statements should be sorted alphabetically. The first
       |       |     wrong one is Drupal\Core\Cache\CacheBackendInterface.
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    
    FILE: ...s/d9/d9-local/web/modules/contrib/jsonrpc/src/Shaper/RpcRequestFactory.php
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     12 | ERROR | [x] Use statements should be sorted alphabetically. The first
        |       |     wrong one is Drupal\jsonrpc\ParameterDefinitionInterface.
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    
    Time: 646ms; Memory: 12MB
    
    āžœ  contrib git:(master) āœ— 
    

    Moving this to needs work

  • Open in Jenkins ā†’ Open on Drupal.org ā†’
    Core: 10.2.1 + Environment: PHP 8.1 & MariaDB 10.3.22
    last update 6 months ago
    4 pass
  • Status changed to Needs review 6 months ago
  • šŸ‡ÆšŸ‡µJapan ptmkenny

    @clarkssquared Good catch, the coding standards had been updated since this was originally submitted.

  • šŸ‡µšŸ‡­Philippines clarkssquared

    Hi ptmkenny,

    I applied the updated MR !4 after commit 873f5808, and I confirmed that there are no PHPCS issues

    āžœ  jsonrpc git:(2.x) curl https://git.drupalcode.org/project/jsonrpc/-/merge_requests/4.diff | patch -p1
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100 11826    0 11826    0     0  26106      0 --:--:-- --:--:-- --:--:-- 26456
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/AddPermissionToRole.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Cache.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/ListPermissions.php'
    patching file 'modules/jsonrpc_core/src/Plugin/jsonrpc/Method/Plugins.php'
    patching file 'modules/jsonrpc_core/tests/src/Functional/MaintenanceModeEnabledTest.php'
    patching file 'modules/jsonrpc_core/tests/src/Functional/PluginsTest.php'
    patching file 'src/Annotation/JsonRpcParameterDefinition.php'
    patching file 'src/Handler.php'
    patching file 'src/Object/Error.php'
    patching file 'src/Object/ParameterBag.php'
    patching file 'src/Object/Response.php'
    patching file 'src/Plugin/JsonRpcMethodManager.php'
    patching file 'src/Shaper/RpcRequestFactory.php'
    patching file 'tests/src/Functional/JsonRpcTestBase.php'
    patching file 'tests/src/Functional/ResponseHeadersTest.php'
    āžœ  jsonrpc git:(2.x) āœ— ..
    āžœ  contrib git:(master) āœ— phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml jsonrpc            
    āžœ  contrib git:(master) āœ— 
    

    RTBC +1 from me, I will retain the status to needs review for others to also give their feedbacks.

  • šŸ‡®šŸ‡¹Italy apaderno Brescia, šŸ‡®šŸ‡¹
  • Pipeline finished with Skipped
    3 months ago
    #269830
    • ptmkenny ā†’ committed fd6f1499 on 2.x
      Issue #3339557 by ptmkenny, paraderojether, avpaderno, clarkssquared:...
  • Status changed to Fixed 3 months ago
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024