-
Notifications
You must be signed in to change notification settings - Fork 15.4k
batch can drift from active turn tool filtering #21367
Copy link
Copy link
Open
Labels
coreAnything pertaining to core functionality of the application (opencode server stuff)Anything pertaining to core functionality of the application (opencode server stuff)
Description
Description
batch resolves executable tools independently from the active turn filter, so batched execution can disagree with the tool set the model actually saw.
Observed failure modes:
batchcan miss model-gated tools such asapply_patchwhen the active model would expose thembatchcan attempt subcalls that were not exposed in the current turn
This is related to, but distinct from, #16028. That issue is about permission aliasing for apply_patch; this one is about batch drifting from the active turn's model-specific and per-turn-filtered tool set.
Plugins
None
OpenCode version
Current dev branch behavior prior to PR #21366
Steps to reproduce
- Start a turn where
SessionPromptexposes a filtered tool set to the model - Use a GPT-5-style patch flow where
apply_patchis available for the active turn - Call
batchwith anapply_patchsubcall - Observe that
batchresolves tools independently from the turn context instead of using the active{ providerID, modelID }and turn allowlist
Screenshot and/or share link
N/A
Operating System
Linux
Terminal
bash
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
coreAnything pertaining to core functionality of the application (opencode server stuff)Anything pertaining to core functionality of the application (opencode server stuff)
Type
Fields
Give feedbackNo fields configured for issues without a type.