open-southeners / vscode-laravel-pint

🍺 Integrates Laravel Pint into your VSCode projects for automatic code formatting
https://marketplace.visualstudio.com/items?itemName=open-southeners.laravel-pint
MIT License
81 stars 17 forks source link

Formatting no longer works on macOS #58

Open zepfietje opened 8 months ago

zepfietje commented 8 months ago

Describe the bug

When using "Format document using Laravel Pint", "Format Document", or "Format On Save", PHP files are no longer formatted using the extension. Running ./vendor/bin/pint manually works just fine. I noticed this issue in the last couple weeks. Managed to fix it briefly by uninstall and reinstall the extension (IIRC), but it's back to broken again.

To Reproduce

Steps to reproduce the behavior:

  1. Install the extension.
  2. Open a poorly formatted PHP file in a Laravel project.
  3. Call "Formaat document using Laravel Pint" from the VS Code command palette.
  4. Watch as nothing happens.

Expected behavior

I expect the extension to format the file using Laravel Pint.

Screenshots

Environment:

Additional context

d8vjork commented 8 months ago

Weird, to me all these format methods works and I'm on a Mac using 1.1.8

d8vjork commented 8 months ago

Do you use any pint.json config? And what about the pint binary (global or local)? Any modification to the extension config?

zepfietje commented 8 months ago

I don't use a pint.json config, have Pint configured on a per-project basis (so as dependency in composer.json). No modifications to extension.

samlinck commented 7 months ago

I have the same problem. Everything works fine when using vendor/bin/pint. But Format document using Laravel Pint does nothing.

d8vjork commented 7 months ago

I tried to replicate but still no luck, will probably do on a new install

https://github.com/open-southeners/vscode-laravel-pint/assets/2331052/84bc0c84-37d2-4c5b-9fd2-de4eedc94080

Ukesh2010 commented 7 months ago

Having the same issue.

hooch commented 7 months ago

Same issue, running vendor/bin/pint formats code as expected. But formatting from within VSC, nothing happens. This was with 1.2.0. Tried installing earlier versions but VSC reports CorruptZip: end of central directory record signature not found

jleonardolemos commented 6 months ago

Same for me using linux. Nothing happens in developer tools too.

danielgalanrodriguez commented 6 months ago

Same issue here. Nothing happens when formatting the document using Laravel Pint from VSC command palette. I use the project's pint.json config with a local installation of the binary.

There is nothing strange in the output. Just the common message Formatting completed in XXms

Environment:

For now I manage to get it working by:

Let's see if it happens again.

gregoryalary commented 4 months ago

Same issue as well :/

SilvioLucasDev commented 3 months ago

Same issue here

zepfietje commented 3 months ago

@d8vjork, have you been able to reproduce this issue yet? It seems like a lot of other people are running into the same bug.

yondifon commented 3 months ago

same issue here.

martin-ro commented 1 month ago

Same here

mangaljptech commented 2 weeks ago

same here