Fix the issues reported by PHP_CodeSniffer

Created on 7 September 2024, 4 months ago
Updated 13 September 2024, 4 months ago
๐Ÿ“Œ Task
Status

Needs review

Version

1.0

Component

Code

Created by

๐Ÿ‡บ๐Ÿ‡ธUnited States sunil jolapara 3265 Summitrun Drive, Independence, KY, 41051

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

Merge Requests

Comments & Activities

  • Issue created by @sunil jolapara
  • ๐Ÿ‡ฎ๐Ÿ‡นItaly apaderno Brescia, ๐Ÿ‡ฎ๐Ÿ‡น

    avpaderno โ†’ made their first commit to this issueโ€™s fork.

  • Status changed to Active 4 months ago
  • ๐Ÿ‡ฎ๐Ÿ‡นItaly apaderno Brescia, ๐Ÿ‡ฎ๐Ÿ‡น
  • Pipeline finished with Success
    4 months ago
    Total: 141s
    #276398
  • ๐Ÿ‡ฎ๐Ÿ‡นItaly apaderno Brescia, ๐Ÿ‡ฎ๐Ÿ‡น
  • Status changed to Needs review 4 months ago
  • ๐Ÿ‡ฎ๐Ÿ‡นItaly apaderno Brescia, ๐Ÿ‡ฎ๐Ÿ‡น
  • Pipeline finished with Failed
    4 months ago
    Total: 83s
    #276399
  • ๐Ÿ‡ฎ๐Ÿ‡นItaly apaderno Brescia, ๐Ÿ‡ฎ๐Ÿ‡น
  • Status changed to Needs work 4 months ago
  • ๐Ÿ‡ต๐Ÿ‡ญPhilippines cleavinjosh

    Hi @avpaderno,

    I applied MR!2, it was applied smoothly and fixed most of the phpcs issues.

    These are the remaining issues after I ran phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml:

    โžœ  sector_social_follow git:(1.0.x) curl https://git.drupalcode.org/project/sector_social_follow/-/merge_requests/2.diff | patch -p1
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100  2445    0  2445    0     0   5108      0 --:--:-- --:--:-- --:--:--  5104
    patching file .gitlab-ci.yml
    patching file sector_social_follow.install
    โžœ  sector_social_follow git:(1.0.x) โœ— ..
    โžœ  contrib git:(main) โœ— phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml sector_social_follow
    
    FILE: /Users/interns/Demo-site/drupal_11_test/install-dir/drupal_11_test_site/web/modules/contrib/sector_social_follow/sector_social_follow.info.yml
    ----------------------------------------------------------------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 4 WARNINGS AFFECTING 4 LINES
    ----------------------------------------------------------------------------------------------------------------------------------------------------
      1 | WARNING | Remove "version" from the info file, it will be added by drupal.org packaging automatically
      9 | WARNING | All dependencies must be prefixed with the project name, for example "drupal:"
     10 | WARNING | All dependencies must be prefixed with the project name, for example "drupal:"
     11 | WARNING | All dependencies must be prefixed with the project name, for example "drupal:"
    ----------------------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /Users/interns/Demo-site/drupal_11_test/install-dir/drupal_11_test_site/web/modules/contrib/sector_social_follow/sector_social_follow.install
    ---------------------------------------------------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    ---------------------------------------------------------------------------------------------------------------------------------------------------
     13 | ERROR | [x] You must use "/**" style comments for a function comment
    ---------------------------------------------------------------------------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    ---------------------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /Users/interns/Demo-site/drupal_11_test/install-dir/drupal_11_test_site/web/modules/contrib/sector_social_follow/README.md
    --------------------------------------------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 4 WARNINGS AFFECTING 4 LINES
    --------------------------------------------------------------------------------------------------------------------------------
      3 | WARNING | Line exceeds 80 characters; contains 161 characters
      8 | WARNING | Line exceeds 80 characters; contains 234 characters
      9 | WARNING | Line exceeds 80 characters; contains 84 characters
     20 | WARNING | Line exceeds 80 characters; contains 122 characters
    --------------------------------------------------------------------------------------------------------------------------------
    
    Time: 163ms; Memory: 10MB
    
    โžœ  contrib git:(main) โœ—

    Additionally, GitLab CI also found some errors.

    Please check and advise.
    Thank you.

  • Status changed to Needs review 4 months ago
  • ๐Ÿ‡ฎ๐Ÿ‡นItaly apaderno Brescia, ๐Ÿ‡ฎ๐Ÿ‡น

    The only error reported by GitLab CI is the following one.

    FILE: ...b/modules/custom/sector_social_follow-3472719/sector_social_follow.install
    --------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------
     13 | ERROR | [x] You must use "/**" style comments for a function comment
        |       |     (Drupal.Commenting.FunctionComment.WrongStyle)
    --------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    --------------------------------------------------------------------------------
    Time: 100ms; Memory: 6MB
    

     

    I deleted that documentation comment and rewrote it.

  • Pipeline finished with Success
    4 months ago
    Total: 154s
    #282696
Production build 0.71.5 2024