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

Issues with prettier-vscode not working properly with plugins since prettier 3.1.0 release #16102

Closed
TOnDAhNe opened this issue Feb 20, 2024 · 8 comments

Comments

@TOnDAhNe
Copy link

There are plenty of issues about this problem in the prettier-vscode repository, but it seems like nobody cares, so I created this issue to draw attention to it.

prettier/prettier-vscode#3253
prettier/prettier-vscode#3251
prettier/prettier-vscode#3241
prettier/prettier-vscode#3235
prettier/prettier-vscode#3224
prettier/prettier-vscode#3104
prettier/prettier-vscode#3071

Environments:

  • Prettier Version: 3.2.5
  • Running Prettier via: prettier-vscode
  • Runtime: VSCode 1.86.2
  • Operating System: macOS
  • Prettier plugins (if any):

Steps to reproduce:

Install the prettier-vscode plugin in vscode, install any plugin, for example prettier-xml, set prettier-xml as the formatter for xml files, configure .prettierrc (or another config file), attempt to use prettier for formatting xml.

Expected behavior:

The file was formatted.

Actual behavior:

The file was not formatted.

@phocks
Copy link

phocks commented Feb 28, 2024

Yep, same: prettier/prettier-vscode#3253 (comment)

@MikeMcDonald83
Copy link

prettier/prettier-vscode#3235 (comment) fixed this for me. I put mine in the user settings like "prettier.configPath": ".prettierrc",. My 3.1.1 install is correctly loading plugins again. It's probably unintended behavior, but it's a pretty easy workaround.

@phocks
Copy link

phocks commented Feb 29, 2024

prettier/prettier-vscode#3235 (comment) fixed this for me. I put mine in the user settings like "prettier.configPath": ".prettierrc",. My 3.1.1 install is correctly loading plugins again. It's probably unintended behavior, but it's a pretty easy workaround.

Thanks. Can confirm this works. With 3.1.1 and the latest prettier version 3.2.5. If you use yaml formatting etc, just replace it with .prettierrc.yaml or whatever your prettier config file is called.

Hopefully this pull request in the VS Code Prettier Extension fixes things for good. prettier/prettier-vscode#3267

@TOnDAhNe
Copy link
Author

@MikeMcDonald83

Yeah, users have already discovered a workaround, and it does function, but should an extension that doesn't operate correctly without external intervention be distributed? An intervention that a user can only discover by visiting the repository of that extension and spending some time looking for the solution?

I don't think so, at least not until the developers pay attention to this issue and fix it so the extension could work out of the box, just like it used to.

@MikeMcDonald83
Copy link

@MikeMcDonald83

Yeah, users have already discovered a workaround, and it does function, but should an extension that doesn't operate correctly without external intervention be distributed? An intervention that a user can only discover by visiting the repository of that extension and spending some time looking for the solution?

I don't think so, at least not until the developers pay attention to this issue and fix it so the extension could work out of the box, just like it used to.

I totally agree about the expectations. That's why I meant by "It's probably unintended behavior." That being said, it looks like there aren't a lot of people working full time on these large and complex repos. Some of them are making many changes per day. Maybe they need help. Or maybe they are just working through a backlog.

@agreedSkiing
Copy link

From the issue prettier/prettier-vscode#3235 any one of the merged changes in 3.1.1 could be the culprit https://github.com/prettier/prettier/blob/main/CHANGELOG.md#311.

I think either #15663 or #15363 might be the root cause

@cnwork
Copy link

cnwork commented Mar 20, 2024

same issue here, please fix this

@sosukesuzuki
Copy link
Member

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

No branches or pull requests

6 participants