-
Notifications
You must be signed in to change notification settings - Fork 31k
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
Keep getting a change on workspace open #194375
Comments
✋ I actually thought this was intentional and have pushed the change to |
@justschen There should not be migration happening in this case right? |
disable settings migration, workaround for #194375
I would suggest to check the new value and write only if it is changed. |
Sounds look. Looking into this atm. |
Resolved the settings changing in scenarios where migration is not needed, but in scenarios where migration is needed, the above change still happens. Ends up looking like this:
Digging into it further, this is because @sandy081 @jrieken Not sure if there is a better way to handle the migrations but would appreciate some thoughts/insight - some of the more complex examples in https://github.com/microsoft/vscode/blob/main/src/vs/editor/browser/config/migrateOptions.ts are still a tad different from what we want to accomplish here. |
@justschen I think you are doing the right thing here. The scenario you are hitting here is a limitation with the IConfigurationService.updateValue api. This is true with all editor settings migrations so it is not new with your migration. I would recommend you to go with your change ie., do migration only when value has changed. Filed separate issue to fix this in the update method - #194427 - I would prefer to fix this in next milestone because 1. It is not a regression 2. It is not a simple fix to do and therefore risky to do in the endgame. |
{
"[typescript][javascript]": {
"editor.insertSpaces": false,
"editor.defaultFormatter": "vscode.typescript-language-features",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.organizeImports": true
}
},
"[javascript]": {
"editor.codeActionsOnSave": {
"source.removeUnusedImports": "explicit",
"source.organizeImports": "explicit"
}
},
"[typescript]": {
"editor.codeActionsOnSave": {
"source.removeUnusedImports": "explicit",
"source.organizeImports": "explicit"
}
},
}
To confirm, even though value is migrated to each language independently, the effective value is correct and will be the migrated value. I mean, the value of {
"source.removeUnusedImports": "explicit",
"source.organizeImports": "explicit"
} |
Yes - original override with |
closing and deferring rest of issue to #194427 |
@joyceerhl repro: setting is this:
should end up like this without duplicating the settings:
example with multiple:
expected to turn into:
|
Found following bug while verifying - #199736 |
.vscode/settings.json
which is a spread of those compact settingsBefore
After
The text was updated successfully, but these errors were encountered: