Repository navigation
Description
What happened?
If a tool is in settings.disabledTools, the agent can still call it, and the call still runs.
updateSettings saves disabledTools, and GET /api/agents/:id/system-info shows that tool as enabled: false. But sendMessage gives the model all tools:
const result = await generateText({
...
tools: this.tools,createTools() never checks disabledTools, so a disabled tool is still given to the model.
Example on main with claude-haiku-4.5. The agent was created with {"settings": {"maxSteps": 5, "disabledTools": ["executeOperator"]}}. system-info showed:
[{"name":"deleteOperator","enabled":true},{"name":"addOperator","enabled":true},
{"name":"modifyOperator","enabled":true},{"name":"executeOperator","enabled":false}]Prompt: "Add a CSV File Scan operator that reads the file data.csv, then call the executeOperator tool on it to run it." The agent called addOperator, then executeOperator({"operatorId":"op1"}), and the workflow really ran on the backend (it failed with FileNotFoundException, because the file does not exist).
Expected: tools in disabledTools should not be passed to generateText, or should be rejected when called.
Screenshots
Step 2, tool call: the agent calls executeOperator and it runs, even though system-info says enabled: false.
The chat and canvas: the agent added a CSV File Scan, ran it, and reported the error.
How to reproduce?
- Create an agent with
POST /api/agentsand"settings": {"disabledTools": ["executeOperator"]}. (The panel has no switch for this, so use the API.) GET /api/agents/<id>/system-infoshowsexecuteOperatorwithenabled: false.- In the agent panel, send:
Add a CSV File Scan operator that reads the file data.csv, then call the executeOperator tool on it to run it. - Step 2's details show an
executeOperatorcall and its result.
Version/Branch
1.4.0-incubating-SNAPSHOT (main)
Commit Hash (Optional)
What browsers are you seeing the problem on?
Chrome
Relevant log output
agent-service/src/agent/texera-agent.ts sendMessage: generateText({ tools: this.tools }); createTools() does not check settings.disabledTools

Activity
shaynhornik commentedon Oct 25, 2026
/take
shaynhornik commentedon Oct 25, 2026
I'll fix this by leaving tools listed in
disabledToolsout of the tool set passed togenerateText, plus a test.chenlica commentedon Oct 26, 2026
@shaynhornik Please cross link the issue and your PR.
@yrenat You can be the first reviewer of the PR.
shaynhornik commentedon Oct 26, 2026
@chenlica Thanks, the PR is #9149 (it closes this issue). @yrenat, it's ready for review.
chenlica commentedon Nov 8, 2026
@yrenat Please review it.
yrenat commentedon Nov 8, 2026
Sorry for the delayed reply. I will review it ASAP once I have the bandwidth
yrenat commentedon Nov 10, 2026
@chenlica This PR looks good to me
chenlica commentedon Nov 15, 2026
@bobbai00 Please review it.
fix(agent-service): keep disabled tools away from the model (apache#9149