PluginInvokeError while using Gemini and search tool in Agent node. #640

Closed
opened 2026-02-16 10:20:01 -05:00 by yindo · 8 comments
Owner

Originally created by @Egoistsoul on GitHub (Sep 12, 2025).

Self Checks

  • I have read the Contributing Guide and Language Policy.
  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report, otherwise it will be closed.
  • 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

1.8.1

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

I use Gemini 2.5 Pro along with search tools like Tavily and Jina within the Agent node in a loop, but it occasionally triggers the error below and halts execution. Sometimes it works fine but sometimes not, and all variables and settings are not changed.

Run failed: Failed to transform agent message: req_id: 66d87d9167 PluginInvokeError: {"args":{},"error_type":"KeyError","message":"'search'"}

You can check this yml for details build:
B-学习内容生成-test.yml

✔️ Expected Behavior

Gemini can run properly in the loop.

Actual Behavior

Image
Originally created by @Egoistsoul on GitHub (Sep 12, 2025). ### Self Checks - [x] I have read the [Contributing Guide](https://github.com/langgenius/dify/blob/main/CONTRIBUTING.md) and [Language Policy](https://github.com/langgenius/dify/issues/1542). - [x] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [x] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones. - [x] I confirm that I am using English to submit this report, otherwise it will be closed. - [x] 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :) - [x] Please do not modify this template :) and fill in all the required fields. ### Dify version 1.8.1 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce I use Gemini 2.5 Pro along with search tools like Tavily and Jina within the Agent node in a loop, but it occasionally triggers the error below and halts execution. Sometimes it works fine but sometimes not, and all variables and settings are not changed. `Run failed: Failed to transform agent message: req_id: 66d87d9167 PluginInvokeError: {"args":{},"error_type":"KeyError","message":"'search'"}` You can check this yml for details build: [B-学习内容生成-test.yml](https://github.com/user-attachments/files/22290891/B-.-test.yml) ### ✔️ Expected Behavior Gemini can run properly in the loop. ### ❌ Actual Behavior <img width="1137" height="336" alt="Image" src="https://github.com/user-attachments/assets/70cbbcce-0c84-470d-a20d-553776fdfc24" />
yindo added the bug label 2026-02-16 10:20:01 -05:00
yindo closed this issue 2026-02-16 10:20:01 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Sep 12, 2025):

The intermittent PluginInvokeError: KeyError 'search' happens because the agent workflow expects the tool/plugin output to always include a 'search' key, but sometimes the response from Gemini or the search tools (like Tavily/Jina) doesn't contain it. This is a known issue in the agent node's tool invocation logic—there isn't a robust check for the key before accessing it, so if the tool result is missing or malformed, the error bubbles up and halts execution. Defensive coding (using .get('search') or explicit checks) would prevent this, but it's not currently implemented in the relevant code paths source.

Immediate workarounds: try adding retry logic for Gemini nodes, ensure your tool/plugin configuration (especially toolConfig) is correct, and consider testing with a model like GPT-4 that has more stable tool-calling support. If you need reliable execution in loops, you may want to add a fallback or default value for the 'search' key in your workflow logic, or update your agent/plugin code to check for key existence before access source.

If you want to avoid this error entirely, suggest maintainers add defensive checks for missing keys in agent node code, especially for multi-tool workflows. For more context and troubleshooting, see similar issues with Gemini and agent nodes here and here.

To reply, just mention @dosu.


How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Chat with Dosu Join Discord Share on X

@dosubot[bot] commented on GitHub (Sep 12, 2025): <!-- Answer --> The intermittent `PluginInvokeError: KeyError 'search'` happens because the agent workflow expects the tool/plugin output to always include a `'search'` key, but sometimes the response from Gemini or the search tools (like Tavily/Jina) doesn't contain it. This is a known issue in the agent node's tool invocation logic—there isn't a robust check for the key before accessing it, so if the tool result is missing or malformed, the error bubbles up and halts execution. Defensive coding (using `.get('search')` or explicit checks) would prevent this, but it's not currently implemented in the relevant code paths [source](https://github.com/langgenius/dify/blob/285291f54527a0e3d2a57c71e1f9a9c2b3f60455/api/core/tools/entities/tool_entities.py). Immediate workarounds: try adding retry logic for Gemini nodes, ensure your tool/plugin configuration (especially `toolConfig`) is correct, and consider testing with a model like GPT-4 that has more stable tool-calling support. If you need reliable execution in loops, you may want to add a fallback or default value for the `'search'` key in your workflow logic, or update your agent/plugin code to check for key existence before access [source](https://github.com/langgenius/dify/issues/20283). If you want to avoid this error entirely, suggest maintainers add defensive checks for missing keys in agent node code, especially for multi-tool workflows. For more context and troubleshooting, see similar issues with Gemini and agent nodes [here](https://github.com/langgenius/dify/issues/16760#issuecomment-2759083839) and [here](https://github.com/langgenius/dify/issues/16989#issuecomment-2760001796). <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=other)</sup>&nbsp;&nbsp;[![Chat with Dosu](https://dosu.dev/dosu-chat-badge.svg)](https://app.dosu.dev/6088a4f4-073a-43f3-b3d4-4f06fb0c05a0/ask?utm_source=github)&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/langgenius/dify/issues/25587)
Author
Owner

@Egoistsoul commented on GitHub (Sep 12, 2025):

The intermittent PluginInvokeError: KeyError 'search' happens because the agent workflow expects the tool/plugin output to always include a 'search' key, but sometimes the response from Gemini or the search tools (like Tavily/Jina) doesn't contain it. This is a known issue in the agent node's tool invocation logic—there isn't a robust check for the key before accessing it, so if the tool result is missing or malformed, the error bubbles up and halts execution. Defensive coding (using .get('search') or explicit checks) would prevent this, but it's not currently implemented in the relevant code paths source.

Immediate workarounds: try adding retry logic for Gemini nodes, ensure your tool/plugin configuration (especially toolConfig) is correct, and consider testing with a model like GPT-4 that has more stable tool-calling support. If you need reliable execution in loops, you may want to add a fallback or default value for the 'search' key in your workflow logic, or update your agent/plugin code to check for key existence before access source.

If you want to avoid this error entirely, suggest maintainers add defensive checks for missing keys in agent node code, especially for multi-tool workflows. For more context and troubleshooting, see similar issues with Gemini and agent nodes here and here.

To reply, just mention @dosu.

How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Chat with Dosu Join Discord Share on X

The agent node currently lacks a retry function; I request its inclusion in the next version. Additionally, is there any update on implementing defensive checks?

@Egoistsoul commented on GitHub (Sep 12, 2025): > The intermittent `PluginInvokeError: KeyError 'search'` happens because the agent workflow expects the tool/plugin output to always include a `'search'` key, but sometimes the response from Gemini or the search tools (like Tavily/Jina) doesn't contain it. This is a known issue in the agent node's tool invocation logic—there isn't a robust check for the key before accessing it, so if the tool result is missing or malformed, the error bubbles up and halts execution. Defensive coding (using `.get('search')` or explicit checks) would prevent this, but it's not currently implemented in the relevant code paths [source](https://github.com/langgenius/dify/blob/285291f54527a0e3d2a57c71e1f9a9c2b3f60455/api/core/tools/entities/tool_entities.py). > > Immediate workarounds: try adding retry logic for Gemini nodes, ensure your tool/plugin configuration (especially `toolConfig`) is correct, and consider testing with a model like GPT-4 that has more stable tool-calling support. If you need reliable execution in loops, you may want to add a fallback or default value for the `'search'` key in your workflow logic, or update your agent/plugin code to check for key existence before access [source](https://github.com/langgenius/dify/issues/20283). > > If you want to avoid this error entirely, suggest maintainers add defensive checks for missing keys in agent node code, especially for multi-tool workflows. For more context and troubleshooting, see similar issues with Gemini and agent nodes [here](https://github.com/langgenius/dify/issues/16760#issuecomment-2759083839) and [here](https://github.com/langgenius/dify/issues/16989#issuecomment-2760001796). > > _To reply, just mention [@dosu](https://go.dosu.dev/dosubot)._ > > How did I do? [Good](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/56133b1c-a872-4ddf-b0a6-4d111b2b969e?feedback_type=other)  [![Chat with Dosu](https://camo.githubusercontent.com/d9ffebb979729c9ef0fc4e3090dbae5b17cabbfec8afe378ada6b81913d6ad8a/68747470733a2f2f646f73752e6465762f646f73752d636861742d62616467652e737667)](https://app.dosu.dev/6088a4f4-073a-43f3-b3d4-4f06fb0c05a0/ask?utm_source=github) [![Join Discord](https://camo.githubusercontent.com/d562c2df5e4567ea41d37f1d91a4da0839d8341037045b103b2da268998de17f/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6a6f696e2d3538363546323f6c6f676f3d646973636f7264266c6f676f436f6c6f723d7768697465266c6162656c3d)](https://go.dosu.dev/discord-bot) [![Share on X](https://camo.githubusercontent.com/4649f705e2396d6f328dbc8e800a0509c9c17b3b20253b36706c393df124b93d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f582d73686172652d626c61636b)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/langgenius/dify/issues/25587) The agent node currently lacks a retry function; I request its inclusion in the next version. Additionally, is there any update on implementing defensive checks?
Author
Owner

@Egoistsoul commented on GitHub (Sep 12, 2025):

Update, I changed the tool from Tavily to Exa search, and got this error:
Run failed: Failed to transform agent message: req_id: 8218d7a549 PluginInvokeError: {"args":{},"error_type":"KeyError","message":"'exa_synthesis'"}

Image
@Egoistsoul commented on GitHub (Sep 12, 2025): Update, I changed the tool from Tavily to Exa search, and got this error: `Run failed: Failed to transform agent message: req_id: 8218d7a549 PluginInvokeError: {"args":{},"error_type":"KeyError","message":"'exa_synthesis'"}` <img width="736" height="81" alt="Image" src="https://github.com/user-attachments/assets/a0678b4d-d5a6-45e2-8394-1d9e0efe9597" />
Author
Owner

@dosubot[bot] commented on GitHub (Sep 12, 2025):

The error with 'exa_synthesis' is caused by the agent node expecting a key in the plugin/tool output that isn't present—just like the previous 'search' KeyError. This happens because the agent workflow directly accesses keys matching the tool name without checking if they exist, and there are no defensive checks in place to handle missing keys in plugin outputs. This is a known systemic issue in Dify's agent node logic for all plugins, especially custom or non-standard ones, and not specific to Exa search or any official plugin design reference.

Immediate workarounds: update your workflow or plugin code to check for key existence before access (e.g., use .get('exa_synthesis') or provide a fallback/default value), verify your plugin/tool configuration, and consider adding retry logic if the error is intermittent. If you control the plugin output, ensure it always returns the expected key, even if the value is empty. There are ongoing requests for maintainers to add defensive key checks and retry mechanisms in future versions, but no recent updates or merged fixes address this yet reference.

If you need more robust handling, you may want to preprocess plugin outputs to match the expected schema before passing them to the agent node. This will prevent execution from halting due to missing keys.

To reply, just mention @dosu.


How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Join Discord Share on X

@dosubot[bot] commented on GitHub (Sep 12, 2025): <!-- Answer --> The error with `'exa_synthesis'` is caused by the agent node expecting a key in the plugin/tool output that isn't present—just like the previous `'search'` KeyError. This happens because the agent workflow directly accesses keys matching the tool name without checking if they exist, and there are no defensive checks in place to handle missing keys in plugin outputs. This is a known systemic issue in Dify's agent node logic for all plugins, especially custom or non-standard ones, and not specific to Exa search or any official plugin design [reference](https://github.com/langgenius/dify-official-plugins/issues/1706). Immediate workarounds: update your workflow or plugin code to check for key existence before access (e.g., use `.get('exa_synthesis')` or provide a fallback/default value), verify your plugin/tool configuration, and consider adding retry logic if the error is intermittent. If you control the plugin output, ensure it always returns the expected key, even if the value is empty. There are ongoing requests for maintainers to add defensive key checks and retry mechanisms in future versions, but no recent updates or merged fixes address this yet [reference](https://github.com/langgenius/dify-official-plugins/issues/1706). If you need more robust handling, you may want to preprocess plugin outputs to match the expected schema before passing them to the agent node. This will prevent execution from halting due to missing keys. <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=other)</sup>&nbsp;&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/langgenius/dify-official-plugins/issues/1704)
Author
Owner

@Egoistsoul commented on GitHub (Sep 12, 2025):

The error with 'exa_synthesis' is caused by the agent node expecting a key in the plugin/tool output that isn't present—just like the previous 'search' KeyError. This happens because the agent workflow directly accesses keys matching the tool name without checking if they exist, and there are no defensive checks in place to handle missing keys in plugin outputs. This is a known systemic issue in Dify's agent node logic for all plugins, especially custom or non-standard ones, and not specific to Exa search or any official plugin design reference.错误 'exa_synthesis' 是由代理节点期望插件/工具输出中存在某个键但实际上不存在所引起的——就像之前的 'search' KeyError 一样。这是因为代理工作流直接访问与工具名称匹配的键,而未检查其是否存在,且在插件输出中缺少处理缺失键的防御性检查。这是 Dify 代理节点逻辑中所有插件(尤其是自定义或非标准插件)的已知系统性问题,并非特定于 Exa 搜索或任何官方插件设计参考。

Immediate workarounds: update your workflow or plugin code to check for key existence before access (e.g., use .get('exa_synthesis') or provide a fallback/default value), verify your plugin/tool configuration, and consider adding retry logic if the error is intermittent. If you control the plugin output, ensure it always returns the expected key, even if the value is empty. There are ongoing requests for maintainers to add defensive key checks and retry mechanisms in future versions, but no recent updates or merged fixes address this yet reference.立即的解决方案:更新你的工作流或插件代码,在访问前检查键是否存在(例如,使用 .get('exa_synthesis') 或提供回退/默认值),验证你的插件/工具配置,并考虑如果错误是间歇性的,添加重试逻辑。如果你控制插件输出,确保它始终返回预期的键,即使值是空的。目前有维护者要求在未来版本中添加防御性键检查和重试机制,但最近的更新或合并的修复尚未解决此问题。

If you need more robust handling, you may want to preprocess plugin outputs to match the expected schema before passing them to the agent node. This will prevent execution from halting due to missing keys.如果您需要更健壮的处理方式,您可能希望在将插件输出传递给代理节点之前,对其进行预处理以匹配预期的模式。这将防止因缺少键而导致的执行中断。

To reply, just mention @dosu.回复时只需提及@dosu。

How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Join Discord Share on X

What is the earliest date this systemic issue was identified?

@Egoistsoul commented on GitHub (Sep 12, 2025): > The error with `'exa_synthesis'` is caused by the agent node expecting a key in the plugin/tool output that isn't present—just like the previous `'search'` KeyError. This happens because the agent workflow directly accesses keys matching the tool name without checking if they exist, and there are no defensive checks in place to handle missing keys in plugin outputs. This is a known systemic issue in Dify's agent node logic for all plugins, especially custom or non-standard ones, and not specific to Exa search or any official plugin design [reference](https://github.com/langgenius/dify-official-plugins/issues/1706).错误 `'exa_synthesis'` 是由代理节点期望插件/工具输出中存在某个键但实际上不存在所引起的——就像之前的 `'search'` KeyError 一样。这是因为代理工作流直接访问与工具名称匹配的键,而未检查其是否存在,且在插件输出中缺少处理缺失键的防御性检查。这是 Dify 代理节点逻辑中所有插件(尤其是自定义或非标准插件)的已知系统性问题,并非特定于 Exa 搜索或任何官方插件设计参考。 > > Immediate workarounds: update your workflow or plugin code to check for key existence before access (e.g., use `.get('exa_synthesis')` or provide a fallback/default value), verify your plugin/tool configuration, and consider adding retry logic if the error is intermittent. If you control the plugin output, ensure it always returns the expected key, even if the value is empty. There are ongoing requests for maintainers to add defensive key checks and retry mechanisms in future versions, but no recent updates or merged fixes address this yet [reference](https://github.com/langgenius/dify-official-plugins/issues/1706).立即的解决方案:更新你的工作流或插件代码,在访问前检查键是否存在(例如,使用 `.get('exa_synthesis')` 或提供回退/默认值),验证你的插件/工具配置,并考虑如果错误是间歇性的,添加重试逻辑。如果你控制插件输出,确保它始终返回预期的键,即使值是空的。目前有维护者要求在未来版本中添加防御性键检查和重试机制,但最近的更新或合并的修复尚未解决此问题。 > > If you need more robust handling, you may want to preprocess plugin outputs to match the expected schema before passing them to the agent node. This will prevent execution from halting due to missing keys.如果您需要更健壮的处理方式,您可能希望在将插件输出传递给代理节点之前,对其进行预处理以匹配预期的模式。这将防止因缺少键而导致的执行中断。 > > _To reply, just mention [@dosu](https://go.dosu.dev/dosubot).回复时只需提及@dosu。_ > > How did I do? [Good](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/d8f0f938-bd60-48ef-981d-b597a98c5212?feedback_type=other)  [<img alt="Join Discord" width="49" height="20" src="https://camo.githubusercontent.com/d562c2df5e4567ea41d37f1d91a4da0839d8341037045b103b2da268998de17f/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6a6f696e2d3538363546323f6c6f676f3d646973636f7264266c6f676f436f6c6f723d7768697465266c6162656c3d">](https://go.dosu.dev/discord-bot) [<img alt="Share on X" width="58" height="20" src="https://camo.githubusercontent.com/4649f705e2396d6f328dbc8e800a0509c9c17b3b20253b36706c393df124b93d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f582d73686172652d626c61636b">](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/langgenius/dify-official-plugins/issues/1704) What is the earliest date this systemic issue was identified?
Author
Owner

@dosubot[bot] commented on GitHub (Sep 28, 2025):

Hi, @Egoistsoul. I'm Dosu, and I'm helping the dify-official-plugins team manage their backlog and am marking this issue as stale.

Issue Summary

  • You reported intermittent KeyError issues ('search' and 'exa_synthesis') in Dify 1.8.1 when running Gemini 2.5 Pro with various search tools in an agent node loop.
  • The errors cause unpredictable halts due to missing defensive checks for expected keys in plugin outputs.
  • This is a known systemic issue affecting all plugins, especially custom ones.
  • Workarounds include adding retry logic, verifying tool configurations, and updating code to check key existence before access.
  • You requested retry functionality and defensive checks in future versions and asked about the earliest identification date of this issue.

Next Steps

  • Please let me know if this issue is still relevant with the latest version of dify-official-plugins by commenting here to keep the discussion open.
  • Otherwise, I will automatically close this issue in 5 days.

Thank you for your understanding and contribution!

@dosubot[bot] commented on GitHub (Sep 28, 2025): Hi, @Egoistsoul. I'm [Dosu](https://dosu.dev), and I'm helping the dify-official-plugins team manage their backlog and am marking this issue as stale. **Issue Summary** - You reported intermittent KeyError issues ('search' and 'exa_synthesis') in Dify 1.8.1 when running Gemini 2.5 Pro with various search tools in an agent node loop. - The errors cause unpredictable halts due to missing defensive checks for expected keys in plugin outputs. - This is a known systemic issue affecting all plugins, especially custom ones. - Workarounds include adding retry logic, verifying tool configurations, and updating code to check key existence before access. - You requested retry functionality and defensive checks in future versions and asked about the earliest identification date of this issue. **Next Steps** - Please let me know if this issue is still relevant with the latest version of dify-official-plugins by commenting here to keep the discussion open. - Otherwise, I will automatically close this issue in 5 days. Thank you for your understanding and contribution!
Author
Owner

@Egoistsoul commented on GitHub (Nov 3, 2025):

Hi, @Egoistsoul. I'm Dosu, and I'm helping the dify-official-plugins team manage their backlog and am marking this issue as stale.

Issue Summary

  • You reported intermittent KeyError issues ('search' and 'exa_synthesis') in Dify 1.8.1 when running Gemini 2.5 Pro with various search tools in an agent node loop.
  • The errors cause unpredictable halts due to missing defensive checks for expected keys in plugin outputs.
  • This is a known systemic issue affecting all plugins, especially custom ones.
  • Workarounds include adding retry logic, verifying tool configurations, and updating code to check key existence before access.
  • You requested retry functionality and defensive checks in future versions and asked about the earliest identification date of this issue.

Next Steps

  • Please let me know if this issue is still relevant with the latest version of dify-official-plugins by commenting here to keep the discussion open.
  • Otherwise, I will automatically close this issue in 5 days.

Thank you for your understanding and contribution!

This issue still exist in Dify 1.9.2 and Gemini Plugin 0.5.6

@Egoistsoul commented on GitHub (Nov 3, 2025): > Hi, [@Egoistsoul](https://github.com/Egoistsoul). I'm [Dosu](https://dosu.dev), and I'm helping the dify-official-plugins team manage their backlog and am marking this issue as stale. > > **Issue Summary** > > * You reported intermittent KeyError issues ('search' and 'exa_synthesis') in Dify 1.8.1 when running Gemini 2.5 Pro with various search tools in an agent node loop. > * The errors cause unpredictable halts due to missing defensive checks for expected keys in plugin outputs. > * This is a known systemic issue affecting all plugins, especially custom ones. > * Workarounds include adding retry logic, verifying tool configurations, and updating code to check key existence before access. > * You requested retry functionality and defensive checks in future versions and asked about the earliest identification date of this issue. > > **Next Steps** > > * Please let me know if this issue is still relevant with the latest version of dify-official-plugins by commenting here to keep the discussion open. > * Otherwise, I will automatically close this issue in 5 days. > > Thank you for your understanding and contribution! This issue still exist in Dify 1.9.2 and Gemini Plugin 0.5.6
Author
Owner

@dosubot[bot] commented on GitHub (Nov 3, 2025):

@crazywoola The user reports that the intermittent KeyError issues with Dify 1.9.2 and Gemini Plugin 0.5.6 still persist and requests assistance with retry functionality and defensive checks in the plugins. Could you please help address this ongoing problem?

@dosubot[bot] commented on GitHub (Nov 3, 2025): @crazywoola The user reports that the intermittent KeyError issues with Dify 1.9.2 and Gemini Plugin 0.5.6 still persist and requests assistance with retry functionality and defensive checks in the plugins. Could you please help address this ongoing problem?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify-official-plugins#640