Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

squizlabs/php_codesniffer from 3.0.0RC3 to 3.0.0 #499

Closed
wants to merge 1 commit into from

Conversation

dependencies[bot]
Copy link

@dependencies dependencies bot commented Oct 23, 2017

squizlabs/php_codesniffer has been updated to 3.0.0 by dependencies.io.

3.0.0

This is the first stable release of the 3.0 branch, and is a large refactoring of the code base. It breaks backwards compatibility for all custom sniffs and custom reports. An upgrade guide for sniff and report developers is available here: https://github.com/squizlabs/PHP_CodeSniffer/wiki/Version-3.0-Upgrade-Guide

Note: If you only use the built-in coding standards (such as PEAR or PSR2), or you have a custom ruleset.xml file that only makes use of the sniffs and reports distributed with PHP_CodeSniffer, you do not need to make any changes to begin using the 3.0.0 version.

There are no future planned releases for the 2.x branch, but there may still be additional 2.9.x versions released for a time due to the number of changes required to upgrade custom sniffs for 3.0. The intention is to limit 2.9.x releases to serious bug and security fixes only.

Changes since 3.0.0RC4

  • Added an --ignore-annotations command line argument to ignore all codingStandards annotations in code comments (request #811)
    • This allows you to force errors to be shown that would otherwise be ignored by code comments
    • Also stop files being able to change sniff properties mid way through processing
  • An error is now reported if no sniffs were registered to be run (request #1129)
  • The autoloader will now search for files inside the directory of any loaded coding standard
    • This allows autoloading of any file inside a custom coding standard without manually requiring them
    • Ensure your namespace begins with your coding standard's directory name and follows PSR-4
    • e.g., StandardName\Sniffs\CategoryName\AbstractHelper or StandardName\Helpers\StringSniffHelper
  • Fixed an error where STDIN was sometimes not checked when using the --parallel CLI option
  • The is_closure index has been removed from the return value of File::getMethodProperties()
    • This value was always false becasue T_FUNCTION tokens are never closures
    • Closures have a token type of T_CLOSURE
  • The File::isAnonymousFunction() method has been removed
    • This function always returned false because it only accepted T_FUNCTION tokens, which are never closures
    • Closures have a token type of T_CLOSURE
  • Includes all changes from the 2.9.0 release
  • Fixed bug #834 : PSR2.ControlStructures.SwitchDeclaration does not handle if branches with returns
    • Thanks to Fabian Wiget for the patch

Changes since 2.x

For a full list of changes from the 2.x version, please review the following changelogs:
https://github.com/squizlabs/PHP_CodeSniffer/releases/tag/3.0.0a1
https://github.com/squizlabs/PHP_CodeSniffer/releases/tag/3.0.0RC1
https://github.com/squizlabs/PHP_CodeSniffer/releases/tag/3.0.0RC2
https://github.com/squizlabs/PHP_CodeSniffer/releases/tag/3.0.0RC3
https://github.com/squizlabs/PHP_CodeSniffer/releases/tag/3.0.0RC4

felixfbecker added a commit that referenced this pull request Oct 28, 2017
BREAKING CHANGE: removes formatting support

closes #501
closes #474
closes #473
closes #468
closes #450
closes #445
closes #443
closes #423
closes #343
closes #296
closes #293
closes #499
closes #471
felixfbecker added a commit that referenced this pull request Oct 28, 2017
BREAKING CHANGE: removes formatting support

closes #501
closes #474
closes #473
closes #468
closes #450
closes #445
closes #443
closes #423
closes #343
closes #296
closes #293
closes #499
closes #471
felixfbecker added a commit that referenced this pull request Oct 28, 2017
BREAKING CHANGE: removes formatting support

closes #501
closes #474
closes #473
closes #468
closes #450
closes #445
closes #443
closes #423
closes #343
closes #296
closes #293
closes #499
closes #471
felixfbecker added a commit that referenced this pull request Oct 28, 2017
BREAKING CHANGE: removes formatting support

closes #501
closes #474
closes #473
closes #468
closes #450
closes #445
closes #443
closes #423
closes #343
closes #296
closes #293
closes #499
closes #471
cgxxv pushed a commit to cgxxv/php-language-server that referenced this pull request Mar 25, 2022
At this point there are countless issues about the formatting done by CodeSniffer. It plain out doesn't work in many cases, overrides format options that are contributed by other extensions in VS Code and does not reuse any of our AST parsing. For that reason, I am starting to think there is no reason to keep it in here until we have proper pretty-printing support from https://github.com/Microsoft/tolerant-php-parser that actually reuses our ASTs and can work while editing. For people who want to use CodeSniffer to format their code, there could be a standalone CodeSniffer language server (like there is a TSLint language server and ESLint language server). As said, we don't reuse our state anyway.

BREAKING CHANGE: removes formatting support

closes felixfbecker#501
closes felixfbecker#474
closes felixfbecker#473
closes felixfbecker#468
closes felixfbecker#450
closes felixfbecker#445
closes felixfbecker#443
closes felixfbecker#423
closes felixfbecker#343
closes felixfbecker#296
closes felixfbecker#293
closes felixfbecker#499
closes felixfbecker#471
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant