Skip to content

Mute PHPCS 4's SinceTagNotAllowed for Codacy - #181

Merged
PDowney merged 1 commit into
mainfrom
codacy-phpcs4
Nov 27, 2026
Merged

PDowney merged 1 commit into
mainfrom
codacy-phpcs4

Conversation

@PDowney

@PDowney PDowney commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

Keeps phpcs.xml the same as in the other EngineScript plugins. Codacy has no open issues here today, so this prevents future false positives rather than fixing current ones.

WordPress-Docs asks for @since on properties, and the generated rules in phpcs.xml already mute Squiz.Commenting.VariableComment.TagNotAllowed. Codacy runs PHPCS 4.0.4, which reports @since on a property under a new code, SinceTagNotAllowed, that PHPCS 3 doesn't have. That code flagged every documented property in free-gift-coupons and optimizations-ace-mc. The hand-written part of phpcs.xml now mutes it too. The generated rules are unchanged, and codacy-configs.py phpcs --check passes.

Checked locally: Codacy's PHPCS 4.0.4 with its standards finds nothing. composer phpcs, PHPCS 3 on phpcs.xml and gitleaks also pass.

🤖 Generated with Claude Code

WordPress-Docs asks for @SInCE on properties and mutes
Squiz.Commenting.VariableComment.TagNotAllowed, which the generated
rules copy. Codacy runs PHPCS 4.0.4, which reports @SInCE on a property
under a code of its own, SinceTagNotAllowed, that PHPCS 3 does not have,
so Codacy flagged every documented property. The new code is muted in
the hand-written part of phpcs.xml; the generated rules are unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for contributing to EngineScript Site Optimizer!

Before we review:

  • Have you tested your changes with WordPress 7.0+?
  • Are your changes compatible with PHP 8.3+?
  • Have you followed WordPress coding standards?
  • Did you update the CHANGELOG.md if needed?

Security Reminder
This plugin stores per-site settings and emits browser resource hints, so please ensure:

  • All user input is properly sanitized
  • All output is properly escaped
  • No security vulnerabilities are introduced

We'll review your PR soon.

@codacy-production

codacy-production Bot commented Nov 26, 2026 •

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Coverage ∅ diff coverage · +0.00% coverage variation

Metric Results
Coverage variation ✅ +0.00% coverage variation (-1.00%)
Diff coverage ✅ ∅ diff coverage

View coverage diff in Codacy

Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (e6659e4) 871 841 96.56%
Head commit (cc82aa9) 871 (+0) 841 (+0) 96.56% (+0.00%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#181) 0 0 ∅ (not applicable)

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@PDowney
PDowney merged commit 1342d3e into main Nov 27, 2026
28 checks passed
@PDowney
PDowney deleted the codacy-phpcs4 branch November 27, 2026 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant