soderlind / vscode-phpcbf

PHP Code Beautifier and Fixer for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=persoderlind.vscode-phpcbf
GNU General Public License v3.0
28 stars 10 forks source link

ERR An unknown error occurred. Please consult the log for more details. #18

Closed matgargano closed 6 years ago

matgargano commented 6 years ago

Hi,

I am running VS Code for MacOS 1.21.1

Extensions installed:

ESLint 1.4.7 PHP Debug 1.12.2 phpcbf 0.0.8 phpcs 1.0.5

I updated my user settings for PHPCS to

{
    "phpcs.standard": "WordPress-Core",
    "phpcs.enable": true,
    "phpcs.executablePath": "/Users/mgargano/projects/phpcs/scripts/phpcs",
    "phpcbf.executablePath": "/Users/mgargano/projects/phpcs/scripts/phpcbf",
    "phpcbf.standard": "WordPress-Core"
}

the paths are correct, see below:

screenshot 2018-03-19 10 25 57

When I go to run format code (right click and format document), nothing happens and I get the following message in the console (Help > Toggle Developer Tools) An unknown error occurred. Please consult the log for more details.

When I pull up the logs I get nothing useful, see below:

screenshot 2018-03-19 10 28 37 screenshot 2018-03-19 10 28 33 screenshot 2018-03-19 10 28 26 screenshot 2018-03-19 10 28 21

Any help would be greatly appreciated....

matgargano commented 6 years ago

looks like it was an old version of PHPCS i had installed, updating PHPCS fixed this!