Repository navigation
Conversation
…ettings only levelcode-ai's settings became application-scoped in #113, but the other bundled extensions' settings were left, and a folder's .vscode/settings.json can still set them, trusted or in Restricted Mode (untrustedWorkspaces is true for these extensions, so VS Code applies no restriction): - levelcode.update.url overrides the update feed, so a folder can make the editor's update check offer a download from the folder's own address. - levelcode.update.enabled and .intervalHours switch that check off or change how often it asks. - levelcode.init.enabled decides whether the user's ~/.levelcode/init.js runs at start. All four are now "scope": "application". The npp-pack's six editing preferences stay folder-settable, written out as an explicit list. New suite levelcode-updater/test/bundledSettingsScope.test.js is default-deny over every bundled extension except levelcode-ai, like levelcode-ai's own settingsScope test: a setting added later is folder-settable only if someone puts it on the list. It fails on the v1.4.1 manifests naming exactly these four settings. Mutations caught: update.url unscoped, a misspelt scope, a new unscoped setting, init.enabled window-scoped.
Contributor
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
#113 made every
levelcode-aisetting user-only. The other bundled extensions were left, and a folder's.vscode/settings.jsoncan still set four of their settings, with its value winning over the user's, in a trusted folder and in Restricted Mode:levelcode.update.urloverrides the update feed. By reading the code, a folder that sets it makes the editor's update check offer a download from the folder's own address.levelcode.update.enabledandlevelcode.update.intervalHoursswitch that check off or change how often it asks.levelcode.init.enableddecides whether the user's~/.levelcode/init.jsruns at start.Restricted Mode does not help:
levelcode-updaterandlevelcode-hackabilityboth declareuntrustedWorkspaces: { supported: true }, so VS Code applies no restriction.v1.4.1 shipped with this open. Its notes say "LevelCode AI settings", which is accurate, and they do not mention it. This PR closes it.
Change
"scope": "application"on those four settings (extensions/levelcode-updater/package.json,extensions/levelcode-hackability/package.json).extensions/levelcode-updater/test/bundledSettingsScope.test.js, default-deny over every bundled extension exceptlevelcode-ai, in the same shape aslevelcode-ai'ssettingsScope.test.js. A setting added later is folder-settable only if someone puts it on the list, and the first test fails until they do. It also fails on a scope the editor does not know, since VS Code reads a misspelt one aswindow.What a folder may still set
The
levelcode-npp-pack's six editing preferences:bigFile.notify,bigFile.thresholdMB,jsonPaste.enabled,jsonPaste.indent,macros.maxReplayCount,macros.maxSteps. They change how the editor treats text and large files. None decides where anything is sent, what runs, or what is trusted. They are written out as the suite's list, so that decision is made in one place.levelcode-themescontributes no settings.Verified
update.urlloses its scope; a misspelt scope; a new unscoped setting added to the updater;init.enabledset towindow../scripts/test-extensions.shpasses, 138 files, exit 0, on macOS (Node 24).Not verified
.vscode/settings.jsonsetslevelcode.update.urland watch the update check. The mechanism is VS Code'sapplicationscope, which fix(agent): a folder's settings no longer change what the desktop agent may do #113 verified in the real editor for thelevelcode-aisettings; I did not repeat that for these four.test.ymlrun is the first Linux run. The suite reads JSON and uses no timers.Release notes
Not touched here. The next release's notes should say that the updater's and the init script's settings are now user-only, and that
levelcode.update.urlcan no longer be set per project.