Skip to content

Make PHP_CodeSniffer a blocking check (phpcbf baseline cleanup) #417

Closed

Description

@amazing-cat

Summary

PHP_CodeSniffer (advisory) in tests.yml reports violations but never fails, because the codebase has a baseline of 422 errors (all auto-fixable by phpcbf) and 290 warnings in 139 files. Clean up the baseline and make the check blocking so it can be added to the required checks.

Scope

  • Run phpcbf over the files configured in phpcs.xml; formatting only, no behaviour change.
  • Keep warnings (line length, _-prefixed ItemController hooks) non-blocking.
  • CI job PHP_CodeSniffer: on pull requests check changed files and fail on errors; on main check the whole repository and fail on errors.
  • Add the reformatting commit to .git-blame-ignore-revs.

Acceptance criteria

  • vendor/bin/phpcs reports 0 errors on main.
  • The PHPUnit suite is unchanged (same tests, all passing).
  • The job fails on a PR that introduces a PHPCS error and passes on warnings only.

Activity

  1. added this to the 4.1.0 milestone on Oct 25, 2026
  2. added theissue type on Oct 25, 2026
  3. coderabbitai commented on Oct 25, 2026

    @coderabbitai
    🔗 Related PRs

    #400 - ci: add PR quality, security and build checks [merged]


    📝 Issue Planner

    Check the box below or use the @coderabbitai plan command to generate an implementation plan and prompts that you can use with your favorite coding assistant.

    • Create Plan

    🧪 Issue enrichment is currently in open beta.

    You can configure auto-planning by selecting labels in the issue_enrichment configuration.

    To disable automatic issue enrichment, add the following to your .coderabbit.yaml:

    issue_enrichment:
      auto_enrich:
        enabled: false

    💬 Have feedback or questions? Drop into our discord!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    phpPull requests that update Php code

    Type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions