coding-standards icon indicating copy to clipboard operation
coding-standards copied to clipboard

Uncaught TypeError: vsprintf(): Argument #2 ($values) must be of type array, string given

Open jazzsequence opened this issue 2 years ago • 0 comments

Fatal error is being thrown by phpcs. Reported in https://github.com/squizlabs/PHP_CodeSniffer/issues/3196, determined to be a WPCS error and fixed here https://github.com/WordPress/WordPress-Coding-Standards/commit/7cd46bed1e6a7a2af3fe24c7f4a044da3076d8f4

Suggested resolution: bump WPCS to latest (2.3.0)

Workaround: You can temporarily work around the error by manually requiring the latest version of wpcs but calling it the latest supported version by HM coding standards, e.g.:

"require-dev": {
    "humanmade/coding-standards": "^1.1",
    "wp-coding-standards/wpcs": "2.3.0 as 2.2.1"
}

jazzsequence avatar Apr 07 '22 16:04 jazzsequence