Coder is now checking the format of @deprecated / @see:

FILE: /Users/bojanz/Sites/c2/web/modules/contrib/commerce/modules/price/src/Event/NumberFormatEvent.php
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 10 | ERROR   | The deprecation text '@deprecated No longer fired, switch to NumberFormatDefinitionEvent.' does not match the standard format: @deprecated in %in-version% and will be removed
    |         | from %removal-version%. %extra-info%.
 12 | WARNING | The @see url '\Drupal\commerce_price\Event\PriceEvents' does not match the standard: http(s)://www.drupal.org/node/n or http(s)://www.drupal.org/project/aaa/issues/n
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Let's fix our usages.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

bojanz created an issue. See original summary.

jsacksick’s picture

Status: Active » Needs review
FileSize
10.45 KB

Attached patch for review.

Note that I'm not entirely sure each time to which d.org node I should add a link to (I generally point to the d.o issue referenced in the commit).

This requires #3050166: Contrib project version is not correctly matched in @deprecated tag to be fixed to function properly.

jsacksick’s picture

I missed some! New patch for review.

bojanz’s picture

Status: Needs review » Needs work

Coder 8.3.4 was released, but with the patch applied I still see the same error messages.

bojanz’s picture

The new format is documented in #3024461: Adopt consistent deprecation format for core and contrib deprecation messages and is a PITA to comply with since we are missing change requests for some of the early deprecations. Best path forward is to disable the deprecated sniffs for now, but I've been unable to figure out how: #3068684: How do I disable the DeprecatedSniff?.

  • bojanz committed be79460 on 8.x-2.x
    Issue #3049887 by jsacksick, bojanz: New phpcs failures under drupal/...
bojanz’s picture

Status: Needs work » Fixed

Had to rewrite the entire phpcs.xml file. Fixed some violations along the way. Opened #3073815: Fix the format of Commerce deprecations as a followup.

Status: Fixed » Closed (fixed)

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