Problem/Motivation

FILE: ...dules/custom/cloudflare_stream-3446508/src/Service/CloudflareStreamApi.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
80 | ERROR | [x] Multi-line function declarations must have a trailing comma
| | after the last parameter
| | (Drupal.Functions.MultiLineFunctionDeclaration.MissingTrailingComma)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...oudflare_stream-3446508/src/Plugin/Field/FieldType/CloudflareVideoItem.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
80 | ERROR | [x] Multi-line function declarations must have a trailing comma
| | after the last parameter
| | (Drupal.Functions.MultiLineFunctionDeclaration.MissingTrailingComma)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...tream-3446508/src/Plugin/Field/FieldFormatter/CloudflareVideoFormatter.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
83 | ERROR | [x] Multi-line function declarations must have a trailing comma
| | after the last parameter
| | (Drupal.Functions.MultiLineFunctionDeclaration.MissingTrailingComma)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...loudflare_stream-3446508/modules/cloudflare_stream_sync/src/SyncVideos.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
53 | ERROR | [x] Multi-line function declarations must have a trailing comma
| | after the last parameter
| | (Drupal.Functions.MultiLineFunctionDeclaration.MissingTrailingComma)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...eam-3446508/modules/cloudflare_stream_sync/src/Form/SyncVideosSettings.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
44 | ERROR | [x] Multi-line function declarations must have a trailing comma
| | after the last parameter
| | (Drupal.Functions.MultiLineFunctionDeclaration.MissingTrailingComma)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...stream-3446508/modules/cloudflare_stream_sync/src/Commands/SyncCommand.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
27 | ERROR | [x] Multi-line function declarations must have a trailing comma
| | after the last parameter
| | (Drupal.Functions.MultiLineFunctionDeclaration.MissingTrailingComma)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
FILE: ...oudflare_stream_hosted_video/src/Plugin/media/Source/HostedVideoSource.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
65 | ERROR | [x] Multi-line function declarations must have a trailing comma
| | after the last parameter
| | (Drupal.Functions.MultiLineFunctionDeclaration.MissingTrailingComma)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
Time: 280ms; Memory: 6MB
PHP CODE SNIFFER REPORT SUMMARY
--------------------------------------------------------------------------------
FILE ERRORS WARNINGS
--------------------------------------------------------------------------------
..._hosted_video/src/Plugin/media/Source/HostedVideoSource.php 1 0
...m-3446508/modules/cloudflare_stream_sync/src/SyncVideos.php 1 0
...modules/cloudflare_stream_sync/src/Commands/SyncCommand.php 1 0
...ules/cloudflare_stream_sync/src/Form/SyncVideosSettings.php 1 0
...rc/Plugin/Field/FieldFormatter/CloudflareVideoFormatter.php 1 0
...-3446508/src/Plugin/Field/FieldType/CloudflareVideoItem.php 1 0
...oudflare_stream-3446508/src/Service/CloudflareStreamApi.php 1 0
--------------------------------------------------------------------------------
A TOTAL OF 7 ERRORS AND 0 WARNINGS WERE FOUND IN 15 FILES
--------------------------------------------------------------------------------
PHPCBF CAN FIX 7 OF THESE SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
PHP CODE SNIFFER VIOLATION SOURCE SUMMARY
-----------------------------------------------------------------------------
SOURCE COUNT
-----------------------------------------------------------------------------
[x] Drupal.Functions.MultiLineFunctionDeclaration.MissingTrailingComma 7
-----------------------------------------------------------------------------
A TOTAL OF 7 SNIFF VIOLATIONS WERE FOUND IN 1 SOURCE
-----------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SOURCES AUTOMATICALLY (7 VIOLATIONS IN TOTAL)
-----------------------------------------------------------------------------

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

atul_ghate created an issue. See original summary.

atul_ghate’s picture

I will provide MR to fix this phpcs issue.

shivamsen_12579 made their first commit to this issue’s fork.

tim-diels’s picture

Status: Active » Postponed (maintainer needs more info)

This is not yet included in the default coding standards pipeline from Drupal. So please report what version you're using to get this report.

@shivamsen_12579 why are you taking an issue that is assigned to someone else? Please allow someone who is assigned to an issue to actually work on it.

avpaderno’s picture

Issue tags: -phpcs

@atul_ghate Since this project is using GitLAb CI, it gets PHP_CodeSniffer warnings/errors already reported, and there are no warnings/errors, so far.
If there are changes to do as per coding standards, it is probably better to report them without any reference to PHP_CodeSniffer.

atul_ghate’s picture

Hi @tim-diels and apaderno, Thank you for the clarification, But I encountered phpcs issue in this MR https://git.drupalcode.org/issue/cloudflare_stream-3446508/-/jobs/1613819 with this version 3.0.x

avpaderno’s picture

GitLab CI does not report any PHP_CodeSniffer warning/error. That is the job ran for this very issue.
I only updated the .gitlab-ci.yml file from the most recent template file, just to make GitLab CI run for this issue.

atul_ghate’s picture

Assigned: atul_ghate » Unassigned
tim-diels’s picture

Title: Fix issues reported by phpcs » Update gitlab CI file
Status: Postponed (maintainer needs more info) » Reviewed & tested by the community

@apaderno, thanks for the information. Looks like this MR is ready to go in. I updated the title to reflect more what this MR does.

tim-diels’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.