PHP_CodeSniffer icon indicating copy to clipboard operation
PHP_CodeSniffer copied to clipboard

PHP_CodeSniffer tokenizes PHP files and detects violations of a defined set of coding standards.

Results 100 PHP_CodeSniffer issues
Sort by recently updated
recently updated
newest added

Follow up/repost from https://github.com/squizlabs/PHP_CodeSniffer/issues/2823: > A number of sniffs contain a `public $error` property to toggle whether the sniff should throw an `error` or a `warning`. > > This property...

Type: breaking change
Standard: Generic
Standard: Squiz

Repost from https://github.com/squizlabs/PHP_CodeSniffer/issues/2898 by @gsherwood: > Version 4 is a good time to review the exit codes that both scripts produce to ensure that success cases all use `0` and...

Type: breaking change
Type: meta

End to end tests should be introduced in a separate test suite to cover the use of all supported CLI arguments (and some combinations of these). PHPUnit supports a `phpt`...

Type: chores/QA
Status: help wanted

It was previously already announced that the 4.0 release will drop support for: * JavaScript and CSS tokenizers, which also means the JS and CSS specific sniffs will be removed....

Type: meta
Status: waiting for opinions

Follow up on #198. * [ ] Remove the `getBlacklist()` and `getWhitelist()` methods. * [ ] Make the new `getDisallowedFiles()` and `getAllowedFiles()` methods `abstract` and change the return type from...

Type: breaking change
Type: chores/QA
Core Component: Other

The Generic.CodeAnalysis.ForLoopShouldBeWhileLoop sniff is used to detect `for` loops that can be simplified to `while` loops. Currently, the sniff is triggered only when it finds a `for` loop that only...

## Description The current method, listing codes to disable and a list of exceptions to that list, still has trouble with some cases. For example, disabling a standard, re-enabling a...

Type: breaking change
Type: bug
Core Component: File
Core Component: Tokenizer
Core Component: Utils
Status: triage
Status: has merge conflict

Repost from https://github.com/squizlabs/PHP_CodeSniffer/issues/3601: > The following code sample: > ```php >

Core Component: Tokenizer
Status: waiting for opinions

## Description Recreation of upstream PR https://github.com/squizlabs/PHP_CodeSniffer/pull/3771: > ### Generic/Todo-Fixme: make the sniffs more selective > > The sniffs as-they-were, would sniff all comment related tokens, including `T_DOC_COMMENT_STAR`, `T_DOC_COMMENT_WHITESPACE` etc....

Type: enhancement
Focus: Comments/Docblocks
Focus: Performance
Standard: Generic

Repost from https://github.com/squizlabs/PHP_CodeSniffer/issues/1955 by @gsherwood: > Everywhere a sniff code or error message code is sourced from a ruleset, do case insensitive matching on the real sniff and error codes....

Type: enhancement
Core Component: Config & Ruleset & CLI options