chilly-france-44439
10/10/2025, 3:03 AMError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!
Traceback (most recent call last):
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands_cli/simple_main.py", line 45, in main
run_cli_entry(resume_conversation_id=args.resume)
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands_cli/agent_chat.py", line 173, in run_cli_entry
runner.process_message(message)
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands_cli/runner.py", line 83, in process_message
self._run_with_confirmation()
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands_cli/runner.py", line 103, in _run_with_confirmation
self.conversation.run()
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands/sdk/conversation/impl/local_conversation.py", line 245, in run
self.agent.step(self._state, on_event=self._on_event)
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands/sdk/agent/agent.py", line 226, in step
action_event = self._get_action_event(
^^^^^^^^^^^^^^^^^^^^^^^
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands/sdk/agent/agent.py", line 353, in _get_action_event
raise RuntimeError(
RuntimeError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!
Traceback (most recent call last):
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/bin/openhands", line 12, in <module>
sys.exit(main())
^^^^^^
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands_cli/simple_main.py", line 45, in main
run_cli_entry(resume_conversation_id=args.resume)
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands_cli/agent_chat.py", line 173, in run_cli_entry
runner.process_message(message)
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands_cli/runner.py", line 83, in process_message
self._run_with_confirmation()
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands_cli/runner.py", line 103, in _run_with_confirmation
self.conversation.run()
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands/sdk/conversation/impl/local_conversation.py", line 245, in run
self.agent.step(self._state, on_event=self._on_event)
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands/sdk/agent/agent.py", line 226, in step
action_event = self._get_action_event(
^^^^^^^^^^^^^^^^^^^^^^^
File "/home/xingyaow/.cache/uv/archive-v0/4O2s5H4GUkriWq5g6YjrC/lib/python3.12/site-packages/openhands/sdk/agent/agent.py", line 353, in _get_action_event
raise RuntimeError(
RuntimeError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!chilly-france-44439
10/10/2025, 3:04 AMnutritious-balloon-65098
10/10/2025, 3:09 AMnutritious-balloon-65098
10/10/2025, 3:16 AMsecurity_risk parameter but no security analyzer is configured
Root Cause Analysis:
⢠Identified that the issue stems from the interaction between:
a. The CLI's setup_conversation() function that conditionally includes security analyzers
b. The toggle_confirmation_mode() function that removes the security analyzer when confirmation mode is disabled
c. The LLM still returning security_risk parameters in responses
d. The openhands-sdk expecting a security analyzer when security_risk is present
Suggested Fixes:
⢠Three potential approaches: SDK-side fix, CLI-side fix, or LLM prompt fix
Complete Error Traceback:
⢠Full stack trace showing the error originates from openhands/sdk/agent/agent.py line 353
Related Information:
⢠Linked to recent commit 9fe4e9715 ("CLI(V1): Fix confirmation mode breaking on weaker models")
⢠Listed relevant files in the codebase
⢠Noted the SDK dependency version (commit 189979a5013751aa86852ab41afe9a79555e62ac)
⢠Highlighted the impact: makes CLI unusable for affected users
The issue is now tracked and can be reviewed by the OpenHands team for resolution.
<sub>View full conversation</sub>quick-window-91705
10/10/2025, 3:25 AMchilly-france-44439
10/10/2025, 5:34 PMchilly-france-44439
10/10/2025, 5:34 PMchilly-france-44439
10/10/2025, 5:35 PMquick-window-91705
10/10/2025, 5:36 PMquick-window-91705
10/10/2025, 5:39 PMIt prompts me for confirmation on an FileEditorAction (which we don't really ask LLM to predict risk for)Ah this seems fishy will dig into it
chilly-france-44439
10/10/2025, 6:04 PMError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!
Traceback (most recent call last):
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands_cli/simple_main.py", line 45, in main
run_cli_entry(resume_conversation_id=args.resume)
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands_cli/agent_chat.py", line 173, in run_cli_entry
runner.process_message(message)
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands_cli/runner.py", line 83, in process_message
self._run_with_confirmation()
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands_cli/runner.py", line 103, in _run_with_confirmation
self.conversation.run()
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands/sdk/conversation/impl/local_conversation.py", line 245, in run
self.agent.step(self._state, on_event=self._on_event)
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands/sdk/agent/agent.py", line 226, in step
action_event = self._get_action_event(
^^^^^^^^^^^^^^^^^^^^^^^
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands/sdk/agent/agent.py", line 353, in _get_action_event
raise RuntimeError(
RuntimeError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!
Traceback (most recent call last):
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/bin/openhands", line 12, in <module>
sys.exit(main())
^^^^^^
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands_cli/simple_main.py", line 45, in main
run_cli_entry(resume_conversation_id=args.resume)
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands_cli/agent_chat.py", line 173, in run_cli_entry
runner.process_message(message)
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands_cli/runner.py", line 83, in process_message
self._run_with_confirmation()
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands_cli/runner.py", line 103, in _run_with_confirmation
self.conversation.run()
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands/sdk/conversation/impl/local_conversation.py", line 245, in run
self.agent.step(self._state, on_event=self._on_event)
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands/sdk/agent/agent.py", line 226, in step
action_event = self._get_action_event(
^^^^^^^^^^^^^^^^^^^^^^^
File "/home/xingyaow/.cache/uv/archive-v0/Uqy_3HcNJFJ00FSWlWQlK/lib/python3.12/site-packages/openhands/sdk/agent/agent.py", line 353, in _get_action_event
raise RuntimeError(
RuntimeError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!
quick-window-91705
10/10/2025, 6:24 PMquick-window-91705
10/10/2025, 6:29 PMchilly-france-44439
10/10/2025, 6:30 PMchilly-france-44439
10/10/2025, 6:30 PMchilly-france-44439
10/10/2025, 6:30 PMchilly-france-44439
10/10/2025, 6:30 PMquick-window-91705
10/10/2025, 6:34 PMnutritious-balloon-65098
10/10/2025, 6:44 PMchilly-france-44439
10/10/2025, 6:44 PMchilly-france-44439
10/10/2025, 6:45 PMnutritious-balloon-65098
10/10/2025, 6:45 PMchilly-france-44439
10/10/2025, 6:46 PMnutritious-balloon-65098
10/10/2025, 6:46 PMquick-window-91705
10/10/2025, 6:49 PMchilly-france-44439
10/10/2025, 6:50 PMquick-window-91705
10/10/2025, 6:55 PMadamant-controller-19704
10/13/2025, 5:12 AMError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!
Traceback (most recent call last):
File "openhands_cli/simple_main.py", line 45, in main
File "openhands_cli/agent_chat.py", line 173, in run_cli_entry
File "openhands_cli/runner.py", line 83, in process_message
File "openhands_cli/runner.py", line 103, in _run_with_confirmation
File "openhands/sdk/conversation/impl/local_conversation.py", line 245, in run
File "openhands/sdk/agent/agent.py", line 226, in step
File "openhands/sdk/agent/agent.py", line 353, in _get_action_event
RuntimeError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!
Traceback (most recent call last):
File "openhands_cli/simple_main.py", line 59, in module
File "openhands_cli/simple_main.py", line 45, in main
File "openhands_cli/agent_chat.py", line 173, in run_cli_entry
File "openhands_cli/runner.py", line 83, in process_message
File "openhands_cli/runner.py", line 103, in _run_with_confirmation
File "openhands/sdk/conversation/impl/local_conversation.py", line 245, in run
File "openhands/sdk/agent/agent.py", line 226, in step
File "openhands/sdk/agent/agent.py", line 353, in _get_action_event
RuntimeError: LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!
[PYI-88958:ERROR] Failed to execute script 'simple_main' due to unhandled exception!
alonaking@MacBook-Pro-82 All-Hands %adamant-controller-19704
10/13/2025, 5:15 AMquick-window-91705
10/13/2025, 11:50 AMquick-window-91705
10/13/2025, 12:56 PMsecurity_risk field, the agent can still pass it as an argument and we see this runtime error before the tool arguments are validated by pydantic?
Specifically for the area in the PR linked below, it seems we pop the raw arguments and validate security risk against the security analyzer (which is set to None appropriately)
https://github.com/All-Hands-AI/agent-sdk/pull/723/filesquick-window-91705
10/13/2025, 1:01 PMsecurity_risk anyways even when confirmation mode is disabled - i'll clean up this patch but it seems like a reasonable workaround for now lmkchilly-france-44439
10/13/2025, 1:43 PMthe system prompt is set exactly once (with security analyzer descriptions)I think this was also my assumption -- although it just run into a very weird scenario: it is start with LLM-Risk analyzer, and then at some point it turns into a "confirm on every action", and then it throws the same "LLM provided a security_risk but no security analyzer is configured - THIS SHOULD NOT HAPPEN!" error
chilly-france-44439
10/13/2025, 1:49 PMchilly-france-44439
10/13/2025, 2:03 PMquick-window-91705
10/13/2025, 2:05 PMchilly-france-44439
10/13/2025, 2:07 PMquick-window-91705
10/13/2025, 2:08 PMchilly-france-44439
10/13/2025, 2:08 PMNeverConfirm on the base statechilly-france-44439
10/13/2025, 2:08 PMchilly-france-44439
10/13/2025, 2:09 PMquick-window-91705
10/13/2025, 2:09 PM