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

Resolve formatting inconsistency between positron-python extension and main Positron codebase #5838

Open
juliasilge opened this issue Dec 19, 2024 · 1 comment
Labels
area: builds Issues related to Builds category. enhancement New feature or request lang: python

Comments

@juliasilge
Copy link
Contributor

We have two upstream repos that we incorporate into this repo at a regular cadence, both the Python extension and the Code - OSS repo. The upstream projects have different sets of formatting rules for the same kinds of files. We believe we want to maintain the same formatting as the upstream projects because if we did not, managing these upstream merges would be much more difficult. The current state we are dealing with is that if you have the main positron workspace open and make any changes to files in the positron-python extension, the formatting rules from the main workspace are applied to those files. If you check in that change, the linter fails.

My current workaround here is to:

  • make changes to files in the positron-python folder, build, iterate, etc
  • save the files (maybe close VS Code here, to avoid making any other edits using the workspace settings)
  • run npm run format-fix in positron/extensions/positron-python to fix the formatting of the files I just edited

Another workaround people have shared with me that can be used for very small changes is to run "File: Save without Formatting" in VS Code on such files. 😩

This is a pain point for all of us, but new team members are tripping over it in a bad way. Let's find a way to resolve this inconsistency. Is a multi-root workspace the way to go?

For reference:

@juliasilge juliasilge added enhancement New feature or request area: builds Issues related to Builds category. lang: python labels Dec 19, 2024
@juliasilge
Copy link
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: builds Issues related to Builds category. enhancement New feature or request lang: python
Projects
None yet
Development

No branches or pull requests

1 participant