MCPcopy Create free account
hub / github.com/anthropics/anthropic-sdk-python / echo

Function echo

tests/lib/tools/toolsets/test_refusals.py:136–137  ·  view source on GitHub ↗
(context: BetaURLContext, url: str)

Source from the content-addressed store, hash-verified

134
135def test_a_hook_refusal_is_cut_to_the_field_limit_and_stays_the_cause() -> None:
136 def echo(context: BetaURLContext, url: str) -> None:
137 raise ToolError(f"blocked: {url}")
138
139 def refuse(context: BetaConfirmContext) -> bool:
140 raise ToolError("declined: " + "c" * 5000)

Callers

nothing calls this directly

Calls 1

ToolErrorClass · 0.90

Tested by

no test coverage detected