You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
AI code review — automated review for reference; please use your judgment.
packages/core/src/tool/plugin/shell.ts:167 — portable_shell_scanner used to be read directly from config at every guarded invocation, independent of which plugins are enabled; it now flows only through ConfigShellPlugin, so disabling that internal plugin (-opencode.shell-config) silently reverts the scanner to false even when the experimental flag is set in config — if that's intended, fine, but it's an observable behavior change worth noting; otherwise wire the policy transform into a always-on path.
packages/core/src/config/plugin/shell.ts:14 — the refresh chain is wired afterloaded.entries = yield* config.entries() and the subscription starts inside the same effect; a config.updated firing between the initial read and Stream.subscribe is lost, leaving stale portableScanner/shell selection until the next update — subscribe first or do one post-subscription reload, as noted for the variant plugin too (shared helper candidate).
packages/core/test/tool-shell.test.ts:548/:629 — two behavior tests flipped from it.live to productionIt.live; that excludes them from the default CI run precisely where the config-to-state plumbing they cover just changed — please confirm they still execute somewhere (nightly/local profile) or add slimmer always-on equivalents asserting the new ShellPolicy/ToolOutput.limits() paths.
packages/core/config/plugin/shell.ts:17 — Effect.all([a, b], { concurrency: "unbounded" }) for exactly two synchronous-ish reloads adds noise without benefit; plain Effect.all([shell.reload(), policy.reload()], { discard: true }) (sequential) is clearer and avoids interleaved state writes.
Nit — packages/core/src/shell/policy.ts:9 — Data.portableScanner: boolean + single-method Draft is fine, but consider naming the draft method configurePortableScanner (or accepting an object) so future policy knobs don't turn configure(x) into a positional-boolean archaeology dig.
Overall: solid refactor — pulling config parsing out of the per-invocation shell path and the truncation loop into event-refreshed state is the right shape, and the polling-based reload tests verify the wiring end to end. Item 1 deserves an explicit decision; the rest is polish. Thanks!
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
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.
summary
testing