Repository navigation
feat(site/src): add organization subagent limits to Coder Agents settings - #88
Conversation
…not unset a limit
…etched and read-only subagent limit values
|
@codex review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8d8473006d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
A refetch now updates the form while nothing is edited, so the organization inputs cannot go stale next to fresh deployment and effective values. A draft still survives a refetch. The tests assert the cache write instead of rendered copy.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e30f3ecb13
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
|
Codex Review: Didn't find any major issues. Bravo. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Closing and reopening only to make GitHub recompute the merge ref against current main ( |
The merge ref now points at current main ( |
Merge evidence for head
|
Part of #76.
Adds a "Subagent limits" section to the organization part of AI Settings > Coder Agents, behind
fork-nested-subagents. It reads and writesGET/PUT /api/v2/chats/fork/organizations/{organization}/subagent-limits(the response shape from #78).effective; the UI does not re-derive it. A capacity value of 0 renders as "No limit".PUTand the deployment value applies. Values are validated inline (depth 1 to 16, capacity limits 1 or more) and Save stays disabled while a value is invalid. Inputs aretype="text" inputMode="numeric"because a number input reports unparsable text as empty, which would silently unset a limit.updateon the organization's chat model configs (the page's existingcanEdit) can edit. Users who can only read them, such as org auditors, see the values read-only. Plain members, who get 404 from the API, do not see the section and no request is sent.All logic lives in new fork files (
site/src/api/forkSubagentLimits.ts,site/src/api/queries/forkSubagentLimits.ts,ForkSubagentLimits.tsx,components/ForkSubagentLimitsSettings.tsx). The only upstream edit is the hook inOrganizationAgentSettings.tsx. The container readsDashboardContextdirectly instead ofuseDashboard()because the upstreamOrganizationAgentSettingstests and stories mount without aDashboardProvider; a missing dashboard counts as the experiment off.Tests:
ForkSubagentLimits.test.tsx(10 Vitest cases: save with the other set limits and cache update, cleared field omitted, invalid values block the save, a refetch refreshes an unedited form but keeps an unsaved edit, read-only viewer, no request with the experiment off or without read permission), each checked to fail with its behavior broken. Stories cover the visual states.pnpm check,pnpm lintand Vitest forsrc/pages/AISettingsPagepass. UAT ran against the fork UI UAT server (forkmainat ec6cdd6, which includes #78) with this branch's Vite dev server: an org admin set the live limit, an org auditor saw it read-only, the section was hidden with the experiment off, and a real chat in the organization was refused a second live subagent (cannot create a child agent: this chat family has 1 live subagents and the maximum is 1).