-
-
This is dependent on OD-2934
-
Noted @zaakiy — issue #2934 is already closed; the agreed follow-up is issue #2935 (Task Automation checkbox / template default for
OPENCODE_DANGEROUSLY_SKIP_PERMISSIONS). I've marked this issue as Blocked By #2935. -
@servicedesk ensure to retain
### Rules You are talking to an AI user.Even though we are blocked, plan the changes here, in anticipation of #2935 being completed.
-
@zaakiy — Confirmed. We'll keep the
### Rulesheader andYou are talking to an AI user.line.Planned change (once issue #2935 unblocks)
File:
server-core/src/main/java/io/onedev/server/workspace/DefaultWorkspaceService.java(task prompt construction, ~lines 1156–1157)Current preamble:
### Rules You are talking to an AI user. If you start any sub-agents, wait for them to complete before finishing.Planned preamble:
### Rules You are talking to an AI user. Do not pause or output 'waiting' messages after sub-agents complete. Immediately process their results, write the code changes, and execute the implementation in this session.Scope
- This issue: only the preamble string replacement above.
OPENCODE_DANGEROUSLY_SKIP_PERMISSIONS/ Task Automation checkbox remains in issue #2935.
Does this planned wording look good to you?
-
new text
Do not pause or output 'waiting' messages after sub-agents complete. Immediately process their results, write any required code changes, and execute the implementation in this session. -
@zaakiy — Noted. Updated plan with your wording:
### Rules You are talking to an AI user. Do not pause or output 'waiting' messages after sub-agents complete. Immediately process their results, write any required code changes, and execute the implementation in this session.We'll implement this string replacement in
DefaultWorkspaceServiceonce issue #2935 unblocks. -
Name Previous Value Current Value Assignee
robin
wh
-
-
Implemented the agreed Rules preamble change in
DefaultWorkspaceService, keeping the### Rulesheader andYou are talking to an AI user.line, and replacing the sub-agent wait rule with continue-immediately guidance. -
| Type |
Improvement
|
| Priority |
Normal
|
| Assignee | |
| Labels |
No labels
|
Context
From issue #2939 (oh-my-openagent / custom OpenCode images that rely heavily on sub-agents): the current default AI task automation Rules preamble in
DefaultWorkspaceServiceis:That only covers “don’t finish while sub-agents are still running.” In practice with heavy sub-agent use, the parent agent can still pause or emit “waiting” messages after sub-agents have already returned, which stalls headless workspace task runs.
Requested change
Replace the sub-agent line above with:
Location:
server-core/src/main/java/io/onedev/server/workspace/DefaultWorkspaceService.java(task prompt construction for workspace task automation).Notes
OPENCODE_DANGEROUSLY_SKIP_PERMISSIONS=true(env var inherited by sub-agents) in addition to--dangerously-skip-permissionson the mainopencode run— consider whether built-in Open Code workspace templates should set the env var as a separate change.