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
{{ message }}
Repository navigation
The instructions config field is loaded, documented and recommended, but never read #52417
instructions in opencode.json is accepted, validated, migrated from v1 and stored on the config document — but nothing ever reads it. The docs recommend it, and /init points users at it.
packages/schema/src/config.ts:90 declares it: "Additional paths or URLs supplying ambient instructions".
packages/core/src/config/normalize.ts:222 decodes it onto the document; v1/config/migrate.ts:59 carries it across from v1.
packages/core/test/config/config.test.ts:1277 pins the loaded value.
The only producer of instruction files is config/plugin/instruction.ts, whose sources are two hard-coded AGENTS.md lookups (:62 global, :68 ancestor walk). It does not take a Config dependency.
git grep 'info.instructions' over packages/*/src returns nothing.
docs/rules.mdx:134 calls this field "the recommended approach", and documents glob patterns, remote URLs and a 5 second fetch timeout. None of that exists today. A team that follows the docs gets no instruction files, and no diagnostic that the field was ignored.
This is not a regression from #41629: instruction-discovery.ts had no Config reference before that refactor either.
Three ways to close it, with different costs:
Honour it as documented. Add a third source in instruction.ts that expands each document's instructions (~/, globs via fs.scan, http(s) with the documented timeout), mirroring config/plugin/skill.ts:83. Needs decisions on the base directory for relative paths, ordering against AGENTS.md, and whether glob matches are watched.
Warn and move on. Emit a diagnostic when instructions is present but unsupported. Small, and stops misleading users, but leaves a documented feature dead.
Remove the field and the docs. Correct, but breaks anyone who set it and keeps the config.test.ts:1277 assertion meaningful only as a schema test.
I'd lean towards 1, with 2 as a stopgap if wiring it up needs design time. Happy to take whichever you prefer — option 1 is mostly mechanical once the three questions above are settled.
Duplicate of #51341, which already has a fix in flight: #51422.
I had independently traced the same root cause (the field is decoded onto the config document but no producer reads it) and missed that #51341 was open. Withdrawing this one so the thread stays in one place.
Activity
github-actions commentedon Oct 1, 2026
This issue might be a duplicate of existing issues. Please check:
config.instructionsfield is not loaded into session context, with the same behavior described here.config.instructionsentries are never loaded; the report notes the same schema/docs mismatch.feiiiiii5 commentedon Oct 1, 2026
Duplicate of #51341, which already has a fix in flight: #51422.
I had independently traced the same root cause (the field is decoded onto the config document but no producer reads it) and missed that #51341 was open. Withdrawing this one so the thread stays in one place.