fix(core): limit v2 subagent nesting depth (#37291)

This commit is contained in:
opencode-agent[bot] 2026-07-16 09:28:15 -04:00 committed by GitHub
commit d01dfa57b7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 116 additions and 0 deletions

View file

@ -283,6 +283,12 @@ describe("Config", () => {
}),
)
it.effect("migrates the v1 experimental subagent depth", () =>
Effect.sync(() => {
expect(ConfigMigrateV1.migrate({ experimental: { subagent_depth: 2 } }).experimental?.subagent_depth).toBe(2)
}),
)
it.effect("migrates v1 provider setup options into AISDK settings", () =>
Effect.sync(() => {
const migrated = ConfigMigrateV1.migrate({