Change:
Steps to Reproduce: workbench editor associations to open *.json with a custom editor (e.g. HEX) to change this setting later = you cannot because in order to edit the values, you need to go to the JSON but it will open the custom editor always: ! Imho we should have a way to prevent the override from happening fro built in files such as settings. Only workaround is to entirely reset the setting. //cc
I've made a PR to fix this issue. I'm not sure why it is showing so many changes, it might be due to it being based off of the openWith PR that we had open before it got merged.

Discussion:
import { ICommandService } from 'vs/platform/commands/common/commands'; import { CoreEditingCommands } from 'vs/editor/browser/controller/coreCommands'; import { getErrorMessage } from 'vs/base/common/errors'; <ins> import { EditorOverride } from 'vs/platform/editor/common/editor'; </ins> const emptyEditableSettingsContent = '{n}';

...options, focusSearch: true }; <del> return this.editorService.openEditor(input, options ? SettingsEditorOptions.create(options) : undefined) </del> <ins> return this.editorService.openEditor(input, options ? { ...SettingsEditorOptions.create(options), override: EditorOverride.DISABLED } : { override: EditorOverride.DISABLED }) </ins> .then(() => this.editorGroupService.activeGroup.activeEditorPane!); }

const environment = await this.remoteAgentService.getEnvironment(); if (environment) { await this.createIfNotExists(environment.settingsPath, emptyEditableSettingsContent); <del> return this.editorService.openEditor({ resource: environment.settingsPath, options: { pinned: true, revealIfOpened: true } }); </del> <ins> return this.editorService.openEditor({ resource: environment.settingsPath, options: { pinned: true, revealIfOpened: true, override: EditorOverride.DISABLED } }); </ins> } return undefined; }

const activeEditorGroup = this.editorGroupService.activeGroup; const sideEditorGroup = this.editorGroupService.addGroup(activeEditorGroup.id, GroupDirection.RIGHT); await Promise.all([ <del> this.editorService.openEditor({ resource: this.defaultKeybindingsResource, options: { pinned: true, preserveFocus: true, revealIfOpened: true }, label: nls.localize('defaultKeybindings', "Default Keybindings"), description: '' }), </del> <ins> this.editorService.openEditor({ resource: this.defaultKeybindingsResource, options: { pinned: true, preserveFocus: true, revealIfOpened: true, override: EditorOverride.DISABLED }, label: nls.localize('defaultKeybindings', "Default Keybindings"), description: '' }), </ins> this.editorService.openEditor({ resource: editableKeybindings, options }, sideEditorGroup.id) ]); } else {

} } else { <del> const editor = (await this.editorService.openEditor(this.instantiationService.createInstance(KeybindingsEditorInput), options)) as IKeybindingsEditorPane; </del> <ins> const editor = (await this.editorService.openEditor(this.instantiationService.createInstance(KeybindingsEditorInput), { ...options, override: EditorOverride.DISABLED })) as IKeybindingsEditorPane; </ins> if (options.query) { editor.search(options.query); }

return this.getOrCreateEditableSettingsEditorInput(configurationTarget, resource) .then(editableSettingsEditorInput => { <del> if (!options) { options = { pinned: true }; } else { options = { ...options, pinned: true }; } </del> <ins> options = { ...options, pinned: true }; </ins> if (openDefaultSettings) { const activeEditorGroup = this.editorGroupService.activeGroup; const sideEditorGroup = this.editorGroupService.addGroup(activeEditorGroup.id, GroupDirection.RIGHT); return Promise.all([ <del> this.editorService.openEditor({ resource: this.defaultSettingsRawResource, options: { pinned: true, preserveFocus: true, revealIfOpened: true }, label: nls.localize('defaultSettings', "Default Settings"), description: '' }), this.editorService.openEditor(editableSettingsEditorInput, { pinned: true, revealIfOpened: true }, sideEditorGroup.id) </del> <ins> this.editorService.openEditor({ resource: this.defaultSettingsRawResource, options: { pinned: true, preserveFocus: true, revealIfOpened: true, override: EditorOverride.DISABLED }, label: nls.localize('defaultSettings', "Default Settings"), description: '' }), this.editorService.openEditor(editableSettingsEditorInput, { pinned: true, revealIfOpened: true, override: EditorOverride.DISABLED }, sideEditorGroup.id) </ins> ]).then(([defaultEditor, editor]) => withNullAsUndefined(editor)); } else { <del> return this.editorService.openEditor(editableSettingsEditorInput, SettingsEditorOptions.create(options), group); </del> <ins> return this.editorService.openEditor(editableSettingsEditorInput, { ...SettingsEditorOptions.create(options), override: EditorOverride.DISABLED }, group); </ins> } }); }

const defaultPreferencesEditorInput = this.instantiationService.createInstance(DefaultPreferencesEditorInput, this.getDefaultSettingsResource(configurationTarget)); const preferencesEditorInput = new PreferencesEditorInput(this.getPreferencesEditorInputName(configurationTarget, resource), editableSettingsEditorInput.getDescription(), defaultPreferencesEditorInput, <EditorInput>editableSettingsEditorInput); this.lastOpenedSettingsInput = preferencesEditorInput; <del> return this.editorService.openEditor(preferencesEditorInput, SettingsEditorOptions.create(options), group); </del> <ins> return this.editorService.openEditor(preferencesEditorInput, { ...SettingsEditorOptions.create(options), override: EditorOverride.DISABLED }, group); </ins> }); }