QuickApps version
latest
What steps will reproduce the bug?
- Configure a
dial-mcp tool pointing at a deployment that returns attachments, e.g.:
{
"type": "dial-mcp",
"deployment_id": "toolsets/public/document_vision__1.0.0",
"attachment": {
"propagate_types_to_choice": []
}
}
- Trigger a tool call that returns an attachment whose MIME type is not in the (empty) allow-list.
- Observe the chat response / choice.
What is the expected behavior?
With propagate_types_to_choice set to [], no tool attachments should be pushed to the choice.
matches_type(type, []) in src/quickapp/common/utils.py returns False for every type, so
StagedBaseTool._run_in_stage_report_success (src/quickapp/common/staged_base_tool.py:316)
should not append any attachment to result.propagate_to_choice.
What do you see instead?
Tool message attachments are still pushed to the choice — the flag has no effect.
Additional information
The direct tool_call_result.propagate_to_choice path in staged_base_tool.py does appear to
honor the empty list correctly. The leak looks like it comes from a second path: attachments kept
in context for the orchestrator model (keep_in_context_types) get echoed back by the LLM in its
own assistant-message stream, and ChoiceUiSink._add_attachments
(src/quickapp/common/chat_completion_stream/choice_ui_stream_sink.py) currently adds every
attachment from that stream to the choice unconditionally, with no awareness of the tool's
propagate_types_to_choice config. This second path isn't gated by the attachment config at all.
QuickApps version
latest
What steps will reproduce the bug?
dial-mcptool pointing at a deployment that returns attachments, e.g.:{ "type": "dial-mcp", "deployment_id": "toolsets/public/document_vision__1.0.0", "attachment": { "propagate_types_to_choice": [] } }What is the expected behavior?
With
propagate_types_to_choiceset to[], no tool attachments should be pushed to the choice.matches_type(type, [])insrc/quickapp/common/utils.pyreturnsFalsefor every type, soStagedBaseTool._run_in_stage_report_success(src/quickapp/common/staged_base_tool.py:316)should not append any attachment to
result.propagate_to_choice.What do you see instead?
Tool message attachments are still pushed to the choice — the flag has no effect.
Additional information
The direct
tool_call_result.propagate_to_choicepath instaged_base_tool.pydoes appear tohonor the empty list correctly. The leak looks like it comes from a second path: attachments kept
in context for the orchestrator model (
keep_in_context_types) get echoed back by the LLM in itsown assistant-message stream, and
ChoiceUiSink._add_attachments(
src/quickapp/common/chat_completion_stream/choice_ui_stream_sink.py) currently adds everyattachment from that stream to the choice unconditionally, with no awareness of the tool's
propagate_types_to_choiceconfig. This second path isn't gated by the attachment config at all.