SYMBOL INDEX (10864 symbols across 869 files) FILE: .agents/skills/manage-evals/scripts/manage_evals.py function fetch_json (line 51) | def fetch_json(url: str) -> dict[str, Any] | None: function fetch_text (line 66) | def fetch_text(url: str) -> str | None: function parse_run_path (line 81) | def parse_run_path(path: str) -> tuple[str, str, str]: function get_report (line 96) | def get_report(run_path: str) -> dict[str, Any] | None: function get_params (line 102) | def get_params(run_path: str) -> dict[str, Any] | None: function get_metadata_for_date (line 108) | def get_metadata_for_date(date_str: str) -> list[str]: function find_baseline_run (line 117) | def find_baseline_run( function compute_diff (line 173) | def compute_diff( function github_api_request (line 324) | def github_api_request( function post_github_comment (line 349) | def post_github_comment(repo: str, pr_number: int, body: str, token: str... function trigger_eval (line 357) | def trigger_eval( function _require_token (line 415) | def _require_token() -> str: function cmd_trigger (line 424) | def cmd_trigger(args: argparse.Namespace) -> None: function cmd_compare (line 443) | def cmd_compare(args: argparse.Namespace) -> None: function main (line 511) | def main() -> None: FILE: .github/run-eval/resolve_model_config.py function _sigterm_handler (line 23) | def _sigterm_handler(signum: int, _frame: object) -> None: function error_exit (line 343) | def error_exit(msg: str, exit_code: int = 1) -> None: function get_required_env (line 349) | def get_required_env(key: str) -> str: function find_models_by_id (line 357) | def find_models_by_id(model_ids: list[str]) -> list[dict]: function check_model (line 380) | def check_model( function _check_proxy_reachable (line 465) | def _check_proxy_reachable( function run_preflight_check (line 490) | def run_preflight_check(models: list[dict[str, Any]]) -> bool: function main (line 551) | def main() -> None: FILE: .github/run-eval/validate_sdk_ref.py function is_semantic_version (line 36) | def is_semantic_version(ref: str) -> bool: function is_commit_sha (line 41) | def is_commit_sha(ref: str) -> bool: function is_valid_branch_name (line 46) | def is_valid_branch_name(ref: str) -> bool: function validate_branch_name (line 59) | def validate_branch_name(branch_name: str, input_name: str) -> tuple[boo... function validate_sdk_ref (line 70) | def validate_sdk_ref(sdk_ref: str, allow_unreleased: bool) -> tuple[bool... function main (line 92) | def main() -> None: FILE: .github/scripts/check_agent_server_rest_api_breakage.py function _read_version_from_pyproject (line 103) | def _read_version_from_pyproject(pyproject: Path) -> str: function _fetch_pypi_metadata (line 113) | def _fetch_pypi_metadata(distribution: str) -> dict: function _get_baseline_version (line 123) | def _get_baseline_version(distribution: str, current: str) -> str | None: function _generate_openapi_from_source_tree (line 148) | def _generate_openapi_from_source_tree(source_tree: Path, label: str) ->... function _generate_current_openapi (line 174) | def _generate_current_openapi() -> dict | None: function _generate_openapi_for_git_ref (line 178) | def _generate_openapi_for_git_ref(git_ref: str) -> dict | None: function _dotted_name (line 206) | def _dotted_name(node: ast.AST) -> str | None: function _find_sdk_deprecated_fastapi_routes_in_file (line 217) | def _find_sdk_deprecated_fastapi_routes_in_file( function _find_sdk_deprecated_fastapi_routes (line 286) | def _find_sdk_deprecated_fastapi_routes(repo_root: Path) -> list[str]: function _filter_public_rest_openapi (line 296) | def _filter_public_rest_openapi(schema: dict) -> dict: function _find_deprecation_policy_errors (line 307) | def _find_deprecation_policy_errors(schema: dict) -> list[str]: function _parse_openapi_deprecation_description (line 333) | def _parse_openapi_deprecation_description( function _version_ge (line 353) | def _version_ge(current: str, target: str) -> bool: function _get_openapi_operation (line 362) | def _get_openapi_operation(schema: dict, path: str, method: str) -> dict... function _validate_removed_operations (line 374) | def _validate_removed_operations( function _iter_schema_properties (line 434) | def _iter_schema_properties(schema: dict): function _removed_property_name (line 453) | def _removed_property_name(change: dict) -> str | None: function _validate_removed_schema_properties (line 464) | def _validate_removed_schema_properties( function _is_union_property_removal_artifact (line 560) | def _is_union_property_removal_artifact(change: dict) -> bool: function _is_union_type_change_artifact (line 577) | def _is_union_type_change_artifact(change: dict) -> bool: function _split_breaking_changes (line 582) | def _split_breaking_changes( function _normalize_openapi_for_oasdiff (line 623) | def _normalize_openapi_for_oasdiff(schema: dict) -> dict: function _run_oasdiff_breakage_check (line 665) | def _run_oasdiff_breakage_check( function main (line 704) | def main() -> int: FILE: .github/scripts/check_deprecations.py class PackageConfig (line 48) | class PackageConfig: class DeprecationRecord (line 81) | class DeprecationRecord: function _load_current_version (line 91) | def _load_current_version(pyproject: Path) -> str: function _iter_python_files (line 101) | def _iter_python_files(root: Path) -> Iterator[Path]: function _parse_removed_value (line 108) | def _parse_removed_value( function _parse_deprecated_value (line 175) | def _parse_deprecated_value( function _safe_int_literal (line 197) | def _safe_int_literal(node: ast.AST) -> int: function _extract_kw (line 205) | def _extract_kw(call: ast.Call, name: str) -> ast.AST | None: function _extract_string_literal (line 212) | def _extract_string_literal(node: ast.AST | None) -> str | None: function _extract_string_sequence (line 218) | def _extract_string_sequence(node: ast.AST | None) -> tuple[str, ...] | ... function _extract_route_details (line 231) | def _extract_route_details(call: ast.Call) -> tuple[tuple[str, str], ...]: function _parse_rest_route_deprecation_docstring (line 258) | def _parse_rest_route_deprecation_docstring( function _gather_rest_route_deprecations (line 285) | def _gather_rest_route_deprecations( function _gather_decorators (line 328) | def _gather_decorators( function _gather_warn_calls (line 370) | def _gather_warn_calls( function _build_identifier (line 428) | def _build_identifier(node: ast.AST) -> str: function _attach_parents (line 441) | def _attach_parents(tree: ast.AST) -> None: function _collect_records (line 447) | def _collect_records(files: Iterable[Path], *, package: str) -> list[Dep... function _collect_rest_route_records (line 457) | def _collect_rest_route_records( function _version_ge (line 467) | def _version_ge(current: str, target: str) -> bool: function _should_fail (line 476) | def _should_fail(current_version: str, record: DeprecationRecord) -> bool: function _format_record (line 494) | def _format_record(record: DeprecationRecord) -> str: function main (line 516) | def main(argv: Sequence[str] | None = None) -> int: FILE: .github/scripts/check_docstrings.py class Violation (line 46) | class Violation: function should_skip (line 57) | def should_skip(path: Path) -> bool: function check_repl_examples (line 63) | def check_repl_examples( function check_unfenced_shell_config (line 94) | def check_unfenced_shell_config( function check_docstring (line 148) | def check_docstring( function get_docstrings_from_file (line 161) | def get_docstrings_from_file(file: Path) -> list[tuple[str, str, int]]: function is_strict_file (line 199) | def is_strict_file(file: Path, repo_root: Path) -> bool: function check_file (line 208) | def check_file(file: Path, repo_root: Path) -> list[Violation]: function main (line 222) | def main() -> int: FILE: .github/scripts/check_documented_examples.py function find_documented_examples (line 18) | def find_documented_examples(docs_path: Path) -> set[str]: function find_agent_sdk_examples (line 53) | def find_agent_sdk_examples(agent_sdk_path: Path) -> set[str]: function resolve_paths (line 98) | def resolve_paths() -> tuple[Path, Path]: function main (line 149) | def main() -> None: FILE: .github/scripts/check_duplicate_example_numbers.py function find_duplicate_numbers (line 19) | def find_duplicate_numbers(examples_dir: Path) -> dict[str, list[str]]: function main (line 67) | def main() -> None: FILE: .github/scripts/check_sdk_api_breakage.py class PackageConfig (line 49) | class PackageConfig: class DeprecationMetadata (line 58) | class DeprecationMetadata: class DeprecatedSymbols (line 64) | class DeprecatedSymbols: function read_version_from_pyproject (line 104) | def read_version_from_pyproject(path: str) -> str: function _read_pyproject (line 115) | def _read_pyproject(path: str) -> dict: function _bool_env (line 120) | def _bool_env(name: str) -> bool: function _get_dependency_spec (line 125) | def _get_dependency_spec(project_data: dict, dependency: str) -> str | N... function _min_version_from_requirement (line 133) | def _min_version_from_requirement(req_str: str) -> pkg_version.Version |... function _git_show_file (line 160) | def _git_show_file(ref: str, rel_path: str) -> str | None: function _load_base_pyproject (line 173) | def _load_base_pyproject(base_ref: str) -> dict | None: function _check_acp_version_bump (line 192) | def _check_acp_version_bump(repo_root: str) -> int: function _parse_version (line 249) | def _parse_version(v: str) -> pkg_version.Version: function _parse_string_kwarg (line 254) | def _parse_string_kwarg(call: ast.Call, name: str) -> str | None: function _minimum_removed_in (line 265) | def _minimum_removed_in(deprecated_in: str) -> str: function _deprecation_schedule_errors (line 270) | def _deprecation_schedule_errors( function get_pypi_baseline_version (line 319) | def get_pypi_baseline_version(pkg: str, current: str | None) -> str | None: function ensure_griffe (line 367) | def ensure_griffe() -> None: function _escape_newlines_in_string_literals (line 389) | def _escape_newlines_in_string_literals(text: str) -> str: function _parse_field_call (line 426) | def _parse_field_call(value: object) -> ast.Call | None: function _filter_field_metadata_kwargs (line 453) | def _filter_field_metadata_kwargs(call: ast.Call) -> ast.Call: function _is_field_metadata_only_change (line 462) | def _is_field_metadata_only_change(old_val: object, new_val: object) -> ... function _member_deprecation_metadata (line 486) | def _member_deprecation_metadata( function _was_deprecated (line 515) | def _was_deprecated( function _collect_breakages_pairs (line 523) | def _collect_breakages_pairs( function _extract_exported_names (line 616) | def _extract_exported_names(module) -> set[str]: function _check_version_bump (line 656) | def _check_version_bump(prev: str, new_version: str, total_breaks: int) ... function _resolve_griffe_object (line 691) | def _resolve_griffe_object( function _load_current (line 725) | def _load_current( function _load_prev_from_pypi (line 741) | def _load_prev_from_pypi( function _find_deprecated_symbols (line 763) | def _find_deprecated_symbols(source_root: Path) -> DeprecatedSymbols: function _extract_string_literal (line 884) | def _extract_string_literal(node: ast.AST) -> str | None: function _get_source_root (line 891) | def _get_source_root(griffe_root: object) -> Path | None: function _compute_breakages (line 899) | def _compute_breakages( function _check_package (line 990) | def _check_package(griffe_module, repo_root: str, cfg: PackageConfig) ->... function main (line 1036) | def main() -> int: FILE: .github/scripts/check_version_bumps.py class VersionChange (line 27) | class VersionChange: function _read_version_from_pyproject_text (line 34) | def _read_version_from_pyproject_text(text: str, source: str) -> str: function _read_current_version (line 42) | def _read_current_version(repo_root: Path, pyproject: Path) -> str: function _read_version_from_git_ref (line 49) | def _read_version_from_git_ref(repo_root: Path, git_ref: str, pyproject:... function _base_ref_candidates (line 65) | def _base_ref_candidates(base_ref: str) -> list[str]: function find_version_changes (line 71) | def find_version_changes(repo_root: Path, base_ref: str) -> list[Version... function get_release_pr_version (line 106) | def get_release_pr_version( function validate_version_changes (line 123) | def validate_version_changes( function main (line 163) | def main() -> int: FILE: .github/scripts/update_sdk_ref_default.py function update_sdk_ref_default (line 26) | def update_sdk_ref_default(new_version: str, dry_run: bool = False) -> b... function main (line 92) | def main() -> int: FILE: examples/01_standalone_sdk/02_custom_tools.py class GrepAction (line 40) | class GrepAction(Action): class GrepObservation (line 50) | class GrepObservation(Observation): method to_llm_content (line 56) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class GrepExecutor (line 73) | class GrepExecutor(ToolExecutor[GrepAction, GrepObservation]): method __init__ (line 74) | def __init__(self, terminal: TerminalExecutor): method __call__ (line 77) | def __call__(self, action: GrepAction, conversation=None) -> GrepObser... class GrepTool (line 123) | class GrepTool(ToolDefinition[GrepAction, GrepObservation]): method create (line 127) | def create( class BashAndGrepToolSet (line 172) | class BashAndGrepToolSet(ToolDefinition[Action, Observation]): method create (line 176) | def create(cls, conv_state, **params) -> Sequence[ToolDefinition]: function conversation_callback (line 203) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/03_activate_skill.py function conversation_callback (line 101) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/04_confirmation_mode_example.py function _print_action_preview (line 23) | def _print_action_preview(pending_actions) -> None: function confirm_in_console (line 30) | def confirm_in_console(pending_actions) -> bool: function run_until_finished (line 56) | def run_until_finished(conversation: BaseConversation, confirmer: Callab... FILE: examples/01_standalone_sdk/05_use_llm_registry.py function conversation_callback (line 53) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/06_interactive_terminal_w_reasoning.py function conversation_callback (line 46) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/07_mcp_integration.py function conversation_callback (line 58) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/08_mcp_with_oauth.py function conversation_callback (line 48) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/10_persistence.py function conversation_callback (line 52) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/11_async.py function callback_coro (line 59) | async def callback_coro(event: Event): function run_conversation (line 65) | def run_conversation(callback: ConversationCallbackType): function main (line 78) | async def main(): FILE: examples/01_standalone_sdk/12_custom_secrets.py class MySecretSource (line 39) | class MySecretSource(SecretSource): method get_value (line 40) | def get_value(self) -> str: FILE: examples/01_standalone_sdk/13_get_llm_metrics.py function conversation_callback (line 47) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/14_context_condenser.py function conversation_callback (line 66) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/15_browser_use.py function conversation_callback (line 53) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/16_llm_security_analyzer.py function _print_blocked_actions (line 29) | def _print_blocked_actions(pending_actions) -> None: function confirm_high_risk_in_console (line 36) | def confirm_high_risk_in_console(pending_actions) -> bool: function run_until_finished_with_security (line 65) | def run_until_finished_with_security( FILE: examples/01_standalone_sdk/17_image_input.py function _make_png_data_url (line 38) | def _make_png_data_url(width: int, height: int, color: str = "red") -> str: function conversation_callback (line 76) | def conversation_callback(event: Event) -> None: FILE: examples/01_standalone_sdk/18_send_message_while_processing.py function timestamp (line 84) | def timestamp() -> str: FILE: examples/01_standalone_sdk/19_llm_routing.py function conversation_callback (line 54) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/20_stuck_detector.py function conversation_callback (line 34) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/22_anthropic_thinking.py function show_thinking (line 38) | def show_thinking(event: Event): FILE: examples/01_standalone_sdk/23_responses_reasoning.py function conversation_callback (line 52) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/24_planning_agent_workflow.py function get_event_content (line 25) | def get_event_content(event): FILE: examples/01_standalone_sdk/25_agent_delegation.py function create_lodging_planner (line 41) | def create_lodging_planner(llm: LLM) -> Agent: function create_activities_planner (line 65) | def create_activities_planner(llm: LLM) -> Agent: FILE: examples/01_standalone_sdk/26_custom_visualizer.py class MinimalVisualizer (line 26) | class MinimalVisualizer(ConversationVisualizerBase): method on_event (line 29) | def on_event(self, event: Event) -> None: FILE: examples/01_standalone_sdk/28_ask_agent_example.py class MinimalVisualizer (line 50) | class MinimalVisualizer(ConversationVisualizerBase): method on_event (line 55) | def on_event(self, event: Event) -> None: function timestamp (line 68) | def timestamp() -> str: FILE: examples/01_standalone_sdk/29_llm_streaming.py function on_token (line 42) | def on_token(chunk: ModelResponseStream) -> None: FILE: examples/01_standalone_sdk/31_iterative_refinement.py function setup_workspace (line 31) | def setup_workspace() -> tuple[Path, Path, Path]: function create_sample_cobol_files (line 45) | def create_sample_cobol_files(cobol_dir: Path) -> list[str]: function get_refactoring_prompt (line 240) | def get_refactoring_prompt( function get_critique_prompt (line 283) | def get_critique_prompt( function parse_critique_score (line 343) | def parse_critique_score(critique_file: Path) -> float: function run_iterative_refinement (line 365) | def run_iterative_refinement() -> None: FILE: examples/01_standalone_sdk/32_configurable_security_policy.py function conversation_callback (line 116) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/34_critic_example.py function get_required_env (line 41) | def get_required_env(name: str) -> str: function get_default_critic (line 51) | def get_default_critic(llm: LLM) -> CriticBase | None: FILE: examples/01_standalone_sdk/38_browser_session_recording.py function conversation_callback (line 62) | def conversation_callback(event: Event): FILE: examples/01_standalone_sdk/41_task_tool_set.py function create_animal_expert (line 31) | def create_animal_expert(llm: LLM) -> Agent: FILE: examples/01_standalone_sdk/43_mixed_marketplace_skills/main.py function main (line 47) | def main(): FILE: examples/01_standalone_sdk/45_parallel_tool_execution.py function create_code_analyst (line 42) | def create_code_analyst(llm: LLM) -> Agent: function create_doc_reviewer (line 68) | def create_doc_reviewer(llm: LLM) -> Agent: function create_dependency_checker (line 94) | def create_dependency_checker(llm: LLM) -> Agent: function _analyze_conversation (line 191) | def _analyze_conversation(events_dir: Path) -> dict[str, list[str]]: FILE: examples/02_remote_agent_server/01_convo_with_local_agent_server.py function _stream_output (line 23) | def _stream_output(stream, prefix, target_stream): class ManagedAPIServer (line 36) | class ManagedAPIServer: method __init__ (line 39) | def __init__(self, port: int = 8000, host: str = "127.0.0.1"): method __enter__ (line 47) | def __enter__(self): method __exit__ (line 111) | def __exit__(self, exc_type, exc_val, exc_tb): function event_callback (line 158) | def event_callback(event): function hook_event_tracker (line 210) | def hook_event_tracker(event): FILE: examples/02_remote_agent_server/02_convo_with_docker_sandboxed_server.py function detect_platform (line 31) | def detect_platform(): function get_server_image (line 39) | def get_server_image(): function event_callback (line 78) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/03_browser_use_with_docker_sandboxed_server.py function detect_platform (line 26) | def detect_platform(): function get_server_image (line 34) | def get_server_image(): function event_callback (line 75) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/04_convo_with_api_sandboxed_server.py function event_callback (line 64) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/05_vscode_with_docker_sandboxed_server.py function detect_platform (line 28) | def detect_platform(): function get_server_image (line 36) | def get_server_image(): function event_callback (line 68) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/06_custom_tool/custom_tools/log_data.py class LogLevel (line 30) | class LogLevel(StrEnum): class LogDataAction (line 39) | class LogDataAction(Action): class LogDataObservation (line 53) | class LogDataObservation(Observation): method to_llm_content (line 61) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class LogDataExecutor (line 81) | class LogDataExecutor(ToolExecutor[LogDataAction, LogDataObservation]): method __init__ (line 84) | def __init__(self, log_file: str = DEFAULT_LOG_FILE): method __call__ (line 92) | def __call__( class LogDataTool (line 154) | class LogDataTool(ToolDefinition[LogDataAction, LogDataObservation]): method create (line 158) | def create(cls, conv_state, **params) -> Sequence[ToolDefinition]: # ... FILE: examples/02_remote_agent_server/06_custom_tool/main.py function detect_platform (line 65) | def detect_platform(): function event_callback (line 150) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/07_convo_with_cloud_workspace.py function event_callback (line 66) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/08_convo_with_apptainer_sandboxed_server.py function detect_platform (line 31) | def detect_platform(): function get_server_image (line 39) | def get_server_image(): function event_callback (line 74) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/09_acp_agent_with_remote_runtime.py function event_callback (line 65) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/10_cloud_workspace_share_credentials.py function event_callback (line 72) | def event_callback(event) -> None: FILE: examples/02_remote_agent_server/11_conversation_fork.py function _stream_output (line 30) | def _stream_output(stream, prefix, target_stream): class ManagedAPIServer (line 42) | class ManagedAPIServer: method __init__ (line 45) | def __init__(self, port: int = 8000, host: str = "127.0.0.1"): method __enter__ (line 51) | def __enter__(self): method __exit__ (line 94) | def __exit__(self, *args): FILE: examples/02_remote_agent_server/12_settings_and_secrets_api.py function _stream_output (line 34) | def _stream_output(stream, prefix, target_stream): class ManagedAPIServer (line 47) | class ManagedAPIServer: method __init__ (line 50) | def __init__(self, port: int = 8000, host: str = "127.0.0.1"): method __enter__ (line 58) | def __enter__(self): method __exit__ (line 118) | def __exit__(self, exc_type, exc_val, exc_tb): FILE: examples/02_remote_agent_server/13_workspace_get_llm.py function _stream_output (line 40) | def _stream_output(stream, prefix, target_stream): class ManagedAPIServer (line 53) | class ManagedAPIServer: method __init__ (line 60) | def __init__(self, port: int = 8000, host: str = "127.0.0.1"): method __enter__ (line 70) | def __enter__(self): method __exit__ (line 132) | def __exit__(self, exc_type, exc_val, exc_tb): FILE: examples/03_github_workflows/01_basic_action/agent_script.py function is_url (line 41) | def is_url(path: str) -> bool: function load_prompt (line 50) | def load_prompt(prompt_location: str) -> str: function main (line 76) | def main(): FILE: examples/03_github_workflows/03_todo_management/agent_script.py function process_todo (line 38) | def process_todo(todo_data: dict): function main (line 99) | def main(): FILE: examples/03_github_workflows/03_todo_management/scanner.py function scan_file_for_todos (line 30) | def scan_file_for_todos( function scan_directory (line 120) | def scan_directory( function main (line 152) | def main(): FILE: examples/03_github_workflows/04_datadog_debugging/datadog_debugging.py function validate_environment (line 56) | def validate_environment(): function fetch_datadog_errors (line 80) | def fetch_datadog_errors( function create_unique_identifier (line 250) | def create_unique_identifier(query: str, errors_data: dict) -> str: function search_existing_issue (line 271) | def search_existing_issue( function create_github_issue (line 319) | def create_github_issue( function format_issue_body (line 369) | def format_issue_body( function setup_github_issue (line 455) | def setup_github_issue( function create_debugging_prompt (line 516) | def create_debugging_prompt( function main (line 543) | def main(): function run_debugging_session (line 655) | def run_debugging_session( FILE: examples/03_github_workflows/05_posthog_debugging/posthog_debugging.py function get_posthog_host (line 58) | def get_posthog_host() -> str: function _extract_issue_title (line 64) | def _extract_issue_title(examples: list[dict], query: str) -> str: function _fetch_event_timeline (line 125) | def _fetch_event_timeline( function validate_environment (line 214) | def validate_environment(): function fetch_posthog_events (line 238) | def fetch_posthog_events( function create_unique_identifier (line 457) | def create_unique_identifier(query: str, events_data: dict) -> str: function search_existing_issue (line 478) | def search_existing_issue( function create_github_issue (line 531) | def create_github_issue( function update_github_issue (line 581) | def update_github_issue( function _extract_exception_info (line 616) | def _extract_exception_info(properties: dict | str) -> dict | None: function _format_stack_trace (line 673) | def _format_stack_trace(stack_frames: list[dict]) -> str: function format_issue_body (line 698) | def format_issue_body( function setup_github_issue (line 825) | def setup_github_issue( function create_debugging_prompt (line 882) | def create_debugging_prompt( function main (line 910) | def main(): function run_debugging_session (line 1021) | def run_debugging_session( FILE: examples/05_skills_and_plugins/02_loading_plugins/main.py function print_state (line 51) | def print_state(label: str, installed_dir: Path) -> None: function demo_conversation_with_github_plugin (line 69) | def demo_conversation_with_github_plugin(llm: LLM) -> None: function demo_install_local_plugin (line 123) | def demo_install_local_plugin(installed_dir: Path) -> str: function demo_install_github_plugin (line 136) | def demo_install_github_plugin(installed_dir: Path) -> None: function demo_list_and_load_plugins (line 170) | def demo_list_and_load_plugins(installed_dir: Path) -> None: function demo_enable_disable_plugin (line 187) | def demo_enable_disable_plugin(installed_dir: Path, plugin_name: str) ->... function demo_uninstall_plugins (line 214) | def demo_uninstall_plugins(installed_dir: Path) -> None: FILE: examples/05_skills_and_plugins/03_managing_installed_skills/main.py function print_state (line 33) | def print_state(label: str, installed_dir: Path) -> None: function demo_install_skills (line 51) | def demo_install_skills(installed_dir: Path) -> list[str]: function demo_list_and_load_skills (line 70) | def demo_list_and_load_skills(installed_dir: Path) -> None: function demo_enable_disable_skill (line 90) | def demo_enable_disable_skill(installed_dir: Path, skill_name: str) -> N... function demo_uninstall_skill (line 117) | def demo_uninstall_skill( FILE: openhands-agent-server/openhands/agent_server/__main__.py function _get_internal_server_url (line 24) | def _get_internal_server_url(host: str, port: int) -> str: function extend_python_path (line 47) | def extend_python_path(extra_paths: str | None) -> None: function preload_modules (line 87) | def preload_modules(modules_arg: str | None) -> None: function check_browser (line 111) | def check_browser(): class LoggingServer (line 148) | class LoggingServer(uvicorn.Server): method handle_exit (line 156) | def handle_exit(self, sig: int, frame: FrameType | None) -> None: function _setup_crash_diagnostics (line 167) | def _setup_crash_diagnostics() -> None: function main (line 183) | def main() -> None: FILE: openhands-agent-server/openhands/agent_server/_secrets_exposure.py function get_config (line 20) | def get_config(request: Request): function get_cipher (line 31) | def get_cipher(request: Request) -> Cipher | None: function parse_expose_secrets_header (line 36) | def parse_expose_secrets_header(request: Request) -> ExposeSecretsMode |... function build_expose_context (line 64) | def build_expose_context( function _has_missing_cipher_cause (line 73) | def _has_missing_cipher_cause(exc: BaseException) -> bool: function decrypt_incoming_llm_secrets (line 84) | def decrypt_incoming_llm_secrets(llm: LLM, cipher: Cipher) -> LLM: function translate_missing_cipher (line 109) | def translate_missing_cipher() -> Iterator[None]: FILE: openhands-agent-server/openhands/agent_server/api.py function _default_server_tmux_tmpdir (line 64) | def _default_server_tmux_tmpdir() -> Path: function _ensure_server_tmux_tmpdir (line 68) | def _ensure_server_tmux_tmpdir() -> tuple[Path, bool]: function _cleanup_stale_tmux_sessions (line 83) | def _cleanup_stale_tmux_sessions() -> None: function api_lifespan (line 114) | async def api_lifespan(api: FastAPI) -> AsyncIterator[None]: function _get_root_path (line 219) | def _get_root_path(config: Config) -> str: function _create_fastapi_instance (line 227) | def _create_fastapi_instance(config: Config) -> FastAPI: function _find_http_exception (line 243) | def _find_http_exception(exc: BaseExceptionGroup) -> HTTPException | None: function _add_api_routes (line 263) | def _add_api_routes(app: FastAPI, config: Config) -> None: function _setup_static_files (line 316) | def _setup_static_files(app: FastAPI, config: Config) -> None: function _sanitize_validation_errors (line 354) | def _sanitize_validation_errors(errors: Sequence[Any]) -> list[dict]: function _add_exception_handlers (line 377) | def _add_exception_handlers(api: FastAPI) -> None: function create_app (line 502) | def create_app(config: Config | None = None) -> FastAPI: FILE: openhands-agent-server/openhands/agent_server/auth_router.py function _request_is_secure_context (line 44) | def _request_is_secure_context(request: Request) -> bool: function _set_workspace_cookie (line 69) | def _set_workspace_cookie( function _append_partitioned_to_last_set_cookie (line 104) | def _append_partitioned_to_last_set_cookie(response: Response) -> None: function create_workspace_session (line 130) | async def create_workspace_session(request: Request, response: Response)... function delete_workspace_session (line 154) | async def delete_workspace_session(request: Request, response: Response)... FILE: openhands-agent-server/openhands/agent_server/bash_router.py function search_bash_events (line 34) | async def search_bash_events( function get_bash_event (line 76) | async def get_bash_event(event_id: str) -> BashEventBase: function batch_get_bash_events (line 85) | async def batch_get_bash_events( function start_bash_command (line 95) | async def start_bash_command(request: ExecuteBashRequest) -> BashCommand: function execute_bash_command (line 103) | async def execute_bash_command(request: ExecuteBashRequest) -> BashOutput: function clear_all_bash_events (line 114) | async def clear_all_bash_events() -> dict[str, int]: FILE: openhands-agent-server/openhands/agent_server/bash_service.py class BashEventService (line 29) | class BashEventService: method _ensure_bash_events_dir (line 39) | def _ensure_bash_events_dir(self) -> None: method _timestamp_to_str (line 43) | def _timestamp_to_str(self, timestamp: datetime) -> str: method _get_event_filename (line 47) | def _get_event_filename(self, event: BashEventBase) -> str: method _save_event_to_file (line 56) | def _save_event_to_file(self, event: BashEventBase) -> None: method _load_event_from_file (line 67) | def _load_event_from_file(self, filepath: Path) -> BashEventBase | None: method _get_event_files_by_pattern (line 76) | def _get_event_files_by_pattern(self, pattern: str) -> list[Path]: method get_bash_event (line 82) | async def get_bash_event(self, event_id: str) -> BashEventBase | None: method batch_get_bash_events (line 94) | async def batch_get_bash_events( method search_bash_events (line 104) | async def search_bash_events( method _signal_process_group (line 184) | def _signal_process_group( method start_bash_command (line 200) | async def start_bash_command( method _execute_bash_command (line 213) | async def _execute_bash_command(self, command: BashCommand) -> None: method subscribe_to_events (line 347) | async def subscribe_to_events(self, subscriber: Subscriber[BashEventBa... method unsubscribe_from_events (line 354) | async def unsubscribe_from_events(self, subscriber_id: UUID) -> bool: method clear_all_events (line 357) | async def clear_all_events(self) -> int: method close (line 381) | async def close(self): method __aenter__ (line 385) | async def __aenter__(self): method __aexit__ (line 390) | async def __aexit__(self, exc_type, exc_value, traceback): function get_default_bash_event_service (line 398) | def get_default_bash_event_service() -> BashEventService: FILE: openhands-agent-server/openhands/agent_server/cloud_proxy_router.py class CloudProxyRequest (line 38) | class CloudProxyRequest(BaseModel): function _allowed_hosts (line 60) | def _allowed_hosts() -> tuple[str, ...]: function _is_blocked_ip_literal (line 68) | def _is_blocked_ip_literal(hostname: str) -> bool: function _is_host_allowed (line 90) | def _is_host_allowed(host_url: str) -> bool: function _filtered_response_headers (line 135) | def _filtered_response_headers(upstream: httpx.Response) -> dict[str, str]: function _forward_upstream (line 143) | async def _forward_upstream( function cloud_proxy (line 167) | async def cloud_proxy(req: CloudProxyRequest) -> Response: FILE: openhands-agent-server/openhands/agent_server/config.py function _default_session_api_keys (line 19) | def _default_session_api_keys(): function _default_secret_key (line 33) | def _default_secret_key() -> SecretStr | None: function _default_web_url (line 49) | def _default_web_url() -> str | None: class WebhookSpec (line 57) | class WebhookSpec(BaseModel): class Config (line 103) | class Config(BaseModel): method cipher (line 203) | def cipher(self) -> Cipher | None: function get_default_config (line 221) | def get_default_config() -> Config: FILE: openhands-agent-server/openhands/agent_server/conversation_lease.py class LeaseClaim (line 24) | class LeaseClaim: class LeasePayload (line 29) | class LeasePayload(TypedDict): function _current_host (line 40) | def _current_host() -> str: function _is_pid_alive (line 47) | def _is_pid_alive(pid: int) -> bool: class ConversationLeaseHeldError (line 71) | class ConversationLeaseHeldError(RuntimeError): method __init__ (line 72) | def __init__( class ConversationOwnershipLostError (line 87) | class ConversationOwnershipLostError(RuntimeError): method __init__ (line 88) | def __init__( class ConversationLease (line 101) | class ConversationLease: method __init__ (line 109) | def __init__( method claim (line 122) | def claim(self) -> LeaseClaim: method _owner_is_dead (line 166) | def _owner_is_dead(self, payload: LeasePayload) -> bool: method renew (line 187) | def renew(self, generation: int) -> None: method guarded_write (line 197) | def guarded_write(self, generation: int) -> Iterator[None]: method release (line 203) | def release(self, generation: int) -> None: method _assert_owner_locked (line 216) | def _assert_owner_locked(self, generation: int) -> None: method _read_payload (line 234) | def _read_payload(self) -> LeasePayload | None: method _write_payload (line 271) | def _write_payload(self, *, generation: int, expires_at: float) -> None: FILE: openhands-agent-server/openhands/agent_server/conversation_router.py function search_conversations (line 72) | async def search_conversations( function count_conversations (line 100) | async def count_conversations( function get_conversation (line 115) | async def get_conversation( function get_conversation_agent_final_response (line 130) | async def get_conversation_agent_final_response( function batch_get_conversations (line 148) | async def batch_get_conversations( function start_conversation (line 163) | async def start_conversation( function pause_conversation (line 179) | async def pause_conversation( function delete_conversation (line 193) | async def delete_conversation( function run_conversation (line 211) | async def run_conversation( function update_conversation_secrets (line 238) | async def update_conversation_secrets( function set_conversation_confirmation_policy (line 261) | async def set_conversation_confirmation_policy( function set_conversation_security_analyzer (line 278) | async def set_conversation_security_analyzer( function switch_conversation_profile (line 298) | async def switch_conversation_profile( function switch_conversation_llm (line 327) | async def switch_conversation_llm( function update_conversation (line 352) | async def update_conversation( function ask_agent (line 371) | async def ask_agent( function condense_conversation (line 387) | async def condense_conversation( function fork_conversation (line 407) | async def fork_conversation( FILE: openhands-agent-server/openhands/agent_server/conversation_router_acp.py function search_acp_conversations (line 62) | async def search_acp_conversations( function count_acp_conversations (line 94) | async def count_acp_conversations( function get_acp_conversation (line 114) | async def get_acp_conversation( function batch_get_acp_conversations (line 130) | async def batch_get_acp_conversations( function start_acp_conversation (line 144) | async def start_acp_conversation( FILE: openhands-agent-server/openhands/agent_server/conversation_service.py function _build_worktree_guidance (line 55) | def _build_worktree_guidance( function _append_worktree_guidance (line 74) | def _append_worktree_guidance( function _has_git_remote (line 95) | def _has_git_remote(repo_root: Path, remote: str = "origin") -> bool: function _local_branch_exists (line 103) | def _local_branch_exists(repo_root: Path, branch: str) -> bool: function _get_worktree_start_point (line 114) | def _get_worktree_start_point(repo_root: Path) -> str: function _create_conversation_worktree (line 157) | def _create_conversation_worktree( function _prepare_request_workspace (line 216) | def _prepare_request_workspace( function _compose_conversation_info (line 242) | def _compose_conversation_info( function _compose_webhook_conversation_info (line 257) | def _compose_webhook_conversation_info( function _update_state_tags_sync (line 263) | def _update_state_tags_sync( function _compose_webhook_conversation_info_sync (line 271) | def _compose_webhook_conversation_info_sync( function _register_agent_definitions (line 278) | def _register_agent_definitions( class ConversationService (line 314) | class ConversationService: method get_conversation (line 333) | async def get_conversation(self, conversation_id: UUID) -> Conversatio... method get_acp_conversation (line 342) | async def get_acp_conversation( method search_conversations (line 353) | async def search_conversations( method search_acp_conversations (line 371) | async def search_acp_conversations( method _search_conversations (line 389) | async def _search_conversations( method count_conversations (line 446) | async def count_conversations( method _count_conversations (line 452) | async def _count_conversations( method batch_get_conversations (line 475) | async def batch_get_conversations( method batch_get_acp_conversations (line 488) | async def batch_get_acp_conversations( method _notify_conversation_webhooks (line 499) | async def _notify_conversation_webhooks(self, conversation_info: BaseM... method start_conversation (line 531) | async def start_conversation( method start_acp_conversation (line 536) | async def start_acp_conversation( method _start_conversation (line 541) | async def _start_conversation( method pause_conversation (line 638) | async def pause_conversation(self, conversation_id: UUID) -> bool: method resume_conversation (line 652) | async def resume_conversation(self, conversation_id: UUID) -> bool: method delete_conversation (line 660) | async def delete_conversation(self, conversation_id: UUID) -> bool: method update_conversation (line 701) | async def update_conversation( method get_event_service (line 754) | async def get_event_service(self, conversation_id: UUID) -> EventServi... method generate_conversation_title (line 759) | async def generate_conversation_title( method ask_agent (line 773) | async def ask_agent(self, conversation_id: UUID, question: str) -> str... method condense (line 785) | async def condense(self, conversation_id: UUID) -> bool: method fork_conversation (line 797) | async def fork_conversation( method __aenter__ (line 864) | async def __aenter__(self): method _renew_all_leases_loop (line 947) | async def _renew_all_leases_loop(self) -> None: method __aexit__ (line 966) | async def __aexit__(self, exc_type, exc_value, traceback): method get_instance (line 989) | def get_instance(cls, config: Config) -> "ConversationService": method _start_event_service (line 1000) | async def _start_event_service(self, stored: StoredConversation) -> Ev... class _EventSubscriber (line 1054) | class _EventSubscriber(Subscriber): method __call__ (line 1057) | async def __call__(self, _event: Event): class AutoTitleSubscriber (line 1069) | class AutoTitleSubscriber(Subscriber): method __call__ (line 1072) | async def __call__(self, event: Event) -> None: method _load_title_llm (line 1118) | def _load_title_llm(self) -> LLM | None: class WebhookSubscriber (line 1144) | class WebhookSubscriber(Subscriber): method __call__ (line 1152) | async def __call__(self, event: Event): method close (line 1163) | async def close(self): method _post_events (line 1171) | async def _post_events(self): method _cancel_flush_timer (line 1231) | def _cancel_flush_timer(self): method _flush_after_delay (line 1237) | async def _flush_after_delay(self): class ConversationWebhookSubscriber (line 1252) | class ConversationWebhookSubscriber: method post_conversation_info (line 1258) | async def post_conversation_info(self, conversation_info: BaseModel): function get_default_conversation_service (line 1310) | def get_default_conversation_service() -> ConversationService: FILE: openhands-agent-server/openhands/agent_server/dependencies.py function create_session_api_key_dependency (line 23) | def create_session_api_key_dependency(config: Config): function create_workspace_session_dependency (line 38) | def create_workspace_session_dependency(config: Config): function get_conversation_service (line 64) | def get_conversation_service(request: Request): function get_event_service (line 80) | async def get_event_service( FILE: openhands-agent-server/openhands/agent_server/desktop_router.py class DesktopUrlResponse (line 15) | class DesktopUrlResponse(BaseModel): function get_desktop_url (line 22) | async def get_desktop_url( FILE: openhands-agent-server/openhands/agent_server/desktop_service.py class DesktopService (line 18) | class DesktopService: method __init__ (line 21) | def __init__(self): method start (line 25) | async def start(self) -> bool: method stop (line 162) | async def stop(self) -> None: method is_running (line 178) | def is_running(self) -> bool: method get_vnc_url (line 196) | def get_vnc_url(self, base: str = "http://localhost:8003") -> str | None: function get_desktop_service (line 208) | def get_desktop_service() -> DesktopService | None: FILE: openhands-agent-server/openhands/agent_server/docker/build.py function _default_sdk_project_root (line 61) | def _default_sdk_project_root() -> Path: function _run (line 160) | def _run( function _sanitize_branch (line 219) | def _sanitize_branch(ref: str) -> str: function _sanitize_ref_tag (line 224) | def _sanitize_ref_tag(ref_name: str) -> str: function _release_tag_aliases (line 230) | def _release_tag_aliases(version: str) -> list[str]: function _truncate_ident (line 250) | def _truncate_ident(repo: str, tag: str, budget: int) -> str: function _base_slug (line 276) | def _base_slug(image: str, max_len: int = 64) -> str: function _git_info (line 315) | def _git_info() -> tuple[str, str]: function _package_version (line 352) | def _package_version() -> str: class BuildOptions (line 378) | class BuildOptions(BaseModel): method short_sha (line 438) | def short_sha(self) -> str: method long_sha (line 442) | def long_sha(self) -> str: method _valid_target (line 447) | def _valid_target(cls, v: str) -> str: method custom_tag_list (line 453) | def custom_tag_list(self) -> list[str]: method base_image_slug (line 457) | def base_image_slug(self) -> str: method branch_tag (line 461) | def branch_tag(self) -> str | None: method release_tag_source (line 474) | def release_tag_source(self) -> str | None: method versioned_tags (line 491) | def versioned_tags(self) -> list[str]: method base_tag (line 502) | def base_tag(self) -> str: method cache_tags (line 506) | def cache_tags(self) -> tuple[str, str]: method all_tags (line 516) | def all_tags(self) -> list[str]: class BuildTelemetry (line 542) | class BuildTelemetry(BaseModel): class BuildResult (line 555) | class BuildResult(BaseModel): class BuildCommandError (line 560) | class BuildCommandError(subprocess.CalledProcessError): method __init__ (line 561) | def __init__( function _extract_tarball (line 577) | def _extract_tarball(tarball: Path, dest: Path) -> None: function _make_build_context (line 591) | def _make_build_context( function _active_buildx_driver (line 641) | def _active_buildx_driver() -> str | None: function _default_local_cache_dir (line 653) | def _default_local_cache_dir() -> Path: function _get_dockerfile_path (line 662) | def _get_dockerfile_path(sdk_project_root: Path) -> Path: function _round_seconds (line 676) | def _round_seconds(value: float) -> float: function _classify_buildkit_description (line 680) | def _classify_buildkit_description(description: str) -> str | None: function _add_buildkit_duration (line 699) | def _add_buildkit_duration( function _parse_buildkit_telemetry (line 715) | def _parse_buildkit_telemetry(stderr: str) -> BuildTelemetry: function build_with_telemetry (line 798) | def build_with_telemetry(opts: BuildOptions) -> BuildResult: function build (line 965) | def build(opts: BuildOptions) -> list[str]: function _env (line 973) | def _env(name: str, default: str) -> str: function main (line 978) | def main(argv: list[str]) -> int: FILE: openhands-agent-server/openhands/agent_server/env_parser.py class MissingType (line 28) | class MissingType: class EnvParser (line 36) | class EnvParser(ABC): method from_env (line 40) | def from_env(self, key: str) -> JsonType: method to_env (line 43) | def to_env(self, key: str, value: Any, output: IO): class BoolEnvParser (line 50) | class BoolEnvParser(EnvParser): method from_env (line 51) | def from_env(self, key: str) -> bool | MissingType: method to_env (line 56) | def to_env(self, key: str, value: Any, output: IO): class IntEnvParser (line 60) | class IntEnvParser(EnvParser): method from_env (line 61) | def from_env(self, key: str) -> int | MissingType: class FloatEnvParser (line 67) | class FloatEnvParser(EnvParser): method from_env (line 68) | def from_env(self, key: str) -> float | MissingType: class StrEnvParser (line 74) | class StrEnvParser(EnvParser): method from_env (line 75) | def from_env(self, key: str) -> str | MissingType: class NoneEnvParser (line 81) | class NoneEnvParser(EnvParser): method from_env (line 82) | def from_env(self, key: str) -> None | MissingType: method to_env (line 89) | def to_env(self, key: str, value: Any, output: IO): class LiteralEnvParser (line 95) | class LiteralEnvParser(EnvParser): method from_env (line 98) | def from_env(self, key: str) -> str | MissingType: method to_env (line 104) | def to_env(self, key: str, value: Any, output: IO): class ModelEnvParser (line 114) | class ModelEnvParser(EnvParser): method from_env (line 118) | def from_env(self, key: str) -> dict | MissingType: method to_env (line 151) | def to_env(self, key: str, value: Any, output: IO): class DictEnvParser (line 165) | class DictEnvParser(EnvParser): method from_env (line 166) | def from_env(self, key: str) -> dict | MissingType: class ListEnvParser (line 179) | class ListEnvParser(EnvParser): method from_env (line 183) | def from_env(self, key: str) -> list | MissingType: method to_env (line 219) | def to_env(self, key: str, value: Any, output: IO): class UnionEnvParser (line 242) | class UnionEnvParser(EnvParser): method from_env (line 245) | def from_env(self, key: str) -> JsonType: method to_env (line 252) | def to_env(self, key: str, value: Any, output: IO): class DiscriminatedUnionEnvParser (line 276) | class DiscriminatedUnionEnvParser(EnvParser): method from_env (line 279) | def from_env(self, key: str) -> JsonType: method _import_and_register_class (line 313) | def _import_and_register_class(self, full_class_name: str) -> str: method to_env (line 340) | def to_env(self, key: str, value: Any, output: IO): class DelayedParser (line 346) | class DelayedParser(EnvParser): method from_env (line 351) | def from_env(self, key: str) -> JsonType: method to_env (line 355) | def to_env(self, key: str, value: Any, output: IO): function merge (line 360) | def merge(a, b): function get_env_parser (line 385) | def get_env_parser(target_type: type, parsers: dict[type, EnvParser]) ->... function _get_default_parsers (line 449) | def _get_default_parsers() -> dict[type, EnvParser]: function _create_sample (line 463) | def _create_sample(type_: type): function from_env (line 483) | def from_env( function to_env (line 501) | def to_env( FILE: openhands-agent-server/openhands/agent_server/event_router.py function normalize_datetime_to_server_timezone (line 39) | def normalize_datetime_to_server_timezone(dt: datetime) -> datetime: function search_conversation_events (line 66) | async def search_conversation_events( function count_conversation_events (line 123) | async def count_conversation_events( function get_conversation_event (line 167) | async def get_conversation_event( function batch_get_conversation_events (line 179) | async def batch_get_conversation_events( function send_message (line 190) | async def send_message( function respond_to_confirmation (line 203) | async def respond_to_confirmation( FILE: openhands-agent-server/openhands/agent_server/event_service.py class EventService (line 55) | class EventService: method conversation_dir (line 79) | def conversation_dir(self): method load_meta (line 82) | async def load_meta(self): method save_meta (line 91) | async def save_meta(self): method _write_guard (line 102) | def _write_guard(self): method renew_lease (line 107) | def renew_lease(self) -> None: method _renew_lease_loop (line 128) | async def _renew_lease_loop(self) -> None: method get_conversation (line 138) | def get_conversation(self): method _get_event_sync (line 143) | def _get_event_sync(self, event_id: str) -> Event | None: method get_event (line 156) | async def get_event(self, event_id: str) -> Event | None: method _event_matches_filters (line 162) | def _event_matches_filters( method _search_events_sync (line 189) | def _search_events_sync( method search_events (line 270) | async def search_events( method _count_events_sync (line 297) | def _count_events_sync( method count_events (line 339) | async def count_events( method _get_execution_status_sync (line 361) | def _get_execution_status_sync(self) -> ConversationExecutionStatus: method _get_execution_status (line 367) | async def _get_execution_status(self) -> ConversationExecutionStatus: method _create_state_update_event_sync (line 371) | def _create_state_update_event_sync(self) -> ConversationStateUpdateEv... method _create_state_update_event (line 378) | async def _create_state_update_event(self) -> ConversationStateUpdateE... method _event_matches_body (line 382) | def _event_matches_body(self, event: Event, body: str) -> bool: method batch_get_events (line 408) | async def batch_get_events(self, event_ids: list[str]) -> list[Event |... method send_message (line 415) | async def send_message(self, message: Message, run: bool = False): method subscribe_to_events (line 425) | async def subscribe_to_events(self, subscriber: Subscriber[Event]) -> ... method unsubscribe_from_events (line 451) | async def unsubscribe_from_events(self, subscriber_id: UUID) -> bool: method _emit_event_from_thread (line 454) | def _emit_event_from_thread(self, event: Event) -> None: method _setup_llm_log_streaming (line 475) | def _setup_llm_log_streaming(self, agent: AgentBase) -> None: method _setup_acp_activity_heartbeat (line 499) | def _setup_acp_activity_heartbeat(self, agent: AgentBase) -> None: method _setup_stats_streaming (line 521) | def _setup_stats_streaming(self, agent: AgentBase) -> None: method _ensure_workspace_is_git_repo (line 538) | def _ensure_workspace_is_git_repo(working_dir: Path) -> None: method start (line 565) | async def start(self): method run (line 705) | async def run(self): method respond_to_confirmation (line 759) | async def respond_to_confirmation(self, request: ConfirmationResponseR... method reject_pending_actions (line 774) | async def reject_pending_actions(self, reason: str): method pause (line 783) | async def pause(self): method update_secrets (line 790) | async def update_secrets(self, secrets: dict[str, SecretValue]): method set_confirmation_policy (line 797) | async def set_confirmation_policy(self, policy: ConfirmationPolicyBase): method set_security_analyzer (line 806) | async def set_security_analyzer( method close (line 817) | async def close(self): method generate_title (line 852) | async def generate_title( method ask_agent (line 878) | async def ask_agent(self, question: str) -> str: method condense (line 889) | async def condense(self) -> None: method _get_agent_final_response_sync (line 900) | def _get_agent_final_response_sync(self) -> str: method get_agent_final_response (line 911) | async def get_agent_final_response(self) -> str: method get_state (line 922) | async def get_state(self) -> ConversationState: method _publish_state_update (line 927) | async def _publish_state_update(self): method __aenter__ (line 938) | async def __aenter__(self): method __aexit__ (line 942) | async def __aexit__(self, exc_type, exc_value, traceback): method is_open (line 952) | def is_open(self) -> bool: FILE: openhands-agent-server/openhands/agent_server/file_router.py class SubdirectoryEntry (line 26) | class SubdirectoryEntry(BaseModel): class SubdirectoryPage (line 31) | class SubdirectoryPage(BaseModel): class FileBrowserEntry (line 36) | class FileBrowserEntry(BaseModel): class HomeResponse (line 41) | class HomeResponse(BaseModel): function _upload_file (line 51) | async def _upload_file(path: str, file: UploadFile) -> Success: function _download_file (line 87) | async def _download_file(path: str) -> FileResponse: function _create_zip_from_directory (line 125) | def _create_zip_from_directory(source_dir: Path, output_path: Path) -> N... function upload_file_query (line 138) | async def upload_file_query( function download_file_query (line 147) | async def download_file_query( function _list_home_favorites (line 154) | def _list_home_favorites(home: Path, limit: int = 50) -> list[FileBrowse... function _list_root_locations (line 180) | def _list_root_locations() -> list[FileBrowserEntry]: function get_home_directory (line 200) | async def get_home_directory() -> HomeResponse: function search_subdirs (line 217) | async def search_subdirs( function download_trajectory (line 299) | async def download_trajectory( FILE: openhands-agent-server/openhands/agent_server/git_router.py function _get_git_changes (line 28) | async def _get_git_changes(path: str, ref: str | None) -> list[GitChange]: function _get_git_diff (line 43) | async def _get_git_diff(path: str, ref: str | None) -> GitDiff: function git_changes_query (line 60) | async def git_changes_query( function git_diff_query (line 76) | async def git_diff_query( FILE: openhands-agent-server/openhands/agent_server/hooks_router.py class HooksRequest (line 17) | class HooksRequest(BaseModel): class HooksResponse (line 25) | class HooksResponse(BaseModel): function get_hooks (line 35) | def get_hooks(request: HooksRequest) -> HooksResponse: FILE: openhands-agent-server/openhands/agent_server/hooks_service.py function load_hooks_from_workspace (line 20) | def load_hooks_from_workspace(project_dir: str | None = None) -> HookCon... FILE: openhands-agent-server/openhands/agent_server/llm_router.py class ProvidersResponse (line 17) | class ProvidersResponse(BaseModel): class ModelsResponse (line 23) | class ModelsResponse(BaseModel): class VerifiedModelsResponse (line 29) | class VerifiedModelsResponse(BaseModel): function list_providers (line 36) | async def list_providers() -> ProvidersResponse: function list_models (line 43) | async def list_models( function list_verified_models (line 72) | async def list_verified_models() -> VerifiedModelsResponse: FILE: openhands-agent-server/openhands/agent_server/logging_config.py class UvicornAccessJsonFormatter (line 11) | class UvicornAccessJsonFormatter(JsonFormatter): method add_fields (line 21) | def add_fields( function get_uvicorn_logging_config (line 48) | def get_uvicorn_logging_config() -> dict[str, Any]: FILE: openhands-agent-server/openhands/agent_server/middleware.py class LocalhostCORSMiddleware (line 8) | class LocalhostCORSMiddleware(CORSMiddleware): method __init__ (line 15) | def __init__(self, app: ASGIApp, allow_origins: list[str]) -> None: method is_allowed_origin (line 24) | def is_allowed_origin(self, origin: str) -> bool: FILE: openhands-agent-server/openhands/agent_server/models.py class ServerErrorEvent (line 44) | class ServerErrorEvent(Event): class ConversationSortOrder (line 57) | class ConversationSortOrder(str, Enum): class EventSortOrder (line 66) | class EventSortOrder(str, Enum): class StoredConversation (line 73) | class StoredConversation(StartConversationRequest): class _ConversationInfoBase (line 88) | class _ConversationInfoBase(BaseModel): class ConversationInfo (line 189) | class ConversationInfo(_ConversationInfoBase): class ConversationPage (line 198) | class ConversationPage(BaseModel): class ConversationResponse (line 210) | class ConversationResponse(BaseModel): class ConfirmationResponseRequest (line 215) | class ConfirmationResponseRequest(BaseModel): class Success (line 222) | class Success(BaseModel): class EventPage (line 226) | class EventPage(OpenHandsModel): class UpdateSecretsRequest (line 231) | class UpdateSecretsRequest(BaseModel): method convert_string_secrets (line 240) | def convert_string_secrets(cls, v: dict[str, Any]) -> dict[str, Any]: class SetConfirmationPolicyRequest (line 276) | class SetConfirmationPolicyRequest(BaseModel): class SetSecurityAnalyzerRequest (line 282) | class SetSecurityAnalyzerRequest(BaseModel): class UpdateConversationRequest (line 290) | class UpdateConversationRequest(BaseModel): class ForkConversationRequest (line 309) | class ForkConversationRequest(BaseModel): class GenerateTitleRequest (line 337) | class GenerateTitleRequest(BaseModel): class GenerateTitleResponse (line 348) | class GenerateTitleResponse(BaseModel): class AskAgentRequest (line 354) | class AskAgentRequest(BaseModel): class AskAgentResponse (line 360) | class AskAgentResponse(BaseModel): class AgentResponseResult (line 366) | class AgentResponseResult(BaseModel): class BashEventBase (line 382) | class BashEventBase(DiscriminatedUnionMixin, ABC): class ExecuteBashRequest (line 389) | class ExecuteBashRequest(BaseModel): class BashCommand (line 398) | class BashCommand(BashEventBase, ExecuteBashRequest): class BashOutput (line 402) | class BashOutput(BashEventBase): class BashError (line 423) | class BashError(BashEventBase): class BashEventSortOrder (line 428) | class BashEventSortOrder(Enum): class BashEventPage (line 433) | class BashEventPage(OpenHandsModel): FILE: openhands-agent-server/openhands/agent_server/openapi.py function generate_openapi_schema (line 11) | def generate_openapi_schema() -> dict[str, Any]: FILE: openhands-agent-server/openhands/agent_server/persistence/models.py class SettingsUpdatePayload (line 34) | class SettingsUpdatePayload(TypedDict, total=False): function _deep_merge (line 42) | def _deep_merge(base: dict[str, Any], overlay: dict[str, Any]) -> dict[s... class PersistedSettings (line 59) | class PersistedSettings(BaseModel): method llm_api_key_is_set (line 87) | def llm_api_key_is_set(self) -> bool: method update (line 97) | def update(self, payload: SettingsUpdatePayload) -> None: method from_persisted (line 180) | def from_persisted( method agent_settings_serializer (line 201) | def agent_settings_serializer( method _normalize_inputs (line 212) | def _normalize_inputs( class CustomSecret (line 252) | class CustomSecret(BaseModel): method _validate_name (line 261) | def _validate_name(cls, v: str) -> str: method _validate_secret (line 283) | def _validate_secret( method _serialize_secret (line 289) | def _serialize_secret(self, v: SecretStr | None, info: SerializationIn... class Secrets (line 293) | class Secrets(BaseModel): method get_env_vars (line 305) | def get_env_vars(self) -> dict[str, str]: method get_descriptions (line 325) | def get_descriptions(self) -> dict[str, str | None]: method custom_secrets_serializer (line 332) | def custom_secrets_serializer( method _normalize_inputs (line 344) | def _normalize_inputs(cls, data: dict | object) -> dict | object: function _coerce_dict_secrets (line 388) | def _coerce_dict_secrets(d: dict[str, Any]) -> dict[str, Any]: FILE: openhands-agent-server/openhands/agent_server/persistence/store.py function _validate_filename (line 82) | def _validate_filename(filename: str) -> None: function _ensure_secure_directory (line 115) | def _ensure_secure_directory(path: Path) -> None: function _file_lock (line 140) | def _file_lock(lock_path: Path) -> Iterator[None]: function _atomic_write_json (line 180) | def _atomic_write_json(path: Path, data: dict) -> None: class SettingsStore (line 238) | class SettingsStore(ABC): method load (line 242) | def load(self) -> PersistedSettings | None: method save (line 246) | def save(self, settings: PersistedSettings) -> None: method update (line 250) | def update( class SecretsStore (line 264) | class SecretsStore(ABC): method load (line 268) | def load(self) -> Secrets | None: method save (line 272) | def save(self, secrets: Secrets) -> None: method get_secret (line 276) | def get_secret(self, name: str) -> str | None: method set_secret (line 280) | def set_secret(self, name: str, value: str, description: str | None = ... method delete_secret (line 284) | def delete_secret(self, name: str) -> bool: class FileSettingsStore (line 288) | class FileSettingsStore(SettingsStore): method __init__ (line 300) | def __init__( method load (line 314) | def load(self) -> PersistedSettings | None: method save (line 346) | def save(self, settings: PersistedSettings) -> None: method update (line 382) | def update( class FileSecretsStore (line 419) | class FileSecretsStore(SecretsStore): method __init__ (line 438) | def __init__( method load (line 460) | def load(self) -> Secrets | None: method save (line 491) | def save(self, secrets: Secrets) -> None: method get_secret (line 526) | def get_secret(self, name: str) -> str | None: method set_secret (line 540) | def set_secret(self, name: str, value: str, description: str | None = ... method delete_secret (line 572) | def delete_secret(self, name: str) -> bool: function _get_persistence_dir (line 607) | def _get_persistence_dir(config: Config | None = None) -> Path: function _get_cipher (line 621) | def _get_cipher(config: Config | None = None) -> Cipher | None: function get_settings_store (line 628) | def get_settings_store(config: Config | None = None) -> FileSettingsStore: function get_secrets_store (line 660) | def get_secrets_store(config: Config | None = None) -> FileSecretsStore: function reset_stores (line 692) | def reset_stores() -> None: FILE: openhands-agent-server/openhands/agent_server/profiles_router.py class ProfileInfo (line 43) | class ProfileInfo(BaseModel): class ProfileListResponse (line 50) | class ProfileListResponse(BaseModel): class ProfileDetailResponse (line 55) | class ProfileDetailResponse(BaseModel): class ProfileMutationResponse (line 63) | class ProfileMutationResponse(BaseModel): class SaveProfileRequest (line 68) | class SaveProfileRequest(BaseModel): class RenameProfileRequest (line 76) | class RenameProfileRequest(BaseModel): function _store_errors (line 86) | def _store_errors() -> Iterator[None]: function _has_api_key (line 102) | def _has_api_key(llm: LLM) -> bool: function _model_to_profile_name (line 108) | def _model_to_profile_name(model: str) -> str: function list_profiles (line 141) | async def list_profiles(request: Request) -> ProfileListResponse: function get_profile (line 206) | async def get_profile(request: Request, name: ProfileName) -> ProfileDet... function save_profile (line 245) | async def save_profile( function delete_profile (line 285) | async def delete_profile(name: ProfileName) -> ProfileMutationResponse: function rename_profile (line 295) | async def rename_profile( class ActivateProfileResponse (line 347) | class ActivateProfileResponse(BaseModel): function activate_profile (line 356) | async def activate_profile( FILE: openhands-agent-server/openhands/agent_server/pub_sub.py class Subscriber (line 15) | class Subscriber[T](ABC): method __call__ (line 17) | async def __call__(self, event: T): method close (line 20) | async def close(self): class MaxSubscribersError (line 24) | class MaxSubscribersError(Exception): class PubSub (line 29) | class PubSub[T]: method subscribe (line 39) | def subscribe(self, subscriber: Subscriber[T]) -> UUID: method unsubscribe (line 60) | def unsubscribe(self, subscriber_id: UUID) -> bool: method __call__ (line 77) | async def __call__(self, event: T) -> None: method close (line 100) | async def close(self): FILE: openhands-agent-server/openhands/agent_server/server_details_router.py function _package_version (line 19) | def _package_version(dist_name: str) -> str: class HealthStatus (line 26) | class HealthStatus(BaseModel): class ServerInfo (line 30) | class ServerInfo(BaseModel): function update_last_execution_time (line 59) | def update_last_execution_time(): function mark_initialization_complete (line 64) | def mark_initialization_complete() -> None: function alive (line 75) | async def alive() -> HealthStatus: function health (line 81) | async def health() -> HealthStatus: function ready (line 87) | async def ready(response: Response) -> dict[str, str]: function get_server_info (line 101) | async def get_server_info() -> ServerInfo: FILE: openhands-agent-server/openhands/agent_server/settings_router.py function _get_agent_settings_schema (line 52) | def _get_agent_settings_schema() -> SettingsSchema: function _get_conversation_settings_schema (line 62) | def _get_conversation_settings_schema() -> SettingsSchema: function get_agent_settings_schema (line 67) | async def get_agent_settings_schema() -> SettingsSchema: function get_conversation_settings_schema (line 73) | async def get_conversation_settings_schema() -> SettingsSchema: function _validate_secret_name (line 81) | def _validate_secret_name(name: str) -> None: function get_settings (line 104) | async def get_settings(request: Request) -> SettingsResponse: function update_settings (line 167) | async def update_settings( function list_secrets (line 251) | async def list_secrets(request: Request) -> SecretsListResponse: function get_secret_value (line 276) | async def get_secret_value(request: Request, name: str) -> Response: function create_secret (line 309) | async def create_secret( function delete_secret (line 351) | async def delete_secret(request: Request, name: str) -> dict[str, bool]: FILE: openhands-agent-server/openhands/agent_server/skills_router.py class ExposedUrl (line 51) | class ExposedUrl(BaseModel): class OrgConfig (line 59) | class OrgConfig(BaseModel): class SandboxConfig (line 73) | class SandboxConfig(BaseModel): class SkillsRequest (line 82) | class SkillsRequest(BaseModel): class SkillInfo (line 113) | class SkillInfo(BaseModel): class SkillsResponse (line 126) | class SkillsResponse(BaseModel): class SyncResponse (line 136) | class SyncResponse(BaseModel): class InstallSkillRequest (line 148) | class InstallSkillRequest(BaseModel): class InstalledSkillResponse (line 175) | class InstalledSkillResponse(BaseModel): method from_skill_info (line 193) | def from_skill_info(cls, info: InstalledSkillInfo) -> "InstalledSkillR... class InstalledSkillsListResponse (line 207) | class InstalledSkillsListResponse(BaseModel): class UpdateSkillStateRequest (line 213) | class UpdateSkillStateRequest(BaseModel): class UpdateSkillStateResponse (line 219) | class UpdateSkillStateResponse(BaseModel): class UninstallSkillResponse (line 226) | class UninstallSkillResponse(BaseModel): class UpdateSkillResponse (line 232) | class UpdateSkillResponse(BaseModel): class MarketplaceCatalogResponse (line 239) | class MarketplaceCatalogResponse(BaseModel): function get_skills (line 246) | def get_skills(request: SkillsRequest) -> SkillsResponse: function sync_skills (line 309) | def sync_skills() -> SyncResponse: function install_skill_endpoint (line 339) | def install_skill_endpoint(request: InstallSkillRequest) -> InstalledSki... function list_installed_skills_endpoint (line 382) | def list_installed_skills_endpoint() -> InstalledSkillsListResponse: function get_installed_skill_endpoint (line 402) | def get_installed_skill_endpoint(skill_name: SkillNamePath) -> Installed... function set_skill_enabled_endpoint (line 428) | def set_skill_enabled_endpoint( function uninstall_skill_endpoint (line 461) | def uninstall_skill_endpoint(skill_name: SkillNamePath) -> UninstallSkil... function refresh_skill_endpoint (line 491) | def refresh_skill_endpoint(skill_name: SkillNamePath) -> UpdateSkillResp... function get_marketplace_catalog (line 518) | def get_marketplace_catalog() -> MarketplaceCatalogResponse: FILE: openhands-agent-server/openhands/agent_server/skills_service.py class ExposedUrlData (line 72) | class ExposedUrlData: class SkillLoadResult (line 81) | class SkillLoadResult: function load_org_skills_from_url (line 88) | def load_org_skills_from_url( function create_sandbox_skill (line 221) | def create_sandbox_skill( function merge_skills (line 266) | def merge_skills(skill_lists: list[list[Skill]]) -> list[Skill]: function load_all_skills (line 291) | def load_all_skills( function sync_public_skills (line 382) | def sync_public_skills() -> tuple[bool, str]: function service_install_skill (line 412) | def service_install_skill( function service_uninstall_skill (line 450) | def service_uninstall_skill( function service_enable_skill (line 467) | def service_enable_skill( function service_disable_skill (line 484) | def service_disable_skill( function service_list_installed_skills (line 501) | def service_list_installed_skills( function service_get_installed_skill (line 518) | def service_get_installed_skill( function service_update_skill (line 535) | def service_update_skill( class MarketplaceSkillInfo (line 552) | class MarketplaceSkillInfo(BaseModel): function service_get_marketplace_catalog (line 583) | def service_get_marketplace_catalog( function _fetch_catalog_entries (line 626) | def _fetch_catalog_entries(marketplace_path: str) -> list[_CatalogEntry]: FILE: openhands-agent-server/openhands/agent_server/sockets.py function _get_config (line 54) | def _get_config(websocket: WebSocket) -> Config: function _resolve_websocket_session_api_key (line 67) | def _resolve_websocket_session_api_key( function _accept_authenticated_websocket (line 95) | async def _accept_authenticated_websocket( function events_socket (line 189) | async def events_socket( function bash_events_socket (line 341) | async def bash_events_socket( function _send_event (line 434) | async def _send_event(event: Event, websocket: WebSocket): function _is_auth_control_message (line 450) | def _is_auth_control_message(data: object) -> bool: function _safe_close_websocket (line 461) | async def _safe_close_websocket( function _is_websocket_connected (line 473) | def _is_websocket_connected(websocket: WebSocket) -> bool: class _WebSocketSubscriber (line 494) | class _WebSocketSubscriber(Subscriber): method __call__ (line 499) | async def __call__(self, event: Event): function _send_bash_event (line 503) | async def _send_bash_event(event: BashEventBase, websocket: WebSocket): class _BashWebSocketSubscriber (line 517) | class _BashWebSocketSubscriber(Subscriber[BashEventBase]): method __call__ (line 522) | async def __call__(self, event: BashEventBase): FILE: openhands-agent-server/openhands/agent_server/tool_preload_service.py class ToolPreloadService (line 15) | class ToolPreloadService: method start (line 21) | async def start(self) -> bool: method stop (line 46) | async def stop(self) -> None: method is_running (line 50) | def is_running(self) -> bool: function get_tool_preload_service (line 58) | def get_tool_preload_service() -> ToolPreloadService | None: FILE: openhands-agent-server/openhands/agent_server/tool_router.py function list_available_tools (line 23) | async def list_available_tools() -> list[str]: FILE: openhands-agent-server/openhands/agent_server/utils.py function safe_rmtree (line 16) | def safe_rmtree(path: str | Path | None, description: str = "directory")... function utc_now (line 53) | def utc_now(): function _uuid_to_hex (line 58) | def _uuid_to_hex(uuid_obj: UUID) -> str: FILE: openhands-agent-server/openhands/agent_server/vscode_extensions/openhands-settings/extension.js function activate (line 4) | function activate(context) { function deactivate (line 20) | function deactivate() {} FILE: openhands-agent-server/openhands/agent_server/vscode_router.py class VSCodeUrlResponse (line 15) | class VSCodeUrlResponse(BaseModel): function get_vscode_url (line 22) | async def get_vscode_url( function get_vscode_status (line 52) | async def get_vscode_status() -> dict[str, bool | str]: FILE: openhands-agent-server/openhands/agent_server/vscode_service.py class VSCodeService (line 14) | class VSCodeService: method __init__ (line 17) | def __init__( method start (line 39) | async def start(self) -> bool: method stop (line 74) | async def stop(self) -> None: method get_vscode_url (line 90) | def get_vscode_url( method is_running (line 112) | def is_running(self) -> bool: method _check_vscode_available (line 120) | def _check_vscode_available(self) -> bool: method _is_port_available (line 129) | async def _is_port_available(self) -> bool: method _start_vscode_process (line 146) | async def _start_vscode_process(self) -> None: method _wait_for_startup (line 179) | async def _wait_for_startup(self) -> None: function get_vscode_service (line 219) | def get_vscode_service() -> VSCodeService | None: FILE: openhands-agent-server/openhands/agent_server/workspace_router.py function conversation_workspace_url_path (line 32) | def conversation_workspace_url_path(conversation_id: UUID | str) -> str: function _resolve_workspace_dir (line 41) | async def _resolve_workspace_dir( function _resolve_target (line 66) | def _resolve_target(workspace_dir: Path, file_path: str) -> Path: function _serve_path (line 80) | def _serve_path(workspace_dir: Path, file_path: str) -> FileResponse: function serve_workspace_root (line 104) | async def serve_workspace_root( function serve_workspace_file (line 117) | async def serve_workspace_file( FILE: openhands-sdk/openhands/sdk/__init__.py function __getattr__ (line 134) | def __getattr__(name: str) -> Any: FILE: openhands-sdk/openhands/sdk/agent/__init__.py function __getattr__ (line 16) | def __getattr__(name: str): FILE: openhands-sdk/openhands/sdk/agent/acp_agent.py function _make_dummy_llm (line 156) | def _make_dummy_llm() -> LLM: function _select_auth_method (line 179) | def _select_auth_method( function _maybe_set_session_model (line 204) | async def _maybe_set_session_model( function _extract_token_usage (line 224) | def _extract_token_usage( function _estimate_cost_from_tokens (line 251) | def _estimate_cost_from_tokens( function _image_url_to_acp_block (line 270) | def _image_url_to_acp_block(url: str) -> ImageContentBlock | None: function _serialize_tool_content (line 291) | def _serialize_tool_content(content: list[Any] | None) -> list[dict[str,... function _filter_jsonrpc_lines (line 317) | async def _filter_jsonrpc_lines(source: Any, dest: Any) -> None: class _OpenHandsACPBridge (line 346) | class _OpenHandsACPBridge: method __init__ (line 392) | def __init__(self) -> None: method reset (line 421) | def reset(self) -> None: method prepare_usage_sync (line 433) | def prepare_usage_sync(self, session_id: str) -> asyncio.Event: method get_turn_usage_update (line 440) | def get_turn_usage_update(self, session_id: str) -> Any: method pop_turn_usage_update (line 444) | def pop_turn_usage_update(self, session_id: str) -> Any: method session_update (line 451) | async def session_update( method _emit_tool_call_event (line 527) | def _emit_tool_call_event(self, tc: dict[str, Any]) -> None: method _maybe_signal_activity (line 558) | def _maybe_signal_activity(self) -> None: method request_permission (line 579) | async def request_permission( method write_text_file (line 599) | async def write_text_file( method read_text_file (line 604) | async def read_text_file( method create_terminal (line 614) | async def create_terminal( method terminal_output (line 626) | async def terminal_output( method release_terminal (line 631) | async def release_terminal( method wait_for_terminal_exit (line 636) | async def wait_for_terminal_exit( method kill_terminal (line 641) | async def kill_terminal( method ext_method (line 646) | async def ext_method( method ext_notification (line 653) | async def ext_notification( method on_connect (line 660) | def on_connect(self, conn: Any) -> None: # noqa: ARG002 class ACPAgent (line 669) | class ACPAgent(AgentBase): method _serialize_acp_env (line 695) | def _serialize_acp_env(self, value: dict[str, str], info): method model_post_init (line 724) | def model_post_init(self, __context: object) -> None: method _record_usage (line 764) | def _record_usage( method supports_openhands_tools (line 841) | def supports_openhands_tools(self) -> bool: method supports_openhands_mcp (line 846) | def supports_openhands_mcp(self) -> bool: method supports_condenser (line 851) | def supports_condenser(self) -> bool: method agent_kind (line 856) | def agent_kind(self) -> Literal["acp"]: method agent_name (line 863) | def agent_name(self) -> str: method agent_version (line 868) | def agent_version(self) -> str: method get_all_llms (line 872) | def get_all_llms(self) -> Generator[LLM]: method init_state (line 877) | def init_state( method _render_suffix (line 970) | def _render_suffix(self, state: ConversationState) -> str | None: method _start_acp_server (line 979) | def _start_acp_server(self, state: ConversationState) -> None: method _reset_client_for_turn (line 1181) | def _reset_client_for_turn( method _cancel_inflight_tool_calls (line 1201) | def _cancel_inflight_tool_calls(self) -> None: method _build_acp_prompt (line 1245) | def _build_acp_prompt( method step (line 1270) | def step( method ask_agent (line 1514) | def ask_agent(self, question: str) -> str | None: method close (line 1570) | def close(self) -> None: method _cleanup (line 1577) | def _cleanup(self) -> None: method __del__ (line 1606) | def __del__(self) -> None: FILE: openhands-sdk/openhands/sdk/agent/agent.py function _tool_has_summary_param (line 90) | def _tool_has_summary_param(tool: ToolDefinition) -> bool: class _ActionBatch (line 112) | class _ActionBatch: method _truncate_at_finish (line 128) | def _truncate_at_finish( method prepare (line 156) | def prepare( method emit (line 186) | def emit(self, on_event: ConversationCallbackType) -> None: method finalize (line 205) | def finalize( class Agent (line 239) | class Agent(CriticMixin, ResponseDispatchMixin, AgentBase): method model_post_init (line 284) | def model_post_init(self, __context: object) -> None: method _add_security_prompt_as_default (line 292) | def _add_security_prompt_as_default(cls, data): method init_state (line 305) | def init_state( method get_dynamic_context (line 410) | def get_dynamic_context(self, state: ConversationState) -> str | None: method _execute_actions (line 446) | def _execute_actions( method step (line 475) | def step( method _requires_user_confirmation (line 604) | def _requires_user_confirmation( method _extract_security_risk (line 647) | def _extract_security_risk( method _extract_summary (line 674) | def _extract_summary( method _emit_tool_error (line 721) | def _emit_tool_error( method _get_action_event (line 755) | def _get_action_event( method _execute_action_event (line 892) | def _execute_action_event( method _maybe_emit_vllm_tokens (line 950) | def _maybe_emit_vllm_tokens( method _log_context_window_exceeded_warning (line 965) | def _log_context_window_exceeded_warning(self) -> None: FILE: openhands-sdk/openhands/sdk/agent/base.py class AgentBase (line 54) | class AgentBase(DiscriminatedUnionMixin, ABC): method _validate_system_prompt_fields (line 186) | def _validate_system_prompt_fields(cls, data: Any) -> Any: method _decrypt_mcp_config (line 208) | def _decrypt_mcp_config(cls, data: Any, info: ValidationInfo) -> Any: method _serialize_with_mcp_handling (line 250) | def _serialize_with_mcp_handling(self, handler, info: SerializationInfo): method prompt_dir (line 354) | def prompt_dir(self) -> str: method name (line 363) | def name(self) -> str: method static_system_message (line 368) | def static_system_message(self) -> str: method dynamic_context (line 411) | def dynamic_context(self) -> str | None: method init_state (line 434) | def init_state( method _initialize (line 448) | def _initialize(self, state: ConversationState): method step (line 533) | def step( method verify (line 555) | def verify( method model_dump_succint (line 623) | def model_dump_succint(self, **kwargs): method get_all_llms (line 633) | def get_all_llms(self) -> Generator[LLM]: method tools_map (line 704) | def tools_map(self) -> dict[str, ToolDefinition]: method supports_openhands_tools (line 719) | def supports_openhands_tools(self) -> bool: method supports_openhands_mcp (line 728) | def supports_openhands_mcp(self) -> bool: method supports_condenser (line 737) | def supports_condenser(self) -> bool: method agent_kind (line 746) | def agent_kind(self) -> Literal["openhands", "acp"]: method ask_agent (line 750) | def ask_agent(self, question: str) -> str | None: # noqa: ARG002 method close (line 761) | def close(self) -> None: FILE: openhands-sdk/openhands/sdk/agent/critic_mixin.py class CriticMixin (line 25) | class CriticMixin: method _should_evaluate_with_critic (line 34) | def _should_evaluate_with_critic(self, action: Action | None) -> bool: method _evaluate_with_critic (line 49) | def _evaluate_with_critic( method _check_iterative_refinement (line 76) | def _check_iterative_refinement( FILE: openhands-sdk/openhands/sdk/agent/parallel_executor.py class ParallelToolExecutor (line 38) | class ParallelToolExecutor: method __init__ (line 46) | def __init__( method execute_batch (line 54) | def execute_batch( method _run_safe (line 93) | def _run_safe( method _extract_declared_resources (line 143) | def _extract_declared_resources( method _resolve_lock_keys (line 152) | def _resolve_lock_keys( FILE: openhands-sdk/openhands/sdk/agent/response_dispatch.py class LLMResponseType (line 44) | class LLMResponseType(StrEnum): function classify_response (line 53) | def classify_response(message: Message) -> LLMResponseType: class _AgentProtocol (line 86) | class _AgentProtocol(Protocol): method _get_action_event (line 91) | def _get_action_event( method _execute_actions (line 104) | def _execute_actions( method _requires_user_confirmation (line 111) | def _requires_user_confirmation( method _maybe_emit_vllm_tokens (line 117) | def _maybe_emit_vllm_tokens( method _evaluate_with_critic (line 123) | def _evaluate_with_critic( class ResponseDispatchMixin (line 130) | class ResponseDispatchMixin: method _get_action_event (line 140) | def _get_action_event( method _execute_actions (line 155) | def _execute_actions( method _requires_user_confirmation (line 162) | def _requires_user_confirmation( method _maybe_emit_vllm_tokens (line 168) | def _maybe_emit_vllm_tokens( method _evaluate_with_critic (line 174) | def _evaluate_with_critic( method _handle_tool_calls (line 180) | def _handle_tool_calls( method _handle_content_response (line 225) | def _handle_content_response( method _handle_no_content_response (line 239) | def _handle_no_content_response( method _emit_message_event (line 261) | def _emit_message_event( method _send_corrective_nudge (line 283) | def _send_corrective_nudge(self, on_event: ConversationCallbackType) -... FILE: openhands-sdk/openhands/sdk/agent/utils.py function _escape_control_char (line 48) | def _escape_control_char(m: re.Match[str]) -> str: function sanitize_json_control_chars (line 54) | def sanitize_json_control_chars(raw: str) -> str: function fix_malformed_tool_arguments (line 68) | def fix_malformed_tool_arguments( function _normalize_arguments (line 194) | def _normalize_arguments(arguments: dict[str, Any]) -> dict[str, Any]: function parse_tool_call_arguments (line 209) | def parse_tool_call_arguments(raw_arguments: str) -> dict[str, Any]: function _infer_file_editor_command (line 221) | def _infer_file_editor_command(arguments: dict[str, Any]) -> str | None: function _has_file_editor_hint (line 235) | def _has_file_editor_hint(arguments: dict[str, Any]) -> bool: function _join_shell_command (line 300) | def _join_shell_command(parts: list[str]) -> str: function _build_ripgrep_terminal_command (line 307) | def _build_ripgrep_terminal_command( function _build_system_grep_terminal_command (line 318) | def _build_system_grep_terminal_command( function _build_python_grep_terminal_command (line 329) | def _build_python_grep_terminal_command( function _build_grep_terminal_command (line 341) | def _build_grep_terminal_command(arguments: dict[str, Any]) -> str | None: function _maybe_rewrite_as_terminal_command (line 366) | def _maybe_rewrite_as_terminal_command( function normalize_tool_call (line 386) | def normalize_tool_call( function prepare_llm_messages (line 446) | def prepare_llm_messages( function prepare_llm_messages (line 455) | def prepare_llm_messages( function prepare_llm_messages (line 463) | def prepare_llm_messages( function make_llm_completion (line 517) | def make_llm_completion( FILE: openhands-sdk/openhands/sdk/banner.py function _print_banner (line 15) | def _print_banner(version: str) -> None: FILE: openhands-sdk/openhands/sdk/context/agent_context.py class AgentContext (line 37) | class AgentContext(BaseModel): method _serialize_secrets (line 122) | def _serialize_secrets( method _validate_skills (line 138) | def _validate_skills(cls, v: list[Skill], _info): method _load_auto_skills (line 150) | def _load_auto_skills(self): method get_secret_infos (line 174) | def get_secret_infos(self) -> list[dict[str, str | None]]: method get_formatted_datetime (line 192) | def get_formatted_datetime(self) -> str | None: method _partition_skills (line 206) | def _partition_skills(self) -> tuple[list[Skill], list[Skill]]: method get_system_message_suffix (line 229) | def get_system_message_suffix( method validate_acp_compatibility (line 321) | def validate_acp_compatibility(self) -> None: method to_acp_prompt_context (line 340) | def to_acp_prompt_context( method get_user_message_suffix (line 377) | def get_user_message_suffix( FILE: openhands-sdk/openhands/sdk/context/condenser/base.py class CondenserBase (line 16) | class CondenserBase(DiscriminatedUnionMixin, ABC): method condense (line 33) | def condense(self, view: View, agent_llm: LLM | None = None) -> View |... method handles_condensation_requests (line 50) | def handles_condensation_requests(self) -> bool: class PipelinableCondenserBase (line 65) | class PipelinableCondenserBase(CondenserBase): class NoCondensationAvailableException (line 70) | class NoCondensationAvailableException(Exception): class CondensationRequirement (line 81) | class CondensationRequirement(Enum): class RollingCondenser (line 93) | class RollingCondenser(PipelinableCondenserBase, ABC): method hard_context_reset (line 106) | def hard_context_reset( method condensation_requirement (line 124) | def condensation_requirement( method get_condensation (line 140) | def get_condensation( method condense (line 145) | def condense(self, view: View, agent_llm: LLM | None = None) -> View |... FILE: openhands-sdk/openhands/sdk/context/condenser/llm_summarizing_condenser.py class Reason (line 29) | class Reason(Enum): class LLMSummarizingCondenser (line 37) | class LLMSummarizingCondenser(RollingCondenser): method validate_keep_first_vs_max_size (line 73) | def validate_keep_first_vs_max_size(self): method handles_condensation_requests (line 82) | def handles_condensation_requests(self) -> bool: method get_condensation_reasons (line 85) | def get_condensation_reasons( method condensation_requirement (line 116) | def condensation_requirement( method _generate_condensation (line 141) | def _generate_condensation( method _get_forgotten_events (line 197) | def _get_forgotten_events( method hard_context_reset (line 264) | def hard_context_reset( method get_condensation (line 309) | def get_condensation( FILE: openhands-sdk/openhands/sdk/context/condenser/no_op_condenser.py class NoOpCondenser (line 7) | class NoOpCondenser(CondenserBase): method condense (line 13) | def condense(self, view: View, agent_llm: LLM | None = None) -> View |... FILE: openhands-sdk/openhands/sdk/context/condenser/pipeline_condenser.py class PipelineCondenser (line 7) | class PipelineCondenser(CondenserBase): method condense (line 45) | def condense(self, view: View, agent_llm: LLM | None = None) -> View |... method handles_condensation_requests (line 53) | def handles_condensation_requests(self) -> bool: FILE: openhands-sdk/openhands/sdk/context/condenser/utils.py function get_total_token_count (line 7) | def get_total_token_count( function get_shortest_prefix_above_token_count (line 41) | def get_shortest_prefix_above_token_count( function get_suffix_length_for_token_reduction (line 101) | def get_suffix_length_for_token_reduction( FILE: openhands-sdk/openhands/sdk/context/prompts/prompt.py class FlexibleFileSystemLoader (line 16) | class FlexibleFileSystemLoader(BaseLoader): method __init__ (line 21) | def __init__(self, searchpath: str): method get_source (line 24) | def get_source(self, environment, template): # noqa: ARG002 function refine (line 48) | def refine(text: str) -> str: function _get_env (line 58) | def _get_env(prompt_dir: str) -> Environment: function _get_template (line 78) | def _get_template(prompt_dir: str, template_name: str) -> Template: function render_template (line 88) | def render_template(prompt_dir: str, template_name: str, **ctx) -> str: FILE: openhands-sdk/openhands/sdk/context/view/manipulation_indices.py class ManipulationIndices (line 6) | class ManipulationIndices(set[int]): method find_next (line 18) | def find_next(self, threshold: int) -> int: method complete (line 41) | def complete(events: list[LLMConvertibleEvent]) -> ManipulationIndices: FILE: openhands-sdk/openhands/sdk/context/view/properties/base.py class ViewPropertyBase (line 8) | class ViewPropertyBase(ABC): method enforce (line 29) | def enforce( method manipulation_indices (line 47) | def manipulation_indices( FILE: openhands-sdk/openhands/sdk/context/view/properties/batch_atomicity.py class BatchAtomicityProperty (line 10) | class BatchAtomicityProperty(ViewPropertyBase): method enforce (line 21) | def enforce( method manipulation_indices (line 49) | def manipulation_indices( method _build_batches (line 78) | def _build_batches(self, events: Sequence[Event]) -> dict[EventID, set... FILE: openhands-sdk/openhands/sdk/context/view/properties/observation_uniqueness.py class ObservationUniquenessProperty (line 18) | class ObservationUniquenessProperty(ViewPropertyBase): method enforce (line 33) | def enforce( method manipulation_indices (line 54) | def manipulation_indices( FILE: openhands-sdk/openhands/sdk/context/view/properties/tool_call_matching.py class ToolCallMatchingProperty (line 15) | class ToolCallMatchingProperty(ViewPropertyBase): method enforce (line 25) | def enforce( method manipulation_indices (line 61) | def manipulation_indices( FILE: openhands-sdk/openhands/sdk/context/view/properties/tool_loop_atomicity.py class ToolLoopAtomicityProperty (line 14) | class ToolLoopAtomicityProperty(ViewPropertyBase): method _tool_loops (line 24) | def _tool_loops(self, events: Sequence[Event]) -> list[set[EventID]]: method enforce (line 65) | def enforce( method manipulation_indices (line 95) | def manipulation_indices( FILE: openhands-sdk/openhands/sdk/context/view/view.py class View (line 22) | class View(BaseModel): method __len__ (line 35) | def __len__(self) -> int: method manipulation_indices (line 39) | def manipulation_indices(self) -> ManipulationIndices: method __getitem__ (line 58) | def __getitem__(self, key: slice) -> list[LLMConvertibleEvent]: ... method __getitem__ (line 61) | def __getitem__(self, key: int) -> LLMConvertibleEvent: ... method __getitem__ (line 63) | def __getitem__( method enforce_properties (line 74) | def enforce_properties( method append_event (line 111) | def append_event(self, event: Event) -> None: method from_events (line 143) | def from_events(events: Sequence[Event]) -> View: FILE: openhands-sdk/openhands/sdk/conversation/base.py class ConversationStateProtocol (line 44) | class ConversationStateProtocol(Protocol): method id (line 48) | def id(self) -> ConversationID: method events (line 53) | def events(self) -> EventsListBase: method execution_status (line 58) | def execution_status(self) -> "ConversationExecutionStatus": method confirmation_policy (line 63) | def confirmation_policy(self) -> ConfirmationPolicyBase: method security_analyzer (line 68) | def security_analyzer(self) -> SecurityAnalyzerBase | None: method activated_knowledge_skills (line 73) | def activated_knowledge_skills(self) -> list[str]: method invoked_skills (line 78) | def invoked_skills(self) -> list[str]: method workspace (line 83) | def workspace(self) -> BaseWorkspace: method persistence_dir (line 88) | def persistence_dir(self) -> str | None: method agent (line 96) | def agent(self) -> "AgentBase": method stats (line 101) | def stats(self) -> ConversationStats: method hook_config (line 106) | def hook_config(self) -> "HookConfig | None": class BaseConversation (line 111) | class BaseConversation(ABC): method __init__ (line 119) | def __init__(self) -> None: method _start_observability_span (line 130) | def _start_observability_span(self, session_id: str) -> None: method _end_observability_span (line 145) | def _end_observability_span(self) -> None: method id (line 155) | def id(self) -> ConversationID: ... method state (line 159) | def state(self) -> ConversationStateProtocol: ... method conversation_stats (line 163) | def conversation_stats(self) -> ConversationStats: ... method send_message (line 166) | def send_message(self, message: str | Message, sender: str | None = No... method run (line 180) | def run(self) -> None: method set_confirmation_policy (line 189) | def set_confirmation_policy(self, policy: ConfirmationPolicyBase) -> N... method set_security_analyzer (line 194) | def set_security_analyzer(self, analyzer: SecurityAnalyzerBase | None)... method confirmation_policy_active (line 199) | def confirmation_policy_active(self) -> bool: method is_confirmation_mode_active (line 203) | def is_confirmation_mode_active(self) -> bool: method reject_pending_actions (line 216) | def reject_pending_actions( method pause (line 221) | def pause(self) -> None: ... method update_secrets (line 224) | def update_secrets(self, secrets: Mapping[str, SecretValue]) -> None: ... method close (line 227) | def close(self) -> None: ... method generate_title (line 230) | def generate_title(self, llm: LLM | None = None, max_length: int = 50)... method get_persistence_dir (line 247) | def get_persistence_dir( method ask_agent (line 264) | def ask_agent(self, question: str) -> str: method condense (line 282) | def condense(self) -> None: method execute_tool (line 299) | def execute_tool(self, tool_name: str, action: Action) -> Observation: method fork (line 329) | def fork( method compose_callbacks (line 361) | def compose_callbacks(callbacks: Iterable[CallbackType]) -> CallbackType: FILE: openhands-sdk/openhands/sdk/conversation/conversation.py class Conversation (line 31) | class Conversation: method __new__ (line 61) | def __new__( method __new__ (line 86) | def __new__( method __new__ (line 109) | def __new__( FILE: openhands-sdk/openhands/sdk/conversation/conversation_stats.py class ConversationStats (line 13) | class ConversationStats(BaseModel): method _serialize_with_context (line 24) | def _serialize_with_context(self, serializer: Any, info: Any) -> dict[... method get_combined_metrics (line 58) | def get_combined_metrics(self) -> Metrics: method get_metrics_for_usage (line 64) | def get_metrics_for_usage(self, usage_id: str) -> Metrics: method register_llm (line 70) | def register_llm(self, event: RegistryEvent): FILE: openhands-sdk/openhands/sdk/conversation/event_store.py class EventLog (line 25) | class EventLog(EventsListBase): method __init__ (line 44) | def __init__(self, fs: FileStore, dir_path: str = EVENTS_DIR) -> None: method set_write_guard (line 53) | def set_write_guard( method get_index (line 59) | def get_index(self, event_id: EventID) -> int: method get_id (line 66) | def get_id(self, idx: int) -> EventID: method __getitem__ (line 75) | def __getitem__(self, idx: int) -> Event: ... method __getitem__ (line 78) | def __getitem__(self, idx: slice) -> list[Event]: ... method __getitem__ (line 80) | def __getitem__(self, idx: SupportsIndex | slice) -> Event | list[Event]: method _get_single_item (line 86) | def _get_single_item(self, idx: SupportsIndex) -> Event: method __iter__ (line 107) | def __iter__(self) -> Iterator[Event]: method append (line 119) | def append(self, event: Event) -> None: method _count_events_on_disk (line 159) | def _count_events_on_disk(self) -> int: method _sync_from_disk (line 175) | def _sync_from_disk(self, disk_length: int) -> None: method __len__ (line 196) | def __len__(self) -> int: method _path (line 199) | def _path(self, idx: int, *, event_id: EventID | None = None) -> str: method _scan_and_build_index (line 206) | def _scan_and_build_index(self) -> int: FILE: openhands-sdk/openhands/sdk/conversation/events_list_base.py class EventsListBase (line 7) | class EventsListBase(Sequence[Event], ABC): method append (line 15) | def append(self, event: Event) -> None: FILE: openhands-sdk/openhands/sdk/conversation/exceptions.py class WebSocketConnectionError (line 7) | class WebSocketConnectionError(RuntimeError): method __init__ (line 10) | def __init__( class ConversationRunError (line 25) | class ConversationRunError(RuntimeError): method __init__ (line 36) | def __init__( method _build_error_message (line 52) | def _build_error_message( FILE: openhands-sdk/openhands/sdk/conversation/fifo_lock.py class FIFOLock (line 14) | class FIFOLock: method __init__ (line 32) | def __init__(self) -> None: method acquire (line 40) | def acquire(self, blocking: bool = True, timeout: float = -1) -> bool: method release (line 92) | def release(self) -> None: method __enter__ (line 112) | def __enter__(self: Self) -> Self: method __exit__ (line 117) | def __exit__(self, exc_type: Any, exc_val: Any, exc_tb: Any) -> None: method locked (line 121) | def locked(self) -> bool: method owned (line 128) | def owned(self) -> bool: FILE: openhands-sdk/openhands/sdk/conversation/impl/local_conversation.py class LocalConversation (line 71) | class LocalConversation(BaseConversation): method __init__ (line 90) | def __init__( method id (line 282) | def id(self) -> ConversationID: method state (line 287) | def state(self) -> ConversationState: method conversation_stats (line 298) | def conversation_stats(self): method stuck_detector (line 302) | def stuck_detector(self) -> StuckDetector | None: method resolved_plugins (line 307) | def resolved_plugins(self) -> list[ResolvedPluginSource] | None: method fork (line 316) | def fork( method _ensure_plugins_loaded (line 419) | def _ensure_plugins_loaded(self) -> None: method _register_file_based_agents (line 552) | def _register_file_based_agents(self) -> None: method _ensure_agent_ready (line 571) | def _ensure_agent_ready(self) -> None: method _should_initialize_agent_on_send_message (line 619) | def _should_initialize_agent_on_send_message(self) -> bool: method _pin_prompt_cache_key (line 629) | def _pin_prompt_cache_key(self) -> None: method switch_llm (line 637) | def switch_llm(self, llm: LLM) -> None: method switch_profile (line 658) | def switch_profile(self, profile_name: str) -> None: method send_message (line 681) | def send_message(self, message: str | Message, sender: str | None = No... method run (line 747) | def run(self) -> None: method set_confirmation_policy (line 892) | def set_confirmation_policy(self, policy: ConfirmationPolicyBase) -> N... method reject_pending_actions (line 898) | def reject_pending_actions(self, reason: str = "User rejected the acti... method pause (line 929) | def pause(self) -> None: method update_secrets (line 954) | def update_secrets(self, secrets: Mapping[str, SecretValue]) -> None: method set_security_analyzer (line 973) | def set_security_analyzer(self, analyzer: SecurityAnalyzerBase | None)... method close (line 978) | def close(self) -> None: method ask_agent (line 1016) | def ask_agent(self, question: str) -> str: method generate_title (line 1089) | def generate_title(self, llm: LLM | None = None, max_length: int = 50)... method condense (line 1112) | def condense(self) -> None: method rerun_actions (line 1161) | def rerun_actions( method execute_tool (line 1266) | def execute_tool(self, tool_name: str, action: Action) -> Observation: method __del__ (line 1309) | def __del__(self) -> None: FILE: openhands-sdk/openhands/sdk/conversation/impl/remote_conversation.py function _agent_kind_mismatch_message (line 65) | def _agent_kind_mismatch_message(conversation_id: ConversationID) -> str: function _validate_remote_agent (line 72) | def _validate_remote_agent(agent_data: dict) -> AgentBase: function _send_request (line 80) | def _send_request( class WebSocketCallbackClient (line 108) | class WebSocketCallbackClient: method __init__ (line 119) | def __init__( method start (line 134) | def start(self) -> None: method stop (line 141) | def stop(self) -> None: method wait_until_ready (line 148) | def wait_until_ready(self, timeout: float | None = None) -> bool: method _run (line 180) | def _run(self) -> None: method _client_loop (line 190) | async def _client_loop(self) -> None: class RemoteEventsList (line 232) | class RemoteEventsList(EventsListBase): method __init__ (line 246) | def __init__( method _do_full_sync (line 262) | def _do_full_sync(self) -> None: method reconcile (line 292) | def reconcile(self) -> int: method _add_event_unsafe (line 347) | def _add_event_unsafe(self, event: Event) -> None: method add_event (line 392) | def add_event(self, event: Event) -> None: method append (line 403) | def append(self, event: Event) -> None: method create_default_callback (line 407) | def create_default_callback(self) -> ConversationCallbackType: method __len__ (line 415) | def __len__(self) -> int: method __getitem__ (line 419) | def __getitem__(self, index: int) -> Event: ... method __getitem__ (line 422) | def __getitem__(self, index: slice) -> list[Event]: ... method __getitem__ (line 424) | def __getitem__(self, index: SupportsIndex | slice) -> Event | list[Ev... method __iter__ (line 428) | def __iter__(self): class RemoteState (line 433) | class RemoteState(ConversationStateProtocol): method __init__ (line 443) | def __init__( method _get_conversation_info (line 459) | def _get_conversation_info(self) -> dict: method refresh_from_server (line 469) | def refresh_from_server(self) -> dict: method update_state_from_event (line 481) | def update_state_from_event(self, event: ConversationStateUpdateEvent)... method create_state_update_callback (line 496) | def create_state_update_callback(self) -> ConversationCallbackType: method events (line 506) | def events(self) -> RemoteEventsList: method id (line 511) | def id(self) -> ConversationID: method execution_status (line 516) | def execution_status(self) -> ConversationExecutionStatus: method execution_status (line 527) | def execution_status(self, value: ConversationExecutionStatus) -> None: method confirmation_policy (line 539) | def confirmation_policy(self) -> ConfirmationPolicyBase: method security_analyzer (line 550) | def security_analyzer(self) -> SecurityAnalyzerBase | None: method activated_knowledge_skills (line 560) | def activated_knowledge_skills(self) -> list[str]: method invoked_skills (line 566) | def invoked_skills(self) -> list[str]: method agent (line 572) | def agent(self): method workspace (line 581) | def workspace(self): method persistence_dir (line 590) | def persistence_dir(self): method stats (line 601) | def stats(self) -> ConversationStats: method hook_config (line 608) | def hook_config(self) -> HookConfig | None: method model_dump (line 616) | def model_dump(self, **_kwargs): method model_dump_json (line 621) | def model_dump_json(self, **kwargs): method __enter__ (line 626) | def __enter__(self): method __exit__ (line 629) | def __exit__(self, exc_type, exc_val, exc_tb): class RemoteConversation (line 633) | class RemoteConversation(BaseConversation): method __init__ (line 649) | def __init__( method _create_llm_completion_log_callback (line 890) | def _create_llm_completion_log_callback(self) -> ConversationCallbackT... method id (line 924) | def id(self) -> ConversationID: method state (line 928) | def state(self) -> RemoteState: method conversation_stats (line 933) | def conversation_stats(self): method stuck_detector (line 937) | def stuck_detector(self): method send_message (line 946) | def send_message(self, message: str | Message, sender: str | None = No... method run (line 967) | def run( method _wait_for_run_completion (line 1016) | def _wait_for_run_completion( method _poll_status_once (line 1120) | def _poll_status_once(self) -> str | None: method _handle_conversation_status (line 1131) | def _handle_conversation_status(self, status: str | None) -> bool: method _handle_poll_exception (line 1148) | def _handle_poll_exception(self, exc: Exception) -> None: method _get_last_error_detail (line 1177) | def _get_last_error_detail(self) -> str | None: method set_confirmation_policy (line 1189) | def set_confirmation_policy(self, policy: ConfirmationPolicyBase) -> N... method set_security_analyzer (line 1198) | def set_security_analyzer(self, analyzer: SecurityAnalyzerBase | None)... method reject_pending_actions (line 1212) | def reject_pending_actions(self, reason: str = "User rejected the acti... method pause (line 1224) | def pause(self) -> None: method update_secrets (line 1231) | def update_secrets(self, secrets: Mapping[str, SecretValue]) -> None: method ask_agent (line 1256) | def ask_agent(self, question: str) -> str: method generate_title (line 1284) | def generate_title(self, llm: LLM | None = None, max_length: int = 50)... method condense (line 1304) | def condense(self) -> None: method fork (line 1323) | def fork( method execute_tool (line 1396) | def execute_tool(self, tool_name: str, action: "Action") -> "Observati... method close (line 1418) | def close(self) -> None: method __del__ (line 1450) | def __del__(self) -> None: FILE: openhands-sdk/openhands/sdk/conversation/request.py class SendMessageRequest (line 50) | class SendMessageRequest(BaseModel): method create_message (line 60) | def create_message(self) -> Message: class StartConversationRequest (line 64) | class StartConversationRequest(BaseModel): method _populate_agent_from_settings (line 207) | def _populate_agent_from_settings(cls, data: Any) -> Any: method _require_agent (line 228) | def _require_agent(self) -> StartConversationRequest: class StartACPConversationRequest (line 234) | class StartACPConversationRequest(StartConversationRequest): FILE: openhands-sdk/openhands/sdk/conversation/resource_lock_manager.py class ResourceLockTimeout (line 31) | class ResourceLockTimeout(TimeoutError): class ResourceLockManager (line 35) | class ResourceLockManager: method __init__ (line 46) | def __init__( method _get_lock (line 55) | def _get_lock(self, key: str) -> FIFOLock: method _release_lock (line 67) | def _release_lock(self, key: str) -> None: method _get_timeout (line 79) | def _get_timeout(self, key: str) -> float: method lock (line 85) | def lock(self, *resource_keys: str) -> Generator[None]: FILE: openhands-sdk/openhands/sdk/conversation/response_utils.py function get_agent_final_response (line 11) | def get_agent_final_response(events: Sequence[Event]) -> str: FILE: openhands-sdk/openhands/sdk/conversation/secret_registry.py class SecretRegistry (line 15) | class SecretRegistry(OpenHandsModel): method update_secrets (line 36) | def update_secrets( method find_secrets_in_text (line 49) | def find_secrets_in_text(self, text: str) -> set[str]: method get_secrets_as_env_vars (line 64) | def get_secrets_as_env_vars(self, command: str) -> dict[str, str]: method mask_secrets_in_output (line 96) | def mask_secrets_in_output(self, text: str) -> str: method get_secret_infos (line 119) | def get_secret_infos(self) -> list[dict[str, str | None]]: method get_secret_value (line 135) | def get_secret_value(self, name: str) -> str | None: function _wrap_secret (line 185) | def _wrap_secret(value: SecretValue) -> SecretSource: FILE: openhands-sdk/openhands/sdk/conversation/state.py class ConversationExecutionStatus (line 46) | class ConversationExecutionStatus(str, Enum): method is_terminal (line 60) | def is_terminal(self) -> bool: class ConversationState (line 80) | class ConversationState(OpenHandsModel): method events (line 225) | def events(self) -> EventLog: method env_observation_persistence_dir (line 229) | def env_observation_persistence_dir(self) -> str | None: method set_on_state_change (line 235) | def set_on_state_change(self, callback: ConversationCallbackType | Non... method set_write_guard (line 244) | def set_write_guard( method _save_base_state (line 252) | def _save_base_state(self, fs: FileStore) -> None: method create (line 277) | def create( method __setattr__ (line 399) | def __setattr__(self, name, value): method block_action (line 446) | def block_action(self, action_id: str, reason: str) -> None: method pop_blocked_action (line 450) | def pop_blocked_action(self, action_id: str) -> str | None: method block_message (line 459) | def block_message(self, message_id: str, reason: str) -> None: method pop_blocked_message (line 463) | def pop_blocked_message(self, message_id: str) -> str | None: method get_unmatched_actions (line 473) | def get_unmatched_actions(events: Sequence[Event]) -> list[ActionEvent]: method acquire (line 515) | def acquire(self, blocking: bool = True, timeout: float = -1) -> bool: method release (line 530) | def release(self) -> None: method __enter__ (line 539) | def __enter__(self: Self) -> Self: method __exit__ (line 549) | def __exit__(self, exc_type: Any, exc_val: Any, exc_tb: Any) -> None: method locked (line 562) | def locked(self) -> bool: method owned (line 568) | def owned(self) -> bool: FILE: openhands-sdk/openhands/sdk/conversation/stuck_detector.py class StuckDetector (line 24) | class StuckDetector: method __init__ (line 38) | def __init__( method action_observation_threshold (line 47) | def action_observation_threshold(self) -> int: method action_error_threshold (line 51) | def action_error_threshold(self) -> int: method monologue_threshold (line 55) | def monologue_threshold(self) -> int: method alternating_pattern_threshold (line 59) | def alternating_pattern_threshold(self) -> int: method is_stuck (line 62) | def is_stuck(self) -> bool: method _is_stuck_repeating_action_observation (line 140) | def _is_stuck_repeating_action_observation( method _is_stuck_repeating_action_error (line 176) | def _is_stuck_repeating_action_error( method _is_stuck_monologue (line 200) | def _is_stuck_monologue(self, events: list[Event]) -> bool: method _is_stuck_alternating_action_observation (line 227) | def _is_stuck_alternating_action_observation(self, events: list[Event]... method _is_stuck_context_window_error (line 264) | def _is_stuck_context_window_error(self, _events: list[Event]) -> bool: method _event_eq (line 275) | def _event_eq(self, event1: Event, event2: Event) -> bool: FILE: openhands-sdk/openhands/sdk/conversation/title_utils.py function extract_message_text (line 32) | def extract_message_text(event: MessageEvent) -> str | None: function extract_first_user_message (line 45) | def extract_first_user_message(events: Sequence[Event]) -> str | None: function generate_title_with_llm (line 62) | def generate_title_with_llm(message: str, llm: LLM, max_length: int = 50... function generate_fallback_title (line 144) | def generate_fallback_title(message: str, max_length: int = 50) -> str: function generate_title_from_message (line 160) | def generate_title_from_message( function generate_conversation_title (line 177) | def generate_conversation_title( FILE: openhands-sdk/openhands/sdk/conversation/types.py function _validate_tags (line 25) | def _validate_tags(v: dict[str, str] | None) -> dict[str, str]: class StuckDetectionThresholds (line 48) | class StuckDetectionThresholds(BaseModel): FILE: openhands-sdk/openhands/sdk/conversation/visualizer/base.py class ConversationVisualizerBase (line 12) | class ConversationVisualizerBase(ABC): method __init__ (line 33) | def __init__(self): method initialize (line 38) | def initialize(self, state: "ConversationStateProtocol") -> None: method conversation_stats (line 53) | def conversation_stats(self) -> "ConversationStats | None": method on_event (line 58) | def on_event(self, event: Event) -> None: method create_sub_visualizer (line 69) | def create_sub_visualizer( FILE: openhands-sdk/openhands/sdk/conversation/visualizer/default.py class _EncodingSafeTextIO (line 61) | class _EncodingSafeTextIO: method encoding (line 67) | def encoding(self) -> str | None: method fileno (line 70) | def fileno(self) -> int: method flush (line 73) | def flush(self) -> None: method isatty (line 76) | def isatty(self) -> bool: method write (line 79) | def write(self, text: str) -> int: function _create_console (line 89) | def _create_console() -> Console: class EventVisualizationConfig (line 94) | class EventVisualizationConfig(BaseModel): function indent_content (line 115) | def indent_content(content: Text, spaces: int = 4) -> Text: function section_header (line 130) | def section_header(title: str, color: str) -> Rule: function build_event_block (line 140) | def build_event_block( function _get_action_title (line 172) | def _get_action_title(event: Event) -> str: function _get_message_title (line 179) | def _get_message_title(event: Event) -> str: function _get_message_color (line 190) | def _get_message_color(event: Event) -> str: class DefaultConversationVisualizer (line 256) | class DefaultConversationVisualizer(ConversationVisualizerBase): method __init__ (line 266) | def __init__( method on_event (line 286) | def on_event(self, event: Event) -> None: method _apply_highlighting (line 292) | def _apply_highlighting(self, text: Text) -> Text: method _create_event_block (line 314) | def _create_event_block(self, event: Event) -> Group | None: method _format_metrics_subtitle (line 367) | def _format_metrics_subtitle(self) -> str | None: FILE: openhands-sdk/openhands/sdk/critic/base.py class IterativeRefinementConfig (line 20) | class IterativeRefinementConfig(BaseModel): class CriticBase (line 57) | class CriticBase(DiscriminatedUnionMixin, abc.ABC): method evaluate (line 83) | def evaluate( method get_followup_prompt (line 88) | def get_followup_prompt(self, critic_result: CriticResult, iteration: ... method should_refine (line 109) | def should_refine(self, critic_result: CriticResult) -> bool: FILE: openhands-sdk/openhands/sdk/critic/impl/agent_finished.py class AgentFinishedCritic (line 24) | class AgentFinishedCritic(CriticBase): method evaluate (line 33) | def evaluate( method _has_finish_action (line 73) | def _has_finish_action(self, events: Sequence["LLMConvertibleEvent"]) ... FILE: openhands-sdk/openhands/sdk/critic/impl/api/chat_template.py function _get_cache_path (line 34) | def _get_cache_path(tokenizer_name: str) -> Path: function _fetch_tokenizer_config (line 41) | def _fetch_tokenizer_config( function _compile_jinja_template (line 82) | def _compile_jinja_template(chat_template: str) -> jinja2.Template: class ChatTemplateRenderer (line 120) | class ChatTemplateRenderer: method __init__ (line 128) | def __init__( method chat_template (line 160) | def chat_template(self) -> str: method apply_chat_template (line 165) | def apply_chat_template( function apply_chat_template (line 193) | def apply_chat_template( FILE: openhands-sdk/openhands/sdk/critic/impl/api/client.py class UsageTokens (line 33) | class UsageTokens(BaseModel): class ClassificationItem (line 41) | class ClassificationItem(BaseModel): class ClassificationResponse (line 51) | class ClassificationResponse(BaseModel): class LabelProbMap (line 61) | class LabelProbMap(BaseModel): class CriticClient (line 78) | class CriticClient(BaseModel): method _validate_and_convert_api_key (line 174) | def _validate_and_convert_api_key( method _serialize_api_key (line 181) | def _serialize_api_key(self, v: str | SecretStr | None, info): method all_labels (line 189) | def all_labels(self) -> tuple[str, ...]: method _get_template_renderer (line 203) | def _get_template_renderer(self) -> ChatTemplateRenderer: method normalize_messages (line 212) | def normalize_messages(messages: Sequence[dict]) -> Sequence[dict]: method apply_chat_template (line 229) | def apply_chat_template( method _get_api_key_value (line 250) | def _get_api_key_value(self) -> str: method classify_trace (line 262) | def classify_trace( method extract_prob_map (line 304) | def extract_prob_map(self, response: ClassificationResponse) -> LabelP... method predict_labels (line 334) | def predict_labels(self, probs: list[float], threshold: float = 0.5) -... FILE: openhands-sdk/openhands/sdk/critic/impl/api/critic.py function _format_feature_list (line 18) | def _format_feature_list(features: list[dict[str, Any]]) -> str: function _get_high_probability_agent_issues (line 30) | def _get_high_probability_agent_issues( class APIBasedCritic (line 47) | class APIBasedCritic(CriticBase, CriticClient): method evaluate (line 58) | def evaluate( method should_refine (line 135) | def should_refine(self, critic_result: CriticResult) -> bool: method get_followup_prompt (line 146) | def get_followup_prompt(self, critic_result: CriticResult, iteration: ... FILE: openhands-sdk/openhands/sdk/critic/impl/api/taxonomy.py function get_category (line 50) | def get_category(feature_name: str) -> str | None: function _softmax_normalize (line 62) | def _softmax_normalize(probs: dict[str, float]) -> dict[str, float]: function categorize_features (line 82) | def categorize_features( FILE: openhands-sdk/openhands/sdk/critic/impl/empty_patch.py class EmptyPatchCritic (line 18) | class EmptyPatchCritic(CriticBase): method evaluate (line 29) | def evaluate( FILE: openhands-sdk/openhands/sdk/critic/impl/pass_critic.py class PassCritic (line 18) | class PassCritic(CriticBase): method evaluate (line 26) | def evaluate( FILE: openhands-sdk/openhands/sdk/critic/result.py class CriticResult (line 7) | class CriticResult(BaseModel): method success (line 28) | def success(self) -> bool: method _get_star_rating (line 33) | def _get_star_rating(score: float) -> str: method _get_star_style (line 43) | def _get_star_style(score: float) -> str: method visualize (line 53) | def visualize(self) -> Text: method _append_categorized_features (line 78) | def _append_categorized_features( method _append_feature_list_inline (line 121) | def _append_feature_list_inline( FILE: openhands-sdk/openhands/sdk/event/acp_tool_call.py class ACPToolCallEvent (line 16) | class ACPToolCallEvent(Event): method visualize (line 38) | def visualize(self) -> Text: method __str__ (line 70) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/event/base.py class Event (line 20) | class Event(DiscriminatedUnionMixin, ABC): method visualize (line 35) | def visualize(self) -> Text: method __str__ (line 46) | def __str__(self) -> str: method __repr__ (line 50) | def __repr__(self) -> str: class LLMConvertibleEvent (line 58) | class LLMConvertibleEvent(Event, ABC): method to_llm_message (line 62) | def to_llm_message(self) -> Message: method __str__ (line 65) | def __str__(self) -> str: method events_to_messages (line 91) | def events_to_messages(events: list["LLMConvertibleEvent"]) -> list[Me... function _combine_action_events (line 129) | def _combine_action_events(events: list["ActionEvent"]) -> Message: FILE: openhands-sdk/openhands/sdk/event/condenser.py class Condensation (line 11) | class Condensation(Event): method visualize (line 40) | def visualize(self) -> Text: method summary_event (line 52) | def summary_event(self) -> CondensationSummaryEvent: method has_summary_metadata (line 79) | def has_summary_metadata(self) -> bool: method apply (line 83) | def apply(self, events: list[LLMConvertibleEvent]) -> list[LLMConverti... class CondensationRequest (line 99) | class CondensationRequest(Event): method visualize (line 109) | def visualize(self) -> Text: class CondensationSummaryEvent (line 120) | class CondensationSummaryEvent(LLMConvertibleEvent): method to_llm_message (line 128) | def to_llm_message(self) -> Message: FILE: openhands-sdk/openhands/sdk/event/conversation_error.py class ConversationErrorEvent (line 7) | class ConversationErrorEvent(Event): method visualize (line 29) | def visualize(self) -> Text: FILE: openhands-sdk/openhands/sdk/event/conversation_state.py class ConversationStateUpdateEvent (line 18) | class ConversationStateUpdateEvent(Event): method validate_key (line 39) | def validate_key(cls, key): method validate_value (line 51) | def validate_value(cls, value, info): method from_conversation_state (line 82) | def from_conversation_state( method __str__ (line 103) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/event/hook_execution.py class HookExecutionEvent (line 22) | class HookExecutionEvent(Event): method visualize (line 85) | def visualize(self) -> Text: method __str__ (line 123) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/event/llm_completion_log.py class LLMCompletionLogEvent (line 9) | class LLMCompletionLogEvent(Event): method __str__ (line 35) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/event/llm_convertible/action.py class ActionEvent (line 21) | class ActionEvent(LLMConvertibleEvent): method visualize (line 89) | def visualize(self) -> Text: method to_llm_message (line 140) | def to_llm_message(self) -> Message: method __str__ (line 151) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/event/llm_convertible/message.py class MessageEvent (line 21) | class MessageEvent(LLMConvertibleEvent): method reasoning_content (line 61) | def reasoning_content(self) -> str: method thinking_blocks (line 65) | def thinking_blocks(self) -> Sequence[ThinkingBlock | RedactedThinking... method visualize (line 70) | def visualize(self) -> Text: method to_llm_message (line 116) | def to_llm_message(self) -> Message: method __str__ (line 121) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/event/llm_convertible/observation.py class ObservationBaseEvent (line 16) | class ObservationBaseEvent(LLMConvertibleEvent): class ObservationEvent (line 31) | class ObservationEvent(ObservationBaseEvent): method visualize (line 40) | def visualize(self) -> Text: method to_llm_message (line 51) | def to_llm_message(self) -> Message: method __str__ (line 59) | def __str__(self) -> str: class UserRejectObservation (line 71) | class UserRejectObservation(ObservationBaseEvent): method visualize (line 95) | def visualize(self) -> Text: method to_llm_message (line 104) | def to_llm_message(self) -> Message: method __str__ (line 112) | def __str__(self) -> str: class AgentErrorEvent (line 123) | class AgentErrorEvent(ObservationBaseEvent): method visualize (line 134) | def visualize(self) -> Text: method to_llm_message (line 141) | def to_llm_message(self) -> Message: method __str__ (line 151) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/event/llm_convertible/system.py class SystemPromptEvent (line 12) | class SystemPromptEvent(LLMConvertibleEvent): method visualize (line 44) | def visualize(self) -> Text: method to_llm_message (line 72) | def to_llm_message(self) -> Message: method __str__ (line 87) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/event/streaming_delta.py class StreamingDeltaEvent (line 5) | class StreamingDeltaEvent(Event): FILE: openhands-sdk/openhands/sdk/event/token.py class TokenEvent (line 7) | class TokenEvent(Event): FILE: openhands-sdk/openhands/sdk/event/user_action.py class PauseEvent (line 7) | class PauseEvent(Event): method visualize (line 13) | def visualize(self) -> Text: method __str__ (line 19) | def __str__(self) -> str: FILE: openhands-sdk/openhands/sdk/extensions/fetch.py class ExtensionFetchError (line 16) | class ExtensionFetchError(Exception): class SourceType (line 20) | class SourceType(StrEnum): function parse_extension_source (line 33) | def parse_extension_source(source: str) -> tuple[SourceType, str]: function _resolve_local_source (line 92) | def _resolve_local_source(url: str) -> Path: function _apply_subpath (line 110) | def _apply_subpath(base_path: Path, subpath: str | None, context: str) -... function fetch (line 133) | def fetch( function fetch_with_resolution (line 165) | def fetch_with_resolution( function get_cache_path (line 209) | def get_cache_path(source: str, cache_dir: Path) -> Path: function _fetch_remote_source_with_resolution (line 231) | def _fetch_remote_source_with_resolution( FILE: openhands-sdk/openhands/sdk/extensions/installation/info.py class InstallationInfo (line 11) | class InstallationInfo(BaseModel): method from_extension (line 40) | def from_extension( FILE: openhands-sdk/openhands/sdk/extensions/installation/interface.py class ExtensionProtocol (line 6) | class ExtensionProtocol(Protocol): method name (line 15) | def name(self) -> str: ... method version (line 18) | def version(self) -> str: ... method description (line 21) | def description(self) -> str | None: ... class InstallationInterface (line 24) | class InstallationInterface[T: ExtensionProtocol](ABC): method load_from_dir (line 33) | def load_from_dir(extension_dir: Path) -> T: ... FILE: openhands-sdk/openhands/sdk/extensions/installation/manager.py class InstallationManager (line 27) | class InstallationManager[T: ExtensionProtocol]: method __post_init__ (line 43) | def __post_init__(self) -> None: method metadata_session (line 47) | def metadata_session(self) -> MetadataSession: method install (line 53) | def install( method uninstall (line 132) | def uninstall(self, name: str) -> bool: method _set_enabled (line 170) | def _set_enabled( method enable (line 214) | def enable(self, name: str) -> bool: method disable (line 218) | def disable(self, name: str) -> bool: method list_installed (line 222) | def list_installed(self) -> list[InstallationInfo]: method load_installed (line 238) | def load_installed(self) -> list[T]: method get (line 264) | def get(self, name: str) -> InstallationInfo | None: method update (line 291) | def update(self, name: str) -> InstallationInfo | None: FILE: openhands-sdk/openhands/sdk/extensions/installation/metadata.py class MetadataSession (line 20) | class MetadataSession: method __init__ (line 30) | def __init__( method extensions (line 41) | def extensions(self) -> dict[str, InstallationInfo]: method sync (line 44) | def sync(self) -> list[InstallationInfo]: method __enter__ (line 67) | def __enter__(self) -> MetadataSession: method __exit__ (line 70) | def __exit__( class InstallationMetadata (line 80) | class InstallationMetadata(BaseModel): method _migrate_legacy_keys (line 101) | def _migrate_legacy_keys(cls, data: Any) -> Any: method open (line 123) | def open( method get_metadata_path (line 141) | def get_metadata_path(cls, installed_dir: Path) -> Path: method load_from_dir (line 146) | def load_from_dir(cls, installed_dir: Path) -> InstallationMetadata: method save_to_dir (line 158) | def save_to_dir(self, installed_dir: Path) -> None: method validate_tracked (line 164) | def validate_tracked(self, installed_dir: Path) -> list[InstallationIn... method discover_untracked (line 197) | def discover_untracked( FILE: openhands-sdk/openhands/sdk/extensions/installation/utils.py function validate_extension_name (line 8) | def validate_extension_name(name: str) -> None: FILE: openhands-sdk/openhands/sdk/git/cached_repo.py class GitHelper (line 26) | class GitHelper: method clone (line 33) | def clone( method fetch (line 69) | def fetch( method checkout (line 93) | def checkout(self, repo_path: Path, ref: str, timeout: int = 30) -> None: method reset_hard (line 106) | def reset_hard(self, repo_path: Path, ref: str, timeout: int = 30) -> ... method get_current_branch (line 119) | def get_current_branch(self, repo_path: Path, timeout: int = 10) -> st... method get_default_branch (line 140) | def get_default_branch(self, repo_path: Path, timeout: int = 10) -> st... method get_head_commit (line 173) | def get_head_commit(self, repo_path: Path, timeout: int = 10) -> str: function try_cached_clone_or_update (line 193) | def try_cached_clone_or_update( function _do_clone_or_update (line 256) | def _do_clone_or_update( function _clone_repository (line 294) | def _clone_repository( function _update_repository (line 316) | def _update_repository( function _try_fetch (line 367) | def _try_fetch(repo_path: Path, git: GitHelper) -> bool: function _try_checkout_and_reset (line 377) | def _try_checkout_and_reset(repo_path: Path, ref: str, git: GitHelper) -... function _try_reset_to_origin (line 386) | def _try_reset_to_origin(repo_path: Path, branch: str, git: GitHelper) -... function _recover_from_detached_head (line 397) | def _recover_from_detached_head(repo_path: Path, git: GitHelper) -> None: function _checkout_ref (line 434) | def _checkout_ref(repo_path: Path, ref: str, git: GitHelper) -> None: FILE: openhands-sdk/openhands/sdk/git/exceptions.py class GitError (line 4) | class GitError(Exception): class GitRepositoryError (line 10) | class GitRepositoryError(GitError): method __init__ (line 16) | def __init__( class GitCommandError (line 24) | class GitCommandError(GitError): method __init__ (line 31) | def __init__( class GitPathError (line 40) | class GitPathError(GitError): FILE: openhands-sdk/openhands/sdk/git/git_changes.py function _map_git_status_to_enum (line 24) | def _map_git_status_to_enum(status: str) -> GitChangeStatus: function get_changes_in_repo (line 37) | def get_changes_in_repo( function get_git_changes (line 205) | def get_git_changes(cwd: str | Path, ref: str | None = None) -> list[Git... FILE: openhands-sdk/openhands/sdk/git/git_diff.py function get_closest_git_repo (line 29) | def get_closest_git_repo(path: Path) -> Path | None: function get_git_diff (line 53) | def get_git_diff(relative_file_path: str | Path, ref: str | None = None)... FILE: openhands-sdk/openhands/sdk/git/models.py class GitChangeStatus (line 9) | class GitChangeStatus(Enum): class GitChange (line 16) | class GitChange(BaseModel): method _serialize_path (line 21) | def _serialize_path(self, path: Path) -> str: class GitDiff (line 25) | class GitDiff(BaseModel): FILE: openhands-sdk/openhands/sdk/git/utils.py function run_git_command (line 17) | def run_git_command( function _repo_has_commits (line 82) | def _repo_has_commits(repo_dir: str | Path) -> bool: function get_valid_ref (line 104) | def get_valid_ref(repo_dir: str | Path, override: str | None = None) -> ... function validate_git_repository (line 245) | def validate_git_repository(repo_dir: str | Path) -> Path: function is_git_url (line 282) | def is_git_url(source: str) -> bool: function normalize_git_url (line 321) | def normalize_git_url(url: str) -> str: function extract_repo_name (line 344) | def extract_repo_name(source: str) -> str: FILE: openhands-sdk/openhands/sdk/hooks/config.py function _pascal_to_snake (line 18) | def _pascal_to_snake(name: str) -> str: class HookType (line 39) | class HookType(StrEnum): class HookDefinition (line 46) | class HookDefinition(BaseModel): method _set_command_for_prompt_hooks (line 61) | def _set_command_for_prompt_hooks(cls, data: Any) -> Any: method _check_required_fields (line 71) | def _check_required_fields(self) -> "HookDefinition": class HookMatcher (line 79) | class HookMatcher(BaseModel): method matches (line 91) | def matches(self, tool_name: str | None) -> bool: class HookConfig (line 125) | class HookConfig(BaseModel): method is_empty (line 174) | def is_empty(self) -> bool: method _normalize_hooks_input (line 189) | def _normalize_hooks_input(cls, data: Any) -> Any: method load (line 239) | def load( method from_dict (line 274) | def from_dict(cls, data: dict[str, Any]) -> "HookConfig": method _get_matchers_for_event (line 286) | def _get_matchers_for_event(self, event_type: HookEventType) -> list[H... method get_hooks_for_event (line 291) | def get_hooks_for_event( method has_hooks_for_event (line 304) | def has_hooks_for_event(self, event_type: HookEventType) -> bool: method save (line 309) | def save(self, path: str | Path) -> None: method merge (line 318) | def merge(cls, configs: list["HookConfig"]) -> "HookConfig | None": FILE: openhands-sdk/openhands/sdk/hooks/conversation_hooks.py function _truncate_hook_log (line 32) | def _truncate_hook_log(value: str | None) -> str | None: class HookEventProcessor (line 46) | class HookEventProcessor: method __init__ (line 55) | def __init__( method set_conversation_state (line 66) | def set_conversation_state(self, state: "ConversationState") -> None: method _emit_hook_execution_event (line 70) | def _emit_hook_execution_event( method on_event (line 102) | def on_event(self, event: Event) -> None: method _handle_pre_tool_use (line 123) | def _handle_pre_tool_use(self, event: ActionEvent) -> None: method _handle_post_tool_use (line 175) | def _handle_post_tool_use(self, event: ObservationEvent) -> None: method _handle_user_prompt_submit (line 240) | def _handle_user_prompt_submit(self, event: MessageEvent) -> MessageEv... method is_action_blocked (line 309) | def is_action_blocked(self, action_id: str) -> bool: method is_message_blocked (line 315) | def is_message_blocked(self, message_id: str) -> bool: method run_session_start (line 321) | def run_session_start(self) -> None: method run_session_end (line 337) | def run_session_end(self) -> None: method run_stop (line 351) | def run_stop(self, reason: str | None = None) -> tuple[bool, str | None]: function create_hook_callback (line 386) | def create_hook_callback( FILE: openhands-sdk/openhands/sdk/hooks/executor.py class HookResult (line 17) | class HookResult(BaseModel): method should_continue (line 44) | def should_continue(self) -> bool: class AsyncProcessManager (line 56) | class AsyncProcessManager: method __init__ (line 64) | def __init__(self): method add_process (line 67) | def add_process(self, process: subprocess.Popen, timeout: int) -> None: method _terminate_process (line 76) | def _terminate_process(self, process: subprocess.Popen) -> None: method cleanup_expired (line 118) | def cleanup_expired(self) -> None: method cleanup_all (line 132) | def cleanup_all(self) -> None: class HookExecutor (line 140) | class HookExecutor: method __init__ (line 143) | def __init__( method execute (line 151) | def execute( method execute_all (line 293) | def execute_all( FILE: openhands-sdk/openhands/sdk/hooks/manager.py class HookManager (line 14) | class HookManager: method __init__ (line 17) | def __init__( method _create_event (line 28) | def _create_event( method run_pre_tool_use (line 49) | def run_pre_tool_use( method run_post_tool_use (line 80) | def run_post_tool_use( method run_user_prompt_submit (line 101) | def run_user_prompt_submit( method run_session_start (line 130) | def run_session_start(self) -> list[HookResult]: method run_session_end (line 139) | def run_session_end(self) -> list[HookResult]: method cleanup_async_processes (line 152) | def cleanup_async_processes(self) -> None: method run_stop (line 156) | def run_stop( method has_hooks (line 177) | def has_hooks(self, event_type: HookEventType) -> bool: method get_blocking_reason (line 181) | def get_blocking_reason(self, results: list[HookResult]) -> str | None: FILE: openhands-sdk/openhands/sdk/hooks/types.py class HookEventType (line 9) | class HookEventType(str, Enum): class HookEvent (line 20) | class HookEvent(BaseModel): class HookDecision (line 35) | class HookDecision(str, Enum): FILE: openhands-sdk/openhands/sdk/io/base.py class FileStore (line 6) | class FileStore(ABC): method write (line 17) | def write(self, path: str, contents: str | bytes) -> None: method read (line 26) | def read(self, path: str) -> str: method list (line 37) | def list(self, path: str) -> list[str]: method delete (line 48) | def delete(self, path: str) -> None: method exists (line 56) | def exists(self, path: str) -> bool: method get_absolute_path (line 67) | def get_absolute_path(self, path: str) -> str: method lock (line 79) | def lock(self, path: str, timeout: float = 30.0) -> Iterator[None]: FILE: openhands-sdk/openhands/sdk/io/cache.py class MemoryLRUCache (line 11) | class MemoryLRUCache(LRUCache): method __init__ (line 24) | def __init__(self, max_memory: int, max_size: int, *args, **kwargs): method _get_size (line 31) | def _get_size(self, value: Any) -> int: method __setitem__ (line 55) | def __setitem__(self, key: Any, value: Any) -> None: method __delitem__ (line 80) | def __delitem__(self, key: Any) -> None: FILE: openhands-sdk/openhands/sdk/io/local.py class LocalFileStore (line 18) | class LocalFileStore(FileStore): method __init__ (line 22) | def __init__( method get_full_path (line 46) | def get_full_path(self, path: str) -> str: method write (line 61) | def write(self, path: str, contents: str | bytes) -> None: method read (line 74) | def read(self, path: str) -> str: method list (line 89) | def list(self, path: str) -> list[str]: method delete (line 103) | def delete(self, path: str) -> None: method exists (line 122) | def exists(self, path: str) -> bool: method get_absolute_path (line 126) | def get_absolute_path(self, path: str) -> str: method lock (line 131) | def lock(self, path: str, timeout: float = 30.0) -> Iterator[None]: FILE: openhands-sdk/openhands/sdk/io/memory.py class InMemoryFileStore (line 19) | class InMemoryFileStore(FileStore): method __init__ (line 24) | def __init__( method write (line 38) | def write(self, path: str, contents: str | bytes) -> None: method read (line 43) | def read(self, path: str) -> str: method list (line 48) | def list(self, path: str) -> list[str]: method delete (line 67) | def delete(self, path: str) -> None: method exists (line 76) | def exists(self, path: str) -> bool: method get_absolute_path (line 82) | def get_absolute_path(self, path: str) -> str: method lock (line 91) | def lock(self, path: str, timeout: float = 30.0) -> Iterator[None]: FILE: openhands-sdk/openhands/sdk/llm/auth/credentials.py function get_credentials_dir (line 20) | def get_credentials_dir() -> Path: class OAuthCredentials (line 28) | class OAuthCredentials(BaseModel): method is_expired (line 39) | def is_expired(self) -> bool: class CredentialStore (line 46) | class CredentialStore: method __init__ (line 49) | def __init__(self, credentials_dir: Path | None = None): method credentials_dir (line 60) | def credentials_dir(self) -> Path: method _get_credentials_file (line 68) | def _get_credentials_file(self, vendor: str) -> Path: method get (line 72) | def get(self, vendor: str) -> OAuthCredentials | None: method save (line 94) | def save(self, credentials: OAuthCredentials) -> None: method delete (line 113) | def delete(self, vendor: str) -> bool: method update_tokens (line 128) | def update_tokens( FILE: openhands-sdk/openhands/sdk/llm/auth/openai.py function _get_consent_marker_path (line 62) | def _get_consent_marker_path() -> Path: function _has_acknowledged_consent (line 67) | def _has_acknowledged_consent() -> bool: function _mark_consent_acknowledged (line 72) | def _mark_consent_acknowledged() -> None: function _display_consent_and_confirm (line 79) | def _display_consent_and_confirm() -> bool: class _JWKSCache (line 144) | class _JWKSCache: method __init__ (line 147) | def __init__(self) -> None: method get_key_set (line 152) | def get_key_set(self) -> jwk.KeySet: method _fetch_jwks (line 170) | def _fetch_jwks(self) -> None: method clear (line 184) | def clear(self) -> None: function _generate_pkce (line 194) | def _generate_pkce() -> tuple[str, str]: function _extract_chatgpt_account_id (line 201) | def _extract_chatgpt_account_id(access_token: str) -> str | None: function _build_authorize_url (line 246) | def _build_authorize_url(redirect_uri: str, code_challenge: str, state: ... function _exchange_code_for_tokens (line 263) | async def _exchange_code_for_tokens( class DeviceCode (line 285) | class DeviceCode: function _request_device_code (line 294) | async def _request_device_code() -> DeviceCode: function _poll_device_code (line 332) | async def _poll_device_code(device_code: DeviceCode) -> dict[str, Any]: function _refresh_access_token (line 361) | async def _refresh_access_token(refresh_token: str) -> dict[str, Any]: class OpenAISubscriptionAuth (line 427) | class OpenAISubscriptionAuth: method __init__ (line 430) | def __init__( method vendor (line 445) | def vendor(self) -> str: method get_credentials (line 449) | def get_credentials(self) -> OAuthCredentials | None: method has_valid_credentials (line 453) | def has_valid_credentials(self) -> bool: method refresh_if_needed (line 458) | async def refresh_if_needed(self) -> OAuthCredentials | None: method login (line 484) | async def login( method _login_with_device_code (line 626) | async def _login_with_device_code(self) -> OAuthCredentials: method logout (line 666) | def logout(self) -> bool: method create_llm (line 674) | def create_llm( function subscription_login_async (line 752) | async def subscription_login_async( function subscription_login (line 812) | def subscription_login( function inject_system_prefix (line 848) | def inject_system_prefix( function transform_for_subscription (line 872) | def transform_for_subscription( FILE: openhands-sdk/openhands/sdk/llm/exceptions/classifier.py function is_context_window_exceeded (line 50) | def is_context_window_exceeded(exception: Exception) -> bool: function looks_like_malformed_conversation_history_error (line 64) | def looks_like_malformed_conversation_history_error(exception: Exception... function looks_like_auth_error (line 84) | def looks_like_auth_error(exception: Exception) -> bool: FILE: openhands-sdk/openhands/sdk/llm/exceptions/mapping.py function map_provider_exception (line 28) | def map_provider_exception(exception: Exception) -> Exception: FILE: openhands-sdk/openhands/sdk/llm/exceptions/types.py class LLMError (line 1) | class LLMError(Exception): method __init__ (line 4) | def __init__(self, message: str) -> None: method __str__ (line 8) | def __str__(self) -> str: class LLMMalformedActionError (line 13) | class LLMMalformedActionError(LLMError): method __init__ (line 14) | def __init__(self, message: str = "Malformed response") -> None: class LLMNoActionError (line 18) | class LLMNoActionError(LLMError): method __init__ (line 19) | def __init__(self, message: str = "Agent must return an action") -> None: class LLMResponseError (line 23) | class LLMResponseError(LLMError): method __init__ (line 24) | def __init__( class FunctionCallConversionError (line 31) | class FunctionCallConversionError(LLMError): method __init__ (line 32) | def __init__(self, message: str) -> None: class FunctionCallValidationError (line 36) | class FunctionCallValidationError(LLMError): method __init__ (line 37) | def __init__(self, message: str) -> None: class FunctionCallNotExistsError (line 41) | class FunctionCallNotExistsError(LLMError): method __init__ (line 42) | def __init__(self, message: str) -> None: class LLMNoResponseError (line 47) | class LLMNoResponseError(LLMError): method __init__ (line 48) | def __init__( class LLMContextWindowExceedError (line 57) | class LLMContextWindowExceedError(LLMError): method __init__ (line 58) | def __init__( class LLMMalformedConversationHistoryError (line 68) | class LLMMalformedConversationHistoryError(LLMError): method __init__ (line 69) | def __init__( class LLMContextWindowTooSmallError (line 80) | class LLMContextWindowTooSmallError(LLMError): method __init__ (line 83) | def __init__( class LLMAuthenticationError (line 109) | class LLMAuthenticationError(LLMError): method __init__ (line 110) | def __init__(self, message: str = "Invalid or missing API credentials"... class LLMRateLimitError (line 114) | class LLMRateLimitError(LLMError): method __init__ (line 115) | def __init__(self, message: str = "Rate limit exceeded") -> None: class LLMTimeoutError (line 119) | class LLMTimeoutError(LLMError): method __init__ (line 120) | def __init__(self, message: str = "LLM request timed out") -> None: class LLMServiceUnavailableError (line 124) | class LLMServiceUnavailableError(LLMError): method __init__ (line 125) | def __init__(self, message: str = "LLM service unavailable") -> None: class LLMBadRequestError (line 129) | class LLMBadRequestError(LLMError): method __init__ (line 130) | def __init__(self, message: str = "Bad request to LLM provider") -> None: class UserCancelledError (line 135) | class UserCancelledError(Exception): method __init__ (line 136) | def __init__(self, message: str = "User cancelled the request") -> None: class OperationCancelled (line 140) | class OperationCancelled(Exception): method __init__ (line 141) | def __init__(self, message: str = "Operation was cancelled") -> None: FILE: openhands-sdk/openhands/sdk/llm/fallback_strategy.py class FallbackStrategy (line 39) | class FallbackStrategy(BaseModel): method should_fallback (line 59) | def should_fallback(self, error: Exception) -> bool: method try_fallback (line 63) | def try_fallback( method _profile_store (line 121) | def _profile_store(self) -> LLMProfileStore: method _iter_fallbacks (line 124) | def _iter_fallbacks(self) -> Generator[Any]: FILE: openhands-sdk/openhands/sdk/llm/llm.py class LLM (line 148) | class LLM(BaseModel, RetryMixin, NonNativeToolCallingMixin): method _validate_secrets (line 475) | def _validate_secrets(cls, v: str | SecretStr | None, info) -> SecretS... method _coerce_inputs (line 480) | def _coerce_inputs(cls, data): method _post_init (line 511) | def _post_init(self): method _openrouter_headers (line 551) | def _openrouter_headers(self) -> dict[str, str]: method _aws_kwargs (line 566) | def _aws_kwargs(self) -> dict[str, str]: method _retry_listener_fn (line 590) | def _retry_listener_fn( method _serialize_secrets (line 605) | def _serialize_secrets(self, v: SecretStr | None, info): method metrics (line 612) | def metrics(self) -> Metrics: method telemetry (line 629) | def telemetry(self) -> Telemetry: method is_subscription (line 652) | def is_subscription(self) -> bool: method restore_metrics (line 664) | def restore_metrics(self, metrics: Metrics) -> None: method reset_metrics (line 672) | def reset_metrics(self) -> None: method _handle_error (line 688) | def _handle_error( method completion (line 714) | def completion( method responses (line 891) | def responses( method _infer_litellm_provider (line 1116) | def _infer_litellm_provider(self) -> str | None: method _infer_model_info_provider (line 1124) | def _infer_model_info_provider(self) -> str | None: method _get_litellm_api_key_value (line 1132) | def _get_litellm_api_key_value(self) -> str | None: method _transport_call (line 1147) | def _transport_call( method _litellm_modify_params_ctx (line 1215) | def _litellm_modify_params_ctx(self, flag: bool): method _model_name_for_capabilities (line 1227) | def _model_name_for_capabilities(self) -> str: method _init_model_info_and_caps (line 1231) | def _init_model_info_and_caps(self) -> None: method _validate_context_window_size (line 1332) | def _validate_context_window_size(self) -> None: method vision_is_active (line 1352) | def vision_is_active(self) -> bool: method _supports_vision (line 1357) | def _supports_vision(self) -> bool: method is_caching_prompt_active (line 1380) | def is_caching_prompt_active(self) -> bool: method uses_responses_api (line 1396) | def uses_responses_api(self) -> bool: method model_info (line 1403) | def model_info(self) -> dict | None: method effective_max_input_tokens (line 1408) | def effective_max_input_tokens(self) -> int | None: method effective_max_output_tokens (line 1417) | def effective_max_output_tokens(self) -> int | None: method _apply_prompt_caching (line 1428) | def _apply_prompt_caching(self, messages: list[Message]) -> None: method format_messages_for_llm (line 1457) | def format_messages_for_llm(self, messages: list[Message]) -> list[dict]: method format_messages_for_responses (line 1494) | def format_messages_for_responses( method get_token_count (line 1543) | def get_token_count(self, messages: list[Message]) -> int: method from_persisted (line 1569) | def from_persisted(cls, data: Any, *, context: dict[str, Any] | None =... method to_persisted (line 1588) | def to_persisted(self, *, context: dict[str, Any] | None = None) -> di... method load_from_json (line 1598) | def load_from_json( method load_from_env (line 1616) | def load_from_env(cls, prefix: str = "LLM_") -> LLM: method subscription_login (line 1671) | def subscription_login( FILE: openhands-sdk/openhands/sdk/llm/llm_profile_store.py class ProfileLimitExceeded (line 35) | class ProfileLimitExceeded(Exception): class LLMProfileStore (line 39) | class LLMProfileStore: method __init__ (line 42) | def __init__(self, base_dir: Path | str | None = None) -> None: method _acquire_lock (line 56) | def _acquire_lock(self, timeout: float = _LOCK_TIMEOUT_SECONDS) -> Ite... method list (line 74) | def list(self) -> list[str]: method _get_profile_path (line 83) | def _get_profile_path(self, name: str) -> Path: method save (line 101) | def save( method load (line 172) | def load(self, name: str, *, cipher: Cipher | None = None) -> LLM: method delete (line 211) | def delete(self, name: str) -> None: method rename (line 232) | def rename(self, old_name: str, new_name: str) -> None: method list_summaries (line 252) | def list_summaries(self) -> list[dict[str, Any]]: FILE: openhands-sdk/openhands/sdk/llm/llm_registry.py class RegistryEvent (line 15) | class RegistryEvent(BaseModel): class LLMRegistry (line 23) | class LLMRegistry: method __init__ (line 38) | def __init__( method subscribe (line 54) | def subscribe(self, callback: Callable[[RegistryEvent], None]) -> None: method notify (line 62) | def notify(self, event: RegistryEvent) -> None: method usage_to_llm (line 75) | def usage_to_llm(self) -> MappingProxyType[str, LLM]: method _ensure_independent_metrics (line 80) | def _ensure_independent_metrics(self, llm: LLM) -> None: method add (line 108) | def add(self, llm: LLM) -> None: method get (line 140) | def get(self, usage_id: str) -> LLM: method list_usage_ids (line 163) | def list_usage_ids(self) -> list[str]: FILE: openhands-sdk/openhands/sdk/llm/llm_response.py class LLMResponse (line 28) | class LLMResponse(BaseModel): method id (line 49) | def id(self) -> str: FILE: openhands-sdk/openhands/sdk/llm/message.py class MessageToolCall (line 24) | class MessageToolCall(BaseModel): method from_chat_tool_call (line 43) | def from_chat_tool_call( method from_responses_function_call (line 65) | def from_responses_function_call( method to_chat_dict (line 89) | def to_chat_dict(self) -> dict[str, Any]: method to_responses_dict (line 100) | def to_responses_dict(self) -> dict[str, Any]: class ThinkingBlock (line 122) | class ThinkingBlock(BaseModel): class RedactedThinkingBlock (line 137) | class RedactedThinkingBlock(BaseModel): class ReasoningItemModel (line 148) | class ReasoningItemModel(BaseModel): class BaseContent (line 161) | class BaseContent(BaseModel): method to_llm_dict (line 165) | def to_llm_dict(self) -> list[dict[str, str | dict[str, str]]]: class TextContent (line 173) | class TextContent(BaseContent): method _handle_deprecated_fields (line 189) | def _handle_deprecated_fields(cls, data: Any) -> Any: method to_llm_dict (line 193) | def to_llm_dict(self) -> list[dict[str, str | dict[str, str]]]: class ImageContent (line 204) | class ImageContent(BaseContent): method to_llm_dict (line 208) | def to_llm_dict(self) -> list[dict[str, str | dict[str, str]]]: class Message (line 218) | class Message(BaseModel): method _handle_deprecated_fields (line 259) | def _handle_deprecated_fields(cls, data: Any) -> Any: method contains_image (line 264) | def contains_image(self) -> bool: method _coerce_content (line 269) | def _coerce_content(cls, v: Any) -> Sequence[TextContent | ImageConten... method to_chat_dict (line 278) | def to_chat_dict( method _string_serializer (line 328) | def _string_serializer(self) -> dict[str, Any]: method _list_serializer (line 340) | def _list_serializer(self, *, vision_enabled: bool) -> dict[str, Any]: method _remove_content_if_empty (line 390) | def _remove_content_if_empty(self, message_dict: dict[str, Any]) -> None: method to_responses_value (line 436) | def to_responses_value(self, *, vision_enabled: bool) -> str | list[di... method to_responses_dict (line 448) | def to_responses_dict(self, *, vision_enabled: bool) -> list[dict[str,... method _maybe_truncate_tool_text (line 461) | def _maybe_truncate_tool_text(self, text: str) -> str: method from_llm_chat_message (line 472) | def from_llm_chat_message(cls, message: LiteLLMMessage) -> "Message": method from_llm_responses_output (line 531) | def from_llm_responses_output( function content_to_str (line 615) | def content_to_str(contents: Sequence[TextContent | ImageContent]) -> li... FILE: openhands-sdk/openhands/sdk/llm/mixins/fn_call_converter.py class CacheControl (line 24) | class CacheControl(TypedDict): class TextPart (line 28) | class TextPart(TypedDict): function convert_tool_call_to_string (line 92) | def convert_tool_call_to_string(tool_call: dict) -> str: function _summarize_schema_type (line 122) | def _summarize_schema_type(schema: object | None) -> str: function _indent (line 151) | def _indent(indent: int) -> str: function _nested_indent (line 155) | def _nested_indent(indent: int, levels: int = 1) -> int: function _get_description (line 159) | def _get_description(schema: dict[str, object] | None) -> str: function _format_union_details (line 171) | def _format_union_details(schema: dict[str, object], indent: int) -> lis... function _format_array_details (line 189) | def _format_array_details(schema: dict[str, object], indent: int) -> lis... function _format_additional_properties (line 209) | def _format_additional_properties( function _format_object_details (line 227) | def _format_object_details(schema: dict[str, Any], indent: int) -> list[... function _format_schema_detail (line 248) | def _format_schema_detail(schema: object | None, indent: int = 4) -> lis... function convert_tools_to_description (line 271) | def convert_tools_to_description(tools: list[ChatCompletionToolParam]) -... function _build_system_message_suffix (line 315) | def _build_system_message_suffix( function _append_to_content (line 329) | def _append_to_content(content: Content, suffix: str) -> Content: function _prepend_to_content (line 344) | def _prepend_to_content(content: Content, prefix: str) -> Content: function _wrap_content_with_example (line 359) | def _wrap_content_with_example( function _convert_system_to_non_fncall (line 382) | def _convert_system_to_non_fncall( function _convert_user_to_non_fncall (line 391) | def _convert_user_to_non_fncall( function _convert_assistant_to_non_fncall (line 407) | def _convert_assistant_to_non_fncall( function _convert_tool_to_non_fncall (line 447) | def _convert_tool_to_non_fncall(message: dict, content: Content) -> dict: function convert_fncall_messages_to_non_fncall_messages (line 471) | def convert_fncall_messages_to_non_fncall_messages( function _extract_and_validate_params (line 516) | def _extract_and_validate_params( function _preprocess_model_output (line 577) | def _preprocess_model_output(content: str) -> str: function _fix_stopword (line 595) | def _fix_stopword(content: str) -> str: function _normalize_parameter_tags (line 606) | def _normalize_parameter_tags(fn_body: str) -> str: function _find_tool (line 635) | def _find_tool( function _resolve_tool_name (line 650) | def _resolve_tool_name( function _remove_suffix_from_content (line 673) | def _remove_suffix_from_content(content: Content, suffix: str) -> Content: function _strip_in_context_example (line 682) | def _strip_in_context_example( function _find_tool_result_match (line 702) | def _find_tool_result_match(content: Content) -> re.Match | None: function _convert_system_to_fncall (line 725) | def _convert_system_to_fncall(content: Content, system_message_suffix: s... function _convert_user_to_fncall (line 731) | def _convert_user_to_fncall( function _find_function_match (line 772) | def _find_function_match(content: Content) -> tuple[Content, re.Match | ... function _strip_function_call_from_content (line 804) | def _strip_function_call_from_content(content: Content) -> Content: function _convert_assistant_to_fncall (line 818) | def _convert_assistant_to_fncall( function convert_non_fncall_messages_to_fncall_messages (line 860) | def convert_non_fncall_messages_to_fncall_messages( function convert_from_multiple_tool_calls_to_single_tool_call_messages (line 906) | def convert_from_multiple_tool_calls_to_single_tool_call_messages( FILE: openhands-sdk/openhands/sdk/llm/mixins/fn_call_examples.py function _refine_prompt (line 24) | def _refine_prompt(prompt: str) -> str: function get_example_for_tools (line 333) | def get_example_for_tools(tools: list[ChatCompletionToolParam]) -> str: FILE: openhands-sdk/openhands/sdk/llm/mixins/non_native_fc.py class _HostSupports (line 18) | class _HostSupports(Protocol): class NonNativeToolCallingMixin (line 24) | class NonNativeToolCallingMixin: method should_mock_tool_calls (line 33) | def should_mock_tool_calls( method pre_request_prompt_mock (line 38) | def pre_request_prompt_mock( method post_response_prompt_mock (line 65) | def post_response_prompt_mock( FILE: openhands-sdk/openhands/sdk/llm/options/chat_options.py function select_chat_options (line 9) | def select_chat_options( FILE: openhands-sdk/openhands/sdk/llm/options/common.py function apply_defaults_if_absent (line 6) | def apply_defaults_if_absent( FILE: openhands-sdk/openhands/sdk/llm/options/responses_options.py function select_responses_options (line 9) | def select_responses_options( FILE: openhands-sdk/openhands/sdk/llm/router/base.py class RouterLLM (line 21) | class RouterLLM(LLM): method validate_llms_not_empty (line 43) | def validate_llms_not_empty(cls, v): method completion (line 50) | def completion( method select_llm (line 92) | def select_llm(self, messages: list[Message]) -> str: method __getattr__ (line 107) | def __getattr__(self, name): method __str__ (line 113) | def __str__(self) -> str: method set_placeholder_model (line 119) | def set_placeholder_model(cls, data): FILE: openhands-sdk/openhands/sdk/llm/router/impl/multimodal.py class MultimodalRouter (line 13) | class MultimodalRouter(RouterLLM): method select_llm (line 29) | def select_llm(self, messages: list[Message]) -> str: method _validate_llms_for_routing (line 65) | def _validate_llms_for_routing(self) -> "MultimodalRouter": FILE: openhands-sdk/openhands/sdk/llm/router/impl/random.py class RandomRouter (line 11) | class RandomRouter(RouterLLM): method select_llm (line 19) | def select_llm(self, messages: list[Message]) -> str: # noqa: ARG002 FILE: openhands-sdk/openhands/sdk/llm/utils/image_resize.py function maybe_resize_messages_for_provider (line 24) | def maybe_resize_messages_for_provider( function _get_image_max_dimension (line 47) | def _get_image_max_dimension( function _resize_base64_data_url (line 67) | def _resize_base64_data_url(url: str, *, max_dimension: int) -> str: FILE: openhands-sdk/openhands/sdk/llm/utils/litellm_provider.py function infer_litellm_provider (line 12) | def infer_litellm_provider(*, model: str, api_base: str | None) -> str |... FILE: openhands-sdk/openhands/sdk/llm/utils/metrics.py class Cost (line 8) | class Cost(BaseModel): method validate_cost (line 15) | def validate_cost(cls, v: float) -> float: class ResponseLatency (line 21) | class ResponseLatency(BaseModel): method validate_latency (line 30) | def validate_latency(cls, v: float) -> float: class TokenUsage (line 34) | class TokenUsage(BaseModel): method __add__ (line 61) | def __add__(self, other: "TokenUsage") -> "TokenUsage": class MetricsSnapshot (line 76) | class MetricsSnapshot(BaseModel): class Metrics (line 95) | class Metrics(MetricsSnapshot): method validate_accumulated_cost (line 116) | def validate_accumulated_cost(cls, v: float) -> float: method initialize_accumulated_token_usage (line 122) | def initialize_accumulated_token_usage(self) -> "Metrics": method get_snapshot (line 136) | def get_snapshot(self) -> MetricsSnapshot: method add_cost (line 147) | def add_cost(self, value: float) -> None: method add_response_latency (line 153) | def add_response_latency(self, value: float, response_id: str) -> None: method add_token_usage (line 160) | def add_token_usage( method merge (line 204) | def merge(self, other: "Metrics") -> None: method get (line 224) | def get(self) -> dict: method log (line 239) | def log(self) -> str: method deep_copy (line 247) | def deep_copy(self) -> "Metrics": method diff (line 251) | def diff(self, baseline: "Metrics") -> "Metrics": method __repr__ (line 311) | def __repr__(self) -> str: FILE: openhands-sdk/openhands/sdk/llm/utils/model_features.py function model_matches (line 7) | def model_matches(model: str, patterns: list[str]) -> bool: function apply_ordered_model_rules (line 21) | def apply_ordered_model_rules(model: str, rules: list[str]) -> bool: class ModelFeatures (line 44) | class ModelFeatures: function _normalized_supported_openai_params (line 62) | def _normalized_supported_openai_params(model: str | None) -> frozenset[... function _supports_reasoning_effort (line 84) | def _supports_reasoning_effort(model: str | None) -> bool: function get_features (line 194) | def get_features(model: str) -> ModelFeatures: FILE: openhands-sdk/openhands/sdk/llm/utils/model_info.py function _get_model_info_from_litellm_proxy (line 15) | def _get_model_info_from_litellm_proxy( function get_litellm_model_info (line 51) | def get_litellm_model_info( FILE: openhands-sdk/openhands/sdk/llm/utils/model_prompt_spec.py class ModelPromptSpec (line 12) | class ModelPromptSpec(BaseModel): function _normalize (line 54) | def _normalize(name: str | None) -> str: function _match_family (line 58) | def _match_family(model_name: str) -> str | None: function _match_variant (line 69) | def _match_variant( function get_model_prompt_spec (line 90) | def get_model_prompt_spec( FILE: openhands-sdk/openhands/sdk/llm/utils/responses_serialization.py function message_to_responses_dict (line 16) | def message_to_responses_dict( function _user_to_responses_items (line 43) | def _user_to_responses_items( function _build_user_content_items (line 59) | def _build_user_content_items( function _assistant_to_responses_items (line 75) | def _assistant_to_responses_items(message: Message) -> list[dict[str, An... function _build_reasoning_item (line 93) | def _build_reasoning_item( function _build_assistant_content_items (line 120) | def _build_assistant_content_items( function _tool_to_responses_items (line 131) | def _tool_to_responses_items( FILE: openhands-sdk/openhands/sdk/llm/utils/retry_mixin.py class RetryMixin (line 22) | class RetryMixin: method retry_decorator (line 25) | def retry_decorator( method log_retry_attempt (line 88) | def log_retry_attempt(self, retry_state: RetryCallState) -> None: FILE: openhands-sdk/openhands/sdk/llm/utils/telemetry.py class Telemetry (line 22) | class Telemetry(BaseModel): method set_log_completions_callback (line 57) | def set_log_completions_callback( method set_stats_update_callback (line 68) | def set_stats_update_callback(self, callback: Callable[[], None] | Non... method on_request (line 77) | def on_request(self, telemetry_ctx: dict | None) -> None: method on_response (line 81) | def on_response( method on_error (line 124) | def on_error(self, _err: BaseException) -> None: method _has_meaningful_usage (line 168) | def _has_meaningful_usage(self, usage: Usage | ResponseAPIUsage | None... method _record_usage (line 189) | def _record_usage( method _compute_cost (line 248) | def _compute_cost(self, resp: ModelResponse | ResponsesAPIResponse) ->... method log_llm_call (line 288) | def log_llm_call( function _safe_json (line 386) | def _safe_json(obj: Any) -> Any: FILE: openhands-sdk/openhands/sdk/llm/utils/unverified_models.py function _get_boto3 (line 10) | def _get_boto3(): function _list_bedrock_foundation_models (line 21) | def _list_bedrock_foundation_models( function get_supported_llm_models (line 54) | def get_supported_llm_models( function _split_is_actually_version (line 82) | def _split_is_actually_version(split: list[str]) -> bool: function _get_litellm_provider_names (line 91) | def _get_litellm_provider_names() -> set[str]: function _extract_model_and_provider (line 111) | def _extract_model_and_provider(model: str) -> tuple[str, str, str]: function get_unverified_models (line 153) | def get_unverified_models( FILE: openhands-sdk/openhands/sdk/logger/logger.py function disable_logger (line 77) | def disable_logger(name: str, level: int = logging.CRITICAL) -> None: function setup_logging (line 92) | def setup_logging( function get_logger (line 169) | def get_logger(name: str) -> logging.Logger: FILE: openhands-sdk/openhands/sdk/logger/rolling.py class _RollingViewHandler (line 16) | class _RollingViewHandler(logging.Handler): method __init__ (line 17) | def __init__(self, max_lines: int, use_live: bool): method emit (line 24) | def emit(self, record: logging.LogRecord): method snapshot (line 45) | def snapshot(self) -> str: function rolling_log_view (line 50) | def rolling_log_view( FILE: openhands-sdk/openhands/sdk/marketplace/types.py class MarketplaceOwner (line 25) | class MarketplaceOwner(BaseModel): class MarketplacePluginSource (line 37) | class MarketplacePluginSource(BaseModel): method validate_source_fields (line 58) | def validate_source_fields(self) -> MarketplacePluginSource: class MarketplaceEntry (line 67) | class MarketplaceEntry(BaseModel): method _parse_author (line 91) | def _parse_author(cls, v: Any) -> Any: class MarketplacePluginEntry (line 97) | class MarketplacePluginEntry(MarketplaceEntry): method _parse_source (line 143) | def _parse_source(cls, v: Any) -> Any: method to_plugin_manifest (line 148) | def to_plugin_manifest(self) -> PluginManifest: class MarketplaceMetadata (line 159) | class MarketplaceMetadata(BaseModel): class Marketplace (line 168) | class Marketplace(BaseModel): method load (line 218) | def load(cls, marketplace_path: str | Path) -> Marketplace: method get_plugin (line 263) | def get_plugin(self, name: str) -> MarketplacePluginEntry | None: method resolve_plugin_source (line 277) | def resolve_plugin_source( FILE: openhands-sdk/openhands/sdk/mcp/client.py class MCPClient (line 18) | class MCPClient(AsyncMCPClient): method __init__ (line 39) | def __init__(self, *args, **kwargs): method tools (line 46) | def tools(self) -> "list[MCPToolDefinition]": method connect (line 50) | async def connect(self) -> None: method call_async_from_sync (line 57) | def call_async_from_sync( method call_sync_from_async (line 75) | async def call_sync_from_async( method sync_close (line 84) | def sync_close(self) -> None: method __del__ (line 105) | def __del__(self): method __enter__ (line 113) | def __enter__(self) -> "MCPClient": method __exit__ (line 116) | def __exit__(self, *args: object) -> None: method __iter__ (line 120) | def __iter__(self) -> "Iterator[MCPToolDefinition]": method __len__ (line 123) | def __len__(self) -> int: method __getitem__ (line 126) | def __getitem__(self, index: int) -> "MCPToolDefinition": FILE: openhands-sdk/openhands/sdk/mcp/definition.py class MCPToolAction (line 26) | class MCPToolAction(Action): method to_mcp_arguments (line 41) | def to_mcp_arguments(self) -> dict: class MCPToolObservation (line 50) | class MCPToolObservation(Observation): method from_call_tool_result (line 56) | def from_call_tool_result( method visualize (line 86) | def visualize(self) -> Text: FILE: openhands-sdk/openhands/sdk/mcp/exceptions.py class MCPError (line 4) | class MCPError(Exception): class MCPTimeoutError (line 10) | class MCPTimeoutError(MCPError): method __init__ (line 16) | def __init__(self, message: str, timeout: float, config: dict | None =... FILE: openhands-sdk/openhands/sdk/mcp/tool.py function to_camel_case (line 41) | def to_camel_case(s: str) -> str: class MCPToolExecutor (line 46) | class MCPToolExecutor(ToolExecutor): method __init__ (line 53) | def __init__( method call_tool (line 64) | async def call_tool(self, action: MCPToolAction) -> MCPToolObservation: method __call__ (line 90) | def __call__( method close (line 113) | def close(self) -> None: function _create_mcp_action_type (line 120) | def _create_mcp_action_type(action_type: mcp.types.Tool) -> type[Schema]: class MCPToolDefinition (line 146) | class MCPToolDefinition(ToolDefinition[MCPToolAction, MCPToolObservation]): method name (line 152) | def name(self) -> str: # type: ignore[override] method __call__ (line 156) | def __call__( method action_from_arguments (line 192) | def action_from_arguments(self, arguments: dict[str, Any]) -> MCPToolA... method create (line 225) | def create( method to_mcp_tool (line 258) | def to_mcp_tool( method to_openai_tool (line 273) | def to_openai_tool( FILE: openhands-sdk/openhands/sdk/mcp/utils.py function log_handler (line 19) | async def log_handler(message: LogMessage): function _connect_and_list_tools (line 34) | async def _connect_and_list_tools(client: MCPClient) -> None: function create_mcp_tools (line 43) | def create_mcp_tools( FILE: openhands-sdk/openhands/sdk/observability/laminar.py function _get_int_env (line 33) | def _get_int_env(key: str) -> int | None: function _get_bool_env (line 45) | def _get_bool_env(key: str) -> bool: function maybe_init_laminar (line 57) | def maybe_init_laminar(): function observe (line 113) | def observe[**P, R]( function should_enable_observability (line 197) | def should_enable_observability() -> bool: function _is_otel_backend_laminar (line 216) | def _is_otel_backend_laminar(): class RootSpan (line 229) | class RootSpan: method __init__ (line 251) | def __init__(self, name: str, session_id: str | None = None) -> None: method end (line 265) | def end(self) -> None: function start_root_span (line 276) | def start_root_span(name: str, session_id: str | None = None) -> RootSpa... function end_root_span (line 290) | def end_root_span(root: RootSpan | None) -> None: function _maybe_use_root_span (line 298) | def _maybe_use_root_span(args: tuple[Any, ...]) -> Iterator[None]: function _root_span_from_args (line 333) | def _root_span_from_args(args: tuple[Any, ...]) -> RootSpan | None: class SpanManager (line 361) | class SpanManager: method __init__ (line 373) | def __init__(self) -> None: method start_active_span (line 376) | def start_active_span(self, name: str, session_id: str | None = None) ... method end_active_span (line 393) | def end_active_span(self) -> None: function _get_span_manager (line 411) | def _get_span_manager() -> SpanManager: function start_active_span (line 424) | def start_active_span(name: str, session_id: str | None = None) -> None: function end_active_span (line 452) | def end_active_span() -> None: function init_laminar_for_external (line 477) | def init_laminar_for_external(): FILE: openhands-sdk/openhands/sdk/observability/utils.py function get_env (line 8) | def get_env(key: str) -> str | None: function extract_action_name (line 13) | def extract_action_name(action_event: ActionEvent) -> str: FILE: openhands-sdk/openhands/sdk/plugin/fetch.py class PluginFetchError (line 22) | class PluginFetchError(Exception): function fetch_plugin (line 26) | def fetch_plugin( function fetch_plugin_with_resolution (line 69) | def fetch_plugin_with_resolution( FILE: openhands-sdk/openhands/sdk/plugin/installed.py function get_installed_plugins_dir (line 25) | def get_installed_plugins_dir() -> Path: class PluginInstallationInterface (line 35) | class PluginInstallationInterface(InstallationInterface[Plugin]): method load_from_dir (line 37) | def load_from_dir(extension_dir: Path) -> Plugin: function _resolve_installed_dir (line 41) | def _resolve_installed_dir(installed_dir: Path | None) -> Path: function _manager (line 45) | def _manager(installed_dir: Path) -> InstallationManager[Plugin]: function install_plugin (line 57) | def install_plugin( function uninstall_plugin (line 83) | def uninstall_plugin( function enable_plugin (line 95) | def enable_plugin( function disable_plugin (line 103) | def disable_plugin( function list_installed_plugins (line 111) | def list_installed_plugins( function load_installed_plugins (line 121) | def load_installed_plugins( function get_installed_plugin (line 128) | def get_installed_plugin( function update_plugin (line 136) | def update_plugin( FILE: openhands-sdk/openhands/sdk/plugin/loader.py function load_plugins (line 28) | def load_plugins( FILE: openhands-sdk/openhands/sdk/plugin/plugin.py class Plugin (line 39) | class Plugin(BaseModel): method name (line 77) | def name(self) -> str: method version (line 82) | def version(self) -> str: method description (line 87) | def description(self) -> str: method entry_slash_command (line 92) | def entry_slash_command(self) -> str | None: method get_all_skills (line 107) | def get_all_skills(self) -> list[Skill]: method add_skills_to (line 126) | def add_skills_to( method add_mcp_config_to (line 176) | def add_mcp_config_to( method fetch (line 237) | def fetch( method load (line 292) | def load(cls, plugin_path: str | Path) -> Plugin: method load_all (line 338) | def load_all(cls, plugins_dir: str | Path) -> list[Plugin]: function _load_manifest (line 365) | def _load_manifest(plugin_dir: Path) -> PluginManifest: function _load_skills (line 404) | def _load_skills(plugin_dir: Path) -> list[Skill]: function _load_hooks (line 439) | def _load_hooks(plugin_dir: Path) -> HookConfig | None: function _load_mcp_config (line 460) | def _load_mcp_config(plugin_dir: Path) -> dict[str, Any] | None: function _load_agents (line 491) | def _load_agents(plugin_dir: Path) -> list[AgentDefinition]: function _load_commands (line 510) | def _load_commands(plugin_dir: Path) -> list[CommandDefinition]: FILE: openhands-sdk/openhands/sdk/plugin/source.py class GitHubURLComponents (line 27) | class GitHubURLComponents(NamedTuple): function parse_github_url (line 36) | def parse_github_url(url: str) -> GitHubURLComponents | None: function is_local_path (line 48) | def is_local_path(source: str) -> bool: function validate_source_path (line 53) | def validate_source_path(source: str) -> str: function resolve_source_path (line 62) | def resolve_source_path( FILE: openhands-sdk/openhands/sdk/plugin/types.py class PluginSource (line 14) | class PluginSource(BaseModel): method validate_repo_path (line 52) | def validate_repo_path(cls, v: str | None) -> str | None: method source_url (line 67) | def source_url(self) -> str | None: class ResolvedPluginSource (line 109) | class ResolvedPluginSource(BaseModel): method from_plugin_source (line 142) | def from_plugin_source( method to_plugin_source (line 153) | def to_plugin_source(self) -> PluginSource: class PluginAuthor (line 190) | class PluginAuthor(BaseModel): method from_string (line 200) | def from_string(cls, author_str: str) -> PluginAuthor: class PluginManifest (line 209) | class PluginManifest(BaseModel): class CommandDefinition (line 228) | class CommandDefinition(BaseModel): method load (line 253) | def load(cls, command_path: Path) -> CommandDefinition: method to_skill (line 317) | def to_skill(self, plugin_name: str) -> Skill: FILE: openhands-sdk/openhands/sdk/secret/secrets.py function _resolve_lookup_secret_url (line 26) | def _resolve_lookup_secret_url(url: str) -> str: class SecretSource (line 35) | class SecretSource(DiscriminatedUnionMixin, ABC): method get_value (line 44) | def get_value(self) -> str | None: class StaticSecret (line 48) | class StaticSecret(SecretSource): method get_value (line 53) | def get_value(self) -> str | None: method _validate_secrets (line 60) | def _validate_secrets(cls, v: SecretStr | None, info): method _serialize_secrets (line 64) | def _serialize_secrets(self, v: SecretStr | None, info): class LookupSecret (line 68) | class LookupSecret(SecretSource): method _normalize_url (line 76) | def _normalize_url(cls, url: str) -> str: method get_value (line 79) | def get_value(self) -> str: method _validate_secrets (line 86) | def _validate_secrets(cls, headers: dict[str, str], info): method _serialize_secrets (line 119) | def _serialize_secrets(self, headers: dict[str, str], info): FILE: openhands-sdk/openhands/sdk/security/analyzer.py class SecurityAnalyzerBase (line 15) | class SecurityAnalyzerBase(DiscriminatedUnionMixin, ABC): method security_risk (line 26) | def security_risk(self, action: ActionEvent) -> SecurityRisk: method analyze_event (line 41) | def analyze_event(self, event: Event) -> SecurityRisk | None: method should_require_confirmation (line 57) | def should_require_confirmation( method analyze_pending_actions (line 85) | def analyze_pending_actions( FILE: openhands-sdk/openhands/sdk/security/confirmation_policy.py class ConfirmationPolicyBase (line 9) | class ConfirmationPolicyBase(DiscriminatedUnionMixin, ABC): method should_confirm (line 11) | def should_confirm(self, risk: SecurityRisk = SecurityRisk.UNKNOWN) ->... class AlwaysConfirm (line 27) | class AlwaysConfirm(ConfirmationPolicyBase): method should_confirm (line 28) | def should_confirm( class NeverConfirm (line 35) | class NeverConfirm(ConfirmationPolicyBase): method should_confirm (line 36) | def should_confirm( class ConfirmRisky (line 43) | class ConfirmRisky(ConfirmationPolicyBase): method validate_threshold (line 48) | def validate_threshold(cls, v: SecurityRisk) -> SecurityRisk: method should_confirm (line 53) | def should_confirm(self, risk: SecurityRisk = SecurityRisk.UNKNOWN) ->... FILE: openhands-sdk/openhands/sdk/security/defense_in_depth/pattern.py class PatternSecurityAnalyzer (line 140) | class PatternSecurityAnalyzer(SecurityAnalyzerBase): method model_post_init (line 193) | def model_post_init(self, __context: Any) -> None: method security_risk (line 212) | def security_risk(self, action: ActionEvent) -> SecurityRisk: FILE: openhands-sdk/openhands/sdk/security/defense_in_depth/policy_rails.py class RailDecision (line 47) | class RailDecision: function _evaluate_rail_segments (line 68) | def _evaluate_rail_segments(segments: list[str]) -> RailDecision: function _evaluate_rail (line 133) | def _evaluate_rail(content: str) -> RailDecision: class PolicyRailSecurityAnalyzer (line 148) | class PolicyRailSecurityAnalyzer(SecurityAnalyzerBase): method security_risk (line 174) | def security_risk(self, action: ActionEvent) -> SecurityRisk: FILE: openhands-sdk/openhands/sdk/security/defense_in_depth/utils.py class _BoundedSegments (line 49) | class _BoundedSegments: method __init__ (line 61) | def __init__(self, cap: int) -> None: method add (line 66) | def add(self, text: str) -> None: function _walk_json_strings (line 78) | def _walk_json_strings(obj: Any) -> list[str]: function _extract_exec_segments (line 104) | def _extract_exec_segments(action: ActionEvent) -> list[str]: function _extract_text_segments (line 138) | def _extract_text_segments(action: ActionEvent) -> list[str]: function _extract_segments (line 167) | def _extract_segments(action: ActionEvent) -> list[str]: function _extract_content (line 172) | def _extract_content(action: ActionEvent) -> str: function _extract_exec_content (line 186) | def _extract_exec_content(action: ActionEvent) -> str: function _normalize (line 346) | def _normalize(text: str) -> str: FILE: openhands-sdk/openhands/sdk/security/ensemble.py class EnsembleSecurityAnalyzer (line 22) | class EnsembleSecurityAnalyzer(SecurityAnalyzerBase): method security_risk (line 78) | def security_risk(self, action: ActionEvent) -> SecurityRisk: FILE: openhands-sdk/openhands/sdk/security/grayswan/analyzer.py class GraySwanAnalyzer (line 28) | class GraySwanAnalyzer(SecurityAnalyzerBase): method validate_thresholds (line 83) | def validate_thresholds(self) -> GraySwanAnalyzer: method model_post_init (line 92) | def model_post_init(self, __context: Any) -> None: method set_events (line 119) | def set_events(self, events: Sequence[LLMConvertibleEvent]) -> None: method _create_client (line 127) | def _create_client(self) -> httpx.Client: method _get_client (line 138) | def _get_client(self) -> httpx.Client: method _map_violation_to_risk (line 147) | def _map_violation_to_risk(self, violation_score: float) -> SecurityRisk: method _call_grayswan_api (line 163) | def _call_grayswan_api(self, messages: list[dict[str, Any]]) -> Securi... method security_risk (line 229) | def security_risk(self, action: ActionEvent) -> SecurityRisk: method close (line 276) | def close(self) -> None: FILE: openhands-sdk/openhands/sdk/security/grayswan/utils.py function convert_events_to_openai_messages (line 28) | def convert_events_to_openai_messages( FILE: openhands-sdk/openhands/sdk/security/llm_analyzer.py class LLMSecurityAnalyzer (line 10) | class LLMSecurityAnalyzer(SecurityAnalyzerBase): method security_risk (line 20) | def security_risk(self, action: ActionEvent) -> SecurityRisk: FILE: openhands-sdk/openhands/sdk/security/risk.py class SecurityRisk (line 13) | class SecurityRisk(str, Enum): method description (line 26) | def description(self) -> str: method __str__ (line 42) | def __str__(self) -> str: method get_color (line 45) | def get_color(self) -> str: method visualize (line 56) | def visualize(self) -> Text: method is_riskier (line 69) | def is_riskier(self, other: SecurityRisk, reflexive: bool = True) -> b... method _check_comparable (line 102) | def _check_comparable(self, other: object) -> int | None: method __lt__ (line 114) | def __lt__(self, other: object) -> bool: method __gt__ (line 125) | def __gt__(self, other: object) -> bool: method __le__ (line 137) | def __le__(self, other: object) -> bool: method __ge__ (line 143) | def __ge__(self, other: object) -> bool: FILE: openhands-sdk/openhands/sdk/settings/__init__.py function __getattr__ (line 119) | def __getattr__(name: str) -> Any: FILE: openhands-sdk/openhands/sdk/settings/acp_providers.py class ACPProviderInfo (line 31) | class ACPProviderInfo: function get_acp_provider (line 135) | def get_acp_provider(key: str) -> ACPProviderInfo | None: function detect_acp_provider_by_agent_name (line 140) | def detect_acp_provider_by_agent_name(agent_name: str) -> ACPProviderInf... function build_session_model_meta (line 157) | def build_session_model_meta(agent_name: str, acp_model: str | None) -> ... FILE: openhands-sdk/openhands/sdk/settings/api_models.py class SettingsResponse (line 41) | class SettingsResponse(BaseModel): method get_agent_settings (line 62) | def get_agent_settings(self) -> AgentSettingsConfig: method get_conversation_settings (line 73) | def get_conversation_settings(self) -> ConversationSettings: class SettingsUpdateRequest (line 84) | class SettingsUpdateRequest(BaseModel): class SecretItemResponse (line 98) | class SecretItemResponse(BaseModel): class SecretsListResponse (line 108) | class SecretsListResponse(BaseModel): class SecretCreateRequest (line 118) | class SecretCreateRequest(BaseModel): FILE: openhands-sdk/openhands/sdk/settings/metadata.py class SettingProminence (line 13) | class SettingProminence(str, Enum): class SettingsSectionMetadata (line 19) | class SettingsSectionMetadata(BaseModel): class SettingsFieldMetadata (line 25) | class SettingsFieldMetadata(BaseModel): function field_meta (line 35) | def field_meta( FILE: openhands-sdk/openhands/sdk/settings/model.py function _walk_mcp_secret_values (line 71) | def _walk_mcp_secret_values( function _decrypt_secret_value_or_keep (line 95) | def _decrypt_secret_value_or_keep( function _decrypt_mcp_value_or_keep (line 117) | def _decrypt_mcp_value_or_keep(cipher: Cipher, value: str) -> str: class SettingsChoice (line 134) | class SettingsChoice(BaseModel): class SettingsFieldSchema (line 139) | class SettingsFieldSchema(BaseModel): class SettingsSectionSchema (line 162) | class SettingsSectionSchema(BaseModel): class SettingsSchema (line 177) | class SettingsSchema(BaseModel): class CondenserSettings (line 186) | class CondenserSettings(BaseModel): class VerificationSettings (line 211) | class VerificationSettings(BaseModel): function _default_llm_settings (line 306) | def _default_llm_settings() -> LLM: class AgentSettingsBase (line 318) | class AgentSettingsBase(BaseModel): method export_schema (line 340) | def export_schema(cls) -> SettingsSchema: method create_agent (line 344) | def create_agent(self) -> AgentBase: function _copy_persisted_payload (line 360) | def _copy_persisted_payload(data: Any) -> dict[str, Any]: function _apply_persisted_migrations (line 371) | def _apply_persisted_migrations( function _migrate_agent_settings_v0_to_v1 (line 421) | def _migrate_agent_settings_v0_to_v1(payload: dict[str, Any]) -> dict[st... function _migrate_agent_settings_v1_to_v2 (line 428) | def _migrate_agent_settings_v1_to_v2(payload: dict[str, Any]) -> dict[st... function _migrate_agent_settings_v2_to_v3 (line 448) | def _migrate_agent_settings_v2_to_v3(payload: dict[str, Any]) -> dict[st... function _migrate_conversation_settings_v0_to_v1 (line 461) | def _migrate_conversation_settings_v0_to_v1( class ConversationSettings (line 479) | class ConversationSettings(BaseModel): method export_schema (line 579) | def export_schema(cls) -> SettingsSchema: method from_persisted (line 584) | def from_persisted(cls, data: Any) -> ConversationSettings: method _build_confirmation_policy (line 594) | def _build_confirmation_policy(self): method _build_security_analyzer (line 607) | def _build_security_analyzer(self): method _start_request_kwargs (line 617) | def _start_request_kwargs(self, **kwargs: Any) -> dict[str, Any]: method create_request (line 660) | def create_request( class OpenHandsAgentSettings (line 685) | class OpenHandsAgentSettings(AgentSettingsBase): method _normalize_empty_mcp_config (line 798) | def _normalize_empty_mcp_config(cls, value: Any) -> Any: method _decrypt_mcp_secret_values (line 805) | def _decrypt_mcp_secret_values(cls, value: Any, info: ValidationInfo) ... method _serialize_mcp_config (line 824) | def _serialize_mcp_config( method create_agent (line 850) | def create_agent(self) -> Agent: method build_condenser (line 885) | def build_condenser(self, llm: LLM) -> LLMSummarizingCondenser | None: method build_critic (line 894) | def build_critic(self) -> CriticBase | None: class ACPAgentSettings (line 936) | class ACPAgentSettings(AgentSettingsBase): method _decrypt_acp_env_values (line 1032) | def _decrypt_acp_env_values(cls, value: Any, info: ValidationInfo) -> ... method _serialize_acp_env (line 1053) | def _serialize_acp_env(self, value: dict[str, str], info): method provider_info (line 1135) | def provider_info(self) -> ACPProviderInfo | None: method api_key_env_var (line 1140) | def api_key_env_var(self) -> str | None: method base_url_env_var (line 1151) | def base_url_env_var(self) -> str | None: method resolve_provider_env (line 1160) | def resolve_provider_env(self) -> dict[str, str]: method resolve_acp_env (line 1189) | def resolve_acp_env(self) -> dict[str, str]: method resolve_acp_command (line 1203) | def resolve_acp_command(self) -> list[str]: method create_agent (line 1225) | def create_agent(self) -> ACPAgent: class LLMAgentSettings (line 1246) | class LLMAgentSettings(OpenHandsAgentSettings): function _agent_settings_discriminator (line 1274) | def _agent_settings_discriminator(value: Any) -> str: function validate_agent_settings (line 1314) | def validate_agent_settings( class AgentSettings (line 1336) | class AgentSettings(LLMAgentSettings): method from_persisted (line 1368) | def from_persisted( method __init__ (line 1377) | def __init__(self, *args: Any, **kwargs: Any) -> None: function default_agent_settings (line 1394) | def default_agent_settings() -> OpenHandsAgentSettings: function create_agent_from_settings (line 1403) | def create_agent_from_settings( function export_agent_settings_schema (line 1414) | def export_agent_settings_schema() -> SettingsSchema: function settings_section_metadata (line 1458) | def settings_section_metadata(field: FieldInfo) -> SettingsSectionMetada... function settings_metadata (line 1469) | def settings_metadata(field: FieldInfo) -> SettingsFieldMetadata | None: function export_settings_schema (line 1488) | def export_settings_schema(model: type[BaseModel]) -> SettingsSchema: function _nested_model_type (line 1597) | def _nested_model_type(annotation: Any) -> type[BaseModel] | None: function _annotation_options (line 1608) | def _annotation_options(annotation: Any) -> tuple[Any, ...]: function _contains_secret (line 1623) | def _contains_secret(annotation: Any) -> bool: function _infer_value_type (line 1627) | def _infer_value_type(annotation: Any) -> SettingsValueType: function _is_stringish (line 1648) | def _is_stringish(annotation: Any) -> bool: function _is_array_annotation (line 1652) | def _is_array_annotation(annotation: Any) -> bool: function _is_object_annotation (line 1656) | def _is_object_annotation(annotation: Any) -> bool: function _choice_values (line 1663) | def _choice_values(annotation: Any) -> list[SettingsChoiceValue]: function _value_type_for_values (line 1685) | def _value_type_for_values(values: list[SettingsChoiceValue]) -> Setting... function _extract_choices (line 1698) | def _extract_choices(annotation: Any) -> list[SettingsChoice]: function _normalize_default (line 1723) | def _normalize_default(value: Any) -> Any: function _humanize_name (line 1741) | def _humanize_name(name: str) -> str: FILE: openhands-sdk/openhands/sdk/skills/exceptions.py class SkillError (line 1) | class SkillError(Exception): class SkillValidationError (line 7) | class SkillValidationError(SkillError): method __init__ (line 10) | def __init__(self, message: str = "Skill validation failed") -> None: FILE: openhands-sdk/openhands/sdk/skills/execute.py function _execute_inline_command (line 52) | def _execute_inline_command( function render_content_with_commands (line 98) | def render_content_with_commands( FILE: openhands-sdk/openhands/sdk/skills/fetch.py class SkillFetchError (line 22) | class SkillFetchError(Exception): function fetch_skill (line 26) | def fetch_skill( function fetch_skill_with_resolution (line 58) | def fetch_skill_with_resolution( FILE: openhands-sdk/openhands/sdk/skills/installed.py function get_installed_skills_dir (line 31) | def get_installed_skills_dir() -> Path: function _load_skill_from_dir (line 41) | def _load_skill_from_dir(skill_root: Path) -> Skill: class SkillInstallationInterface (line 49) | class SkillInstallationInterface(InstallationInterface[Skill]): method load_from_dir (line 51) | def load_from_dir(extension_dir: Path) -> Skill: function _resolve_installed_dir (line 55) | def _resolve_installed_dir(installed_dir: Path | None) -> Path: function _manager (line 59) | def _manager(installed_dir: Path) -> InstallationManager[Skill]: function install_skill (line 71) | def install_skill( function uninstall_skill (line 96) | def uninstall_skill( function enable_skill (line 108) | def enable_skill( function disable_skill (line 116) | def disable_skill( function list_installed_skills (line 124) | def list_installed_skills( function load_installed_skills (line 134) | def load_installed_skills( function get_installed_skill (line 141) | def get_installed_skill( function update_skill (line 149) | def update_skill( function install_skills_from_marketplace (line 157) | def install_skills_from_marketplace( FILE: openhands-sdk/openhands/sdk/skills/skill.py class SkillInfo (line 43) | class SkillInfo(BaseModel): class SkillResources (line 60) | class SkillResources(BaseModel): method has_resources (line 83) | def has_resources(self) -> bool: method get_scripts_dir (line 87) | def get_scripts_dir(self) -> Path | None: method get_references_dir (line 92) | def get_references_dir(self) -> Path | None: method get_assets_dir (line 97) | def get_assets_dir(self) -> Path | None: class Skill (line 110) | class Skill(BaseModel): method _parse_allowed_tools (line 237) | def _parse_allowed_tools(cls, v: str | list | None) -> list[str] | None: method _convert_metadata_values (line 249) | def _convert_metadata_values(cls, v: dict | None) -> dict[str, str] | ... method _validate_mcp_tools (line 259) | def _validate_mcp_tools(cls, v: dict | None, _info): method load (line 279) | def load( method _load_agentskills_skill (line 310) | def _load_agentskills_skill( method _load_legacy_openhands_skill (line 363) | def _load_legacy_openhands_skill( method _create_skill_from_metadata (line 404) | def _create_skill_from_metadata( method _handle_third_party (line 504) | def _handle_third_party(cls, path: Path, file_content: str) -> Union["... method _truncate_long_description (line 523) | def _truncate_long_description(self): method _append_missing_variables_prompt (line 551) | def _append_missing_variables_prompt(self): method match_trigger (line 572) | def match_trigger(self, message: str) -> str | None: method extract_variables (line 590) | def extract_variables(self, content: str) -> list[str]: method requires_user_input (line 599) | def requires_user_input(self) -> bool: method get_skill_type (line 609) | def get_skill_type(self) -> Literal["repo", "knowledge", "agentskills"]: method get_triggers (line 623) | def get_triggers(self) -> list[str]: method to_skill_info (line 635) | def to_skill_info(self) -> SkillInfo: method render_content (line 652) | def render_content( function load_skills_from_dir (line 672) | def load_skills_from_dir( function load_user_skills (line 745) | def load_user_skills() -> list[Skill]: function _find_git_repo_root (line 783) | def _find_git_repo_root(path: Path) -> Path | None: function _merge_loaded_skills (line 797) | def _merge_loaded_skills( function _load_and_merge_from_dirs (line 813) | def _load_and_merge_from_dirs( function load_project_skills (line 851) | def load_project_skills(work_dir: str | Path) -> list[Skill]: function _invalidate_public_skills_cache (line 947) | def _invalidate_public_skills_cache() -> None: function load_marketplace_skill_names (line 957) | def load_marketplace_skill_names( function load_public_skills (line 1007) | def load_public_skills( function load_available_skills (line 1150) | def load_available_skills( function to_prompt (line 1206) | def to_prompt(skills: list[Skill], max_description_length: int = 1024) -... FILE: openhands-sdk/openhands/sdk/skills/trigger.py class BaseTrigger (line 13) | class BaseTrigger(BaseModel, ABC): class KeywordTrigger (line 19) | class KeywordTrigger(BaseTrigger): class TaskTrigger (line 29) | class TaskTrigger(BaseTrigger): FILE: openhands-sdk/openhands/sdk/skills/types.py class InputMetadata (line 6) | class InputMetadata(BaseModel): class SkillKnowledge (line 13) | class SkillKnowledge(BaseModel): class SkillResponse (line 25) | class SkillResponse(BaseModel): class SkillContentResponse (line 41) | class SkillContentResponse(BaseModel): FILE: openhands-sdk/openhands/sdk/skills/utils.py function find_skill_md (line 39) | def find_skill_md(skill_dir: Path) -> Path | None: function find_mcp_config (line 56) | def find_mcp_config(skill_dir: Path) -> Path | None: function _serialize_for_json (line 73) | def _serialize_for_json(obj: object) -> object: function expand_mcp_variables (line 90) | def expand_mcp_variables( function load_mcp_config (line 167) | def load_mcp_config( function validate_skill_name (line 223) | def validate_skill_name(name: str, directory_name: str | None = None) ->... function find_third_party_files (line 254) | def find_third_party_files( function find_skill_md_directories (line 307) | def find_skill_md_directories(skill_dir: Path) -> list[Path]: function find_regular_md_files (line 327) | def find_regular_md_files(skill_dir: Path, exclude_dirs: set[Path]) -> l... function load_and_categorize (line 349) | def load_and_categorize( function get_skills_cache_dir (line 383) | def get_skills_cache_dir() -> Path: function update_skills_repository (line 394) | def update_skills_repository( function discover_skill_resources (line 416) | def discover_skill_resources(skill_dir: Path) -> SkillResources: function _list_resource_files (line 444) | def _list_resource_files( FILE: openhands-sdk/openhands/sdk/subagent/load.py function load_project_agents (line 58) | def load_project_agents(project_dir: str | Path) -> list[AgentDefinition]: function load_user_agents (line 80) | def load_user_agents() -> list[AgentDefinition]: function _load_agents_from_dirs (line 98) | def _load_agents_from_dirs(dirs: list[Path]) -> list[AgentDefinition]: function load_agents_from_dir (line 118) | def load_agents_from_dir(agents_dir: Path) -> list[AgentDefinition]: FILE: openhands-sdk/openhands/sdk/subagent/registry.py class AgentFactory (line 49) | class AgentFactory(NamedTuple): function _resolve_agent_definition (line 61) | def _resolve_agent_definition( function register_agent (line 85) | def register_agent( function register_agent_if_absent (line 124) | def register_agent_if_absent( function _get_profile_store (line 156) | def _get_profile_store(profile_store_dir: str | None) -> LLMProfileStore: function agent_definition_to_factory (line 160) | def agent_definition_to_factory( function register_file_agents (line 266) | def register_file_agents(work_dir: str | Path) -> list[str]: function register_plugin_agents (line 314) | def register_plugin_agents( function get_agent_factory (line 348) | def get_agent_factory(name: str | None) -> AgentFactory: function get_factory_info (line 396) | def get_factory_info() -> str: function get_registered_agent_definitions (line 414) | def get_registered_agent_definitions() -> list[AgentDefinition]: function _reset_registry_for_tests (line 423) | def _reset_registry_for_tests() -> None: FILE: openhands-sdk/openhands/sdk/subagent/schema.py function _extract_color (line 41) | def _extract_color(fm: dict[str, object]) -> str | None: function _extract_tools (line 48) | def _extract_tools(fm: dict[str, object]) -> list[str]: function _extract_skills (line 63) | def _extract_skills(fm: dict[str, object]) -> list[str]: function _extract_mcp_servers (line 76) | def _extract_mcp_servers(fm: dict[str, Any]) -> dict[str, Any] | None: function _extract_profile_store_dir (line 99) | def _extract_profile_store_dir(fm: dict[str, object]) -> str | None: function _extract_examples (line 111) | def _extract_examples(description: str) -> list[str]: function _extract_permission_mode (line 118) | def _extract_permission_mode(fm: dict[str, object]) -> str | None: function _extract_max_iteration_per_run (line 132) | def _extract_max_iteration_per_run(fm: dict[str, object]) -> int | None: function _extract_hooks (line 142) | def _extract_hooks(fm: dict[str, object]) -> HookConfig | None: class AgentDefinition (line 151) | class AgentDefinition(BaseModel): method get_confirmation_policy (line 211) | def get_confirmation_policy(self) -> ConfirmationPolicyBase | None: method load (line 240) | def load(cls, agent_path: Path) -> AgentDefinition: FILE: openhands-sdk/openhands/sdk/testing/test_llm.py class TestLLMExhaustedError (line 55) | class TestLLMExhaustedError(Exception): class TestLLM (line 61) | class TestLLM(LLM): method __init__ (line 112) | def __init__(self, **data: Any) -> None: method from_messages (line 120) | def from_messages( method completion (line 155) | def completion( method responses (line 205) | def responses( method uses_responses_api (line 230) | def uses_responses_api(self) -> bool: method _zero_metrics (line 234) | def _zero_metrics(self) -> MetricsSnapshot: method _create_model_response (line 247) | def _create_model_response(self, message: Message) -> ModelResponse: method _content_to_string (line 283) | def _content_to_string(self, message: Message) -> str: method remaining_responses (line 294) | def remaining_responses(self) -> int: method call_count (line 299) | def call_count(self) -> int: FILE: openhands-sdk/openhands/sdk/tool/builtins/finish.py class FinishAction (line 21) | class FinishAction(Action): method visualize (line 25) | def visualize(self) -> Text: class FinishObservation (line 33) | class FinishObservation(Observation): method visualize (line 41) | def visualize(self) -> Text: class FinishExecutor (line 60) | class FinishExecutor(ToolExecutor): method __call__ (line 61) | def __call__( class FinishTool (line 69) | class FinishTool(ToolDefinition[FinishAction, FinishObservation]): method create (line 73) | def create( FILE: openhands-sdk/openhands/sdk/tool/builtins/invoke_skill.py class InvokeSkillAction (line 27) | class InvokeSkillAction(Action): method visualize (line 31) | def visualize(self) -> Text: class InvokeSkillObservation (line 38) | class InvokeSkillObservation(Observation): method visualize (line 44) | def visualize(self) -> Text: class InvokeSkillExecutor (line 60) | class InvokeSkillExecutor(ToolExecutor): method _get_skills_and_working_dir (line 62) | def _get_skills_and_working_dir( method _record_invocation (line 76) | def _record_invocation(conversation: BaseConversation | None, name: st... method _error (line 85) | def _error(name: str, text: str) -> InvokeSkillObservation: method __call__ (line 90) | def __call__( method _append_skill_location_footer (line 126) | def _append_skill_location_footer( class InvokeSkillTool (line 163) | class InvokeSkillTool(ToolDefinition[InvokeSkillAction, InvokeSkillObser... method declared_resources (line 166) | def declared_resources(self, action: Action) -> DeclaredResources: method create (line 175) | def create( FILE: openhands-sdk/openhands/sdk/tool/builtins/switch_llm.py class SwitchLLMAction (line 22) | class SwitchLLMAction(Action): method visualize (line 33) | def visualize(self) -> Text: class SwitchLLMObservation (line 43) | class SwitchLLMObservation(Observation): method visualize (line 59) | def visualize(self) -> Text: function get_llm_profile_names (line 86) | def get_llm_profile_names() -> list[str]: function has_llm_profiles (line 91) | def has_llm_profiles() -> bool: function _format_profiles (line 95) | def _format_profiles(profile_names: Sequence[str]) -> str: class SwitchLLMExecutor (line 101) | class SwitchLLMExecutor(ToolExecutor): method __call__ (line 102) | def __call__( class SwitchLLMTool (line 155) | class SwitchLLMTool(ToolDefinition[SwitchLLMAction, SwitchLLMObservation]): method create (line 159) | def create( FILE: openhands-sdk/openhands/sdk/tool/builtins/think.py class ThinkAction (line 21) | class ThinkAction(Action): method visualize (line 27) | def visualize(self) -> Text: class ThinkObservation (line 47) | class ThinkObservation(Observation): method visualize (line 55) | def visualize(self) -> Text: class ThinkExecutor (line 72) | class ThinkExecutor(ToolExecutor): method __call__ (line 73) | def __call__( class ThinkTool (line 81) | class ThinkTool(ToolDefinition[ThinkAction, ThinkObservation]): method create (line 85) | def create( FILE: openhands-sdk/openhands/sdk/tool/registry.py function _resolver_from_instance (line 38) | def _resolver_from_instance(name: str, tool: ToolDefinition) -> Resolver: function _resolver_from_callable (line 57) | def _resolver_from_callable( function _is_abstract_method (line 83) | def _is_abstract_method(cls: type, name: str) -> bool: function _resolver_from_subclass (line 94) | def _resolver_from_subclass(_name: str, cls: type[ToolDefinition]) -> Re... function _usability_from_instance (line 122) | def _usability_from_instance(tool: ToolDefinition) -> UsabilityChecker: function _usability_from_subclass (line 126) | def _usability_from_subclass(cls: type[ToolDefinition]) -> UsabilityChec... function _usability_from_callable (line 130) | def _usability_from_callable( function _check_tool_usable (line 137) | def _check_tool_usable(name: str, checker: UsabilityChecker) -> bool: function register_tool (line 147) | def register_tool( function resolve_tool (line 201) | def resolve_tool( function list_registered_tools (line 213) | def list_registered_tools() -> list[str]: function list_usable_tools (line 218) | def list_usable_tools() -> list[str]: function get_tool_module_qualnames (line 230) | def get_tool_module_qualnames() -> dict[str, str]: FILE: openhands-sdk/openhands/sdk/tool/schema.py function py_type (line 25) | def py_type(spec: dict[str, Any]) -> Any: function _shallow_expand_circular_ref (line 55) | def _shallow_expand_circular_ref(ref_def: dict[str, Any]) -> dict[str, A... function _process_schema_node (line 70) | def _process_schema_node( class Schema (line 173) | class Schema(DiscriminatedUnionMixin): method to_mcp_schema (line 179) | def to_mcp_schema(cls) -> dict[str, Any]: method from_mcp_schema (line 201) | def from_mcp_schema( class Action (line 242) | class Action(Schema, ABC): method visualize (line 246) | def visualize(self) -> Text: class Observation (line 268) | class Observation(Schema, ABC): method from_text (line 286) | def from_text( method text (line 305) | def text(self) -> str: method to_llm_content (line 316) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: method visualize (line 333) | def visualize(self) -> Text: FILE: openhands-sdk/openhands/sdk/tool/spec.py class Tool (line 6) | class Tool(BaseModel): method validate_name (line 29) | def validate_name(cls, v: str) -> str: method validate_params (line 37) | def validate_params(cls, v: dict[str, Any] | None) -> dict[str, Any]: FILE: openhands-sdk/openhands/sdk/tool/tool.py function _camel_to_snake (line 50) | def _camel_to_snake(name: str) -> str: class ToolAnnotations (line 64) | class ToolAnnotations(BaseModel): class DeclaredResources (line 100) | class DeclaredResources: class ToolExecutor (line 132) | class ToolExecutor[ActionT, ObservationT](ABC): method __call__ (line 136) | def __call__( method close (line 157) | def close(self) -> None: class ExecutableTool (line 167) | class ExecutableTool(Protocol): method __call__ (line 177) | def __call__( class ToolDefinition (line 184) | class ToolDefinition[ActionT, ObservationT](DiscriminatedUnionMixin, ABC): method __init_subclass__ (line 223) | def __init_subclass__(cls, **kwargs): method is_usable (line 243) | def is_usable(cls) -> bool: method create (line 249) | def create(cls, *args, **kwargs) -> Sequence[Self]: method title (line 268) | def title(self) -> str: method _ser_action_type (line 274) | def _ser_action_type(self, t: type[Action]) -> str: method _ser_observation_type (line 279) | def _ser_observation_type(self, t: type[Observation] | None) -> str | ... method _val_action_type (line 284) | def _val_action_type(cls, v): method _val_observation_type (line 294) | def _val_observation_type(cls, v): method set_executor (line 304) | def set_executor(self, executor: ToolExecutor) -> Self: method as_executable (line 308) | def as_executable(self) -> ExecutableTool: method declared_resources (line 324) | def declared_resources(self, action: Action) -> DeclaredResources: # ... method action_from_arguments (line 334) | def action_from_arguments(self, arguments: dict[str, Any]) -> Action: method __call__ (line 348) | def __call__( method to_mcp_tool (line 379) | def to_mcp_tool( method _get_tool_schema (line 413) | def _get_tool_schema( method to_openai_tool (line 437) | def to_openai_tool( method to_responses_tool (line 469) | def to_responses_tool( method resolve_kind (line 500) | def resolve_kind(cls, kind: str) -> type: function _prioritize_schema_fields (line 535) | def _prioritize_schema_fields( function create_action_type_with_risk (line 553) | def create_action_type_with_risk(action_type: type[Schema]) -> type[Sche... function _create_action_type_with_summary (line 582) | def _create_action_type_with_summary(action_type: type[Schema]) -> type[... FILE: openhands-sdk/openhands/sdk/utils/async_executor.py class AsyncExecutor (line 17) | class AsyncExecutor: method __init__ (line 23) | def __init__(self): method _ensure_portal (line 29) | def _ensure_portal(self): method run_async (line 51) | def run_async( method close (line 92) | def close(self): method __enter__ (line 104) | def __enter__(self): method __exit__ (line 107) | def __exit__(self, exc_type, exc_val, exc_tb): method __del__ (line 111) | def __del__(self): FILE: openhands-sdk/openhands/sdk/utils/async_utils.py class AsyncCallbackWrapper (line 19) | class AsyncCallbackWrapper: method __init__ (line 35) | def __init__( method __call__ (line 45) | def __call__(self, event: Event): method wait_for_pending (line 57) | def wait_for_pending(self, timeout: float | None = None) -> None: FILE: openhands-sdk/openhands/sdk/utils/cipher.py class Cipher (line 22) | class Cipher: method __init__ (line 27) | def __init__(self, secret_key: str): method encrypt (line 31) | def encrypt(self, secret: SecretStr | None) -> str | None: method decrypt (line 39) | def decrypt(self, secret: str | None) -> SecretStr | None: method try_decrypt_str (line 66) | def try_decrypt_str(self, value: str) -> str | None: method _get_fernet (line 73) | def _get_fernet(self): FILE: openhands-sdk/openhands/sdk/utils/command.py function sanitized_env (line 21) | def sanitized_env( function execute_command (line 54) | def execute_command( FILE: openhands-sdk/openhands/sdk/utils/datetime.py function utc_now (line 10) | def utc_now() -> datetime: function _uuid_to_hex (line 15) | def _uuid_to_hex(uuid_obj: UUID) -> str: FILE: openhands-sdk/openhands/sdk/utils/deprecation.py function _current_version (line 22) | def _current_version() -> str: function deprecated (line 29) | def deprecated( function _should_warn (line 57) | def _should_warn( function warn_deprecated (line 83) | def warn_deprecated( function warn_cleanup (line 115) | def warn_cleanup( function handle_deprecated_model_fields (line 162) | def handle_deprecated_model_fields( FILE: openhands-sdk/openhands/sdk/utils/github.py function sanitize_openhands_mentions (line 14) | def sanitize_openhands_mentions(text: str) -> str: FILE: openhands-sdk/openhands/sdk/utils/json.py class OpenHandsJSONEncoder (line 11) | class OpenHandsJSONEncoder(json.JSONEncoder): method default (line 14) | def default(self, o: object) -> Any: function dumps (line 28) | def dumps(obj, **kwargs): function loads (line 43) | def loads(json_str, **kwargs): FILE: openhands-sdk/openhands/sdk/utils/models.py function _get_schemas_in_progress (line 31) | def _get_schemas_in_progress() -> dict[type, JsonSchemaValue]: function _is_abstract (line 38) | def _is_abstract(type_: type) -> bool: function get_handler_class_name (line 46) | def get_handler_class_name(handler: SerializerFunctionWrapHandler) -> str: function kind_of (line 75) | def kind_of(obj) -> str: function _get_all_subclasses (line 84) | def _get_all_subclasses(cls) -> set[type]: function _bump_subclass_generation (line 114) | def _bump_subclass_generation() -> None: function get_known_concrete_subclasses (line 120) | def get_known_concrete_subclasses(cls) -> tuple[type, ...]: function _get_checked_concrete_subclasses (line 145) | def _get_checked_concrete_subclasses(cls: type) -> dict[str, type]: function clear_subclass_cache (line 170) | def clear_subclass_cache() -> None: class OpenHandsModel (line 181) | class OpenHandsModel(BaseModel): class DiscriminatedUnionMixin (line 192) | class DiscriminatedUnionMixin(OpenHandsModel): method __init_subclass__ (line 193) | def __init_subclass__(cls, **kwargs: Any) -> None: method kind (line 199) | def kind(self) -> str: method _validate_subtype (line 204) | def _validate_subtype( method _serialize_by_kind (line 235) | def _serialize_by_kind( method _is_handler_for_current_class (line 259) | def _is_handler_for_current_class( method __get_pydantic_json_schema__ (line 270) | def __get_pydantic_json_schema__( method resolve_kind (line 326) | def resolve_kind(cls, kind: str) -> type[Self]: method get_serializable_type (line 337) | def get_serializable_type(cls) -> type: FILE: openhands-sdk/openhands/sdk/utils/paging.py class PageProtocol (line 7) | class PageProtocol[T](Protocol): function page_iterator (line 19) | async def page_iterator[T]( FILE: openhands-sdk/openhands/sdk/utils/path.py function to_posix_path (line 13) | def to_posix_path(path: str | os.PathLike[str]) -> str: function posix_path_name (line 23) | def posix_path_name(path: str | os.PathLike[str]) -> str: function is_absolute_path_source (line 30) | def is_absolute_path_source(path: str | os.PathLike[str]) -> bool: function is_host_absolute_path (line 43) | def is_host_absolute_path(path: str | os.PathLike[str]) -> bool: function is_local_path_source (line 52) | def is_local_path_source(source: str) -> bool: FILE: openhands-sdk/openhands/sdk/utils/pydantic_diff.py function _normalize (line 6) | def _normalize(x): function _structured_diff (line 18) | def _structured_diff(a, b): function _format_diff (line 68) | def _format_diff(d, indent=0): function pretty_pydantic_diff (line 83) | def pretty_pydantic_diff(a: BaseModel, b: BaseModel) -> str: FILE: openhands-sdk/openhands/sdk/utils/pydantic_secrets.py class MissingCipherError (line 20) | class MissingCipherError(ValueError): function resolve_expose_mode (line 24) | def resolve_expose_mode(context: Mapping[str, Any] | None) -> ResolvedEx... function is_redacted_secret (line 40) | def is_redacted_secret(v: str | SecretStr | None) -> bool: function serialize_secret (line 48) | def serialize_secret(v: SecretStr | None, info): function validate_secret (line 82) | def validate_secret(v: str | SecretStr | None, info) -> SecretStr | None: FILE: openhands-sdk/openhands/sdk/utils/redact.py function is_secret_key (line 59) | def is_secret_key(key: str) -> bool: function _redact_all_values (line 82) | def _redact_all_values(value: Any) -> Any: function sanitize_dict (line 91) | def sanitize_dict(content: Any) -> Any: function http_error_log_content (line 122) | def http_error_log_content(response: httpx.Response) -> str | dict: function redact_url_params (line 141) | def redact_url_params(url: str) -> str: function _walk_redact_urls (line 187) | def _walk_redact_urls(obj: Any) -> Any: function sanitize_config (line 198) | def sanitize_config(config: dict[str, Any]) -> dict[str, Any]: function redact_text_secrets (line 217) | def redact_text_secrets(text: str) -> str: function redact_api_key_literals (line 307) | def redact_api_key_literals(text: str) -> str: FILE: openhands-sdk/openhands/sdk/utils/truncate.py function _save_full_content (line 28) | def _save_full_content(content: str, save_dir: str, tool_prefix: str) ->... function maybe_truncate (line 50) | def maybe_truncate( FILE: openhands-sdk/openhands/sdk/utils/visualize.py function display_dict (line 4) | def display_dict(d) -> Text: function display_json (line 12) | def display_json(data) -> Text: FILE: openhands-sdk/openhands/sdk/workspace/base.py function _convert_path_to_str (line 16) | def _convert_path_to_str(v: str | Path) -> str: class BaseWorkspace (line 23) | class BaseWorkspace(DiscriminatedUnionMixin, ABC): method __enter__ (line 50) | def __enter__(self) -> "BaseWorkspace": method __exit__ (line 58) | def __exit__(self, exc_type: Any, exc_val: Any, exc_tb: Any) -> None: method execute_command (line 72) | def execute_command( method file_upload (line 95) | def file_upload( method file_download (line 115) | def file_download( method git_changes (line 135) | def git_changes(self, path: str | Path) -> list[GitChange]: method git_diff (line 149) | def git_diff(self, path: str | Path) -> GitDiff: method pause (line 162) | def pause(self) -> None: method resume (line 173) | def resume(self) -> None: FILE: openhands-sdk/openhands/sdk/workspace/local.py class LocalWorkspace (line 17) | class LocalWorkspace(BaseWorkspace): method __init__ (line 31) | def __init__(self, *, working_dir: str | Path, **kwargs: Any): method execute_command (line 36) | def execute_command( method file_upload (line 71) | def file_upload( method file_download (line 116) | def file_download( method git_changes (line 161) | def git_changes(self, path: str | Path) -> list[GitChange]: method git_diff (line 176) | def git_diff(self, path: str | Path) -> GitDiff: method pause (line 191) | def pause(self) -> None: method resume (line 199) | def resume(self) -> None: FILE: openhands-sdk/openhands/sdk/workspace/models.py class CommandResult (line 20) | class CommandResult(BaseModel): class FileOperationResult (line 32) | class FileOperationResult(BaseModel): FILE: openhands-sdk/openhands/sdk/workspace/remote/async_remote_workspace.py class AsyncRemoteWorkspace (line 14) | class AsyncRemoteWorkspace(RemoteWorkspaceMixin): method reset_client (line 19) | async def reset_client(self) -> None: method client (line 33) | def client(self) -> httpx.AsyncClient: method _execute (line 48) | async def _execute(self, generator: Generator[dict[str, Any], httpx.Re... method execute_command (line 57) | async def execute_command( method file_upload (line 80) | async def file_upload( method file_download (line 100) | async def file_download( method git_changes (line 120) | async def git_changes(self, path: str | Path) -> list[GitChange]: method git_diff (line 136) | async def git_diff(self, path: str | Path) -> GitDiff: method alive (line 153) | def alive(self) -> bool: FILE: openhands-sdk/openhands/sdk/workspace/remote/base.py function _is_retryable_error (line 41) | def _is_retryable_error(error: BaseException) -> bool: class RemoteWorkspace (line 48) | class RemoteWorkspace(RemoteWorkspaceMixin, BaseWorkspace): method reset_client (line 73) | def reset_client(self) -> None: method client (line 87) | def client(self) -> httpx.Client: method _execute (line 107) | def _execute(self, generator: Generator[dict[str, Any], httpx.Response... method get_server_info (line 116) | def get_server_info(self) -> dict[str, Any]: method execute_command (line 131) | def execute_command( method file_upload (line 154) | def file_upload( method file_download (line 174) | def file_download( method git_changes (line 194) | def git_changes(self, path: str | Path) -> list[GitChange]: method git_diff (line 210) | def git_diff(self, path: str | Path) -> GitDiff: method alive (line 227) | def alive(self) -> bool: method default_conversation_tags (line 242) | def default_conversation_tags(self) -> dict[str, str] | None: method register_conversation (line 253) | def register_conversation(self, conversation_id: str) -> None: method conversation_id (line 267) | def conversation_id(self) -> str | None: method _send_completion_callback (line 275) | def _send_completion_callback( method __exit__ (line 323) | def __exit__( method _fetch_agent_settings (line 340) | def _fetch_agent_settings( method get_llm (line 368) | def get_llm(self, **llm_kwargs: Any) -> "LLM": method get_secrets (line 414) | def get_secrets(self, names: list[str] | None = None) -> dict[str, "Lo... method get_mcp_config (line 474) | def get_mcp_config(self) -> dict[str, Any]: method _get_secret_value (line 518) | def _get_secret_value(self, name: str) -> str | None: method clone_repos (line 567) | def clone_repos( method get_repos_context (line 640) | def get_repos_context(self, repo_mappings: dict[str, RepoMapping]) -> ... method _call_skills_api (line 663) | def _call_skills_api( method _add_skills_to_dict (line 719) | def _add_skills_to_dict( method _load_skills_multi_dir (line 729) | def _load_skills_multi_dir( method _load_skills_single_dir (line 768) | def _load_skills_single_dir( method _convert_skills_dict_to_list (line 791) | def _convert_skills_dict_to_list( method _convert_skill_data_to_skill (line 805) | def _convert_skill_data_to_skill(self, skill_data: dict[str, Any]) -> ... method load_skills_from_agent_server (line 837) | def load_skills_from_agent_server( FILE: openhands-sdk/openhands/sdk/workspace/remote/remote_workspace_mixin.py function _remote_path (line 18) | def _remote_path(path: str | Path) -> str: function _join_remote_path (line 22) | def _join_remote_path(base: str | Path, path: str | Path) -> str: class RemoteWorkspaceMixin (line 34) | class RemoteWorkspaceMixin(BaseModel): method model_post_init (line 55) | def model_post_init(self, context: Any) -> None: method _headers (line 61) | def _headers(self): method _execute_command_generator (line 67) | def _execute_command_generator( method _file_upload_generator (line 202) | def _file_upload_generator( method _file_download_generator (line 262) | def _file_download_generator( method _git_changes_generator (line 318) | def _git_changes_generator( method _git_diff_generator (line 346) | def _git_diff_generator( FILE: openhands-sdk/openhands/sdk/workspace/repo.py class GitProvider (line 33) | class GitProvider(str, Enum): function _detect_provider_from_url (line 56) | def _detect_provider_from_url(url: str) -> GitProvider | None: function _is_short_url_format (line 82) | def _is_short_url_format(url: str) -> bool: class RepoSource (line 87) | class RepoSource(BaseModel): method normalize_string_input (line 133) | def normalize_string_input(cls, data: Any) -> Any: method validate_url (line 141) | def validate_url(cls, v: str) -> str: method validate_provider_required_for_short_urls (line 159) | def validate_provider_required_for_short_urls(self) -> RepoSource: method get_provider (line 175) | def get_provider(self) -> GitProvider: method get_token_name (line 187) | def get_token_name(self) -> str: class RepoMapping (line 193) | class RepoMapping: class CloneResult (line 203) | class CloneResult: function _is_commit_sha (line 211) | def _is_commit_sha(ref: str | None) -> bool: function _extract_repo_name (line 218) | def _extract_repo_name(url: str) -> str: function _sanitize_dir_name (line 248) | def _sanitize_dir_name(name: str) -> str: function _get_unique_dir_name (line 261) | def _get_unique_dir_name(base_name: str, existing_dirs: set[str]) -> str: function _build_clone_url (line 290) | def _build_clone_url(url: str, provider: GitProvider, token: str | None)... function _mask_url (line 319) | def _mask_url(url: str) -> str: function _mask_token (line 326) | def _mask_token(text: str, token: str | None) -> str: function _build_clone_command (line 337) | def _build_clone_command(clone_url: str, dest: Path, ref: str | None) ->... function _checkout_sha (line 350) | def _checkout_sha(dest: Path, sha: str) -> bool: function _clone_single_repo (line 373) | def _clone_single_repo(repo: RepoSource, dest: Path, token: str | None) ... class _TokenCache (line 410) | class _TokenCache: method __init__ (line 413) | def __init__(self, fetcher: TokenFetcher | None): method get (line 417) | def get(self, token_name: str) -> str | None: function clone_repos (line 429) | def clone_repos( function get_repos_context (line 517) | def get_repos_context(repo_mappings: dict[str, RepoMapping]) -> str: FILE: openhands-sdk/openhands/sdk/workspace/workspace.py class Workspace (line 12) | class Workspace: method __new__ (line 21) | def __new__( method __new__ (line 28) | def __new__( method __new__ (line 36) | def __new__( FILE: openhands-tools/openhands/tools/apply_patch/core.py class ActionType (line 20) | class ActionType(str, Enum): class FileChange (line 26) | class FileChange(BaseModel): class Commit (line 33) | class Commit(BaseModel): function assemble_changes (line 37) | def assemble_changes( class Chunk (line 66) | class Chunk(BaseModel): class PatchAction (line 72) | class PatchAction(BaseModel): class Patch (line 79) | class Patch(BaseModel): class Parser (line 83) | class Parser(BaseModel): method is_done (line 90) | def is_done(self, prefixes: tuple[str, ...] | None = None) -> bool: method startswith (line 97) | def startswith(self, prefix: str | tuple[str, ...]) -> bool: method read_str (line 103) | def read_str(self, prefix: str = "", return_everything: bool = False) ... method parse (line 112) | def parse(self): method parse_update_file (line 148) | def parse_update_file(self, text: str) -> PatchAction: method parse_add_file (line 207) | def parse_add_file(self) -> PatchAction: function find_context_core (line 223) | def find_context_core( function find_context (line 245) | def find_context( function peek_next_section (line 257) | def peek_next_section( function text_to_patch (line 332) | def text_to_patch(text: str, orig: dict[str, str]) -> tuple[Patch, int]: function identify_files_needed (line 350) | def identify_files_needed(text: str) -> list[str]: function _get_updated_file (line 361) | def _get_updated_file(text: str, action: PatchAction, path: str) -> str: function patch_to_commit (line 397) | def patch_to_commit(patch: Patch, orig: dict[str, str]) -> Commit: class DiffError (line 419) | class DiffError(ValueError): function load_files (line 423) | def load_files(paths: list[str], open_fn: Callable[[str], str]) -> dict[... function apply_commit (line 443) | def apply_commit( function process_patch (line 463) | def process_patch( FILE: openhands-tools/openhands/tools/apply_patch/definition.py class ApplyPatchAction (line 28) | class ApplyPatchAction(Action): class ApplyPatchObservation (line 44) | class ApplyPatchObservation(Observation): class ApplyPatchExecutor (line 57) | class ApplyPatchExecutor(ToolExecutor[ApplyPatchAction, ApplyPatchObserv... method __init__ (line 64) | def __init__(self, workspace_root: str): method _resolve_path (line 73) | def _resolve_path(self, p: str) -> Path: method __call__ (line 84) | def __call__( class ApplyPatchTool (line 129) | class ApplyPatchTool(ToolDefinition[ApplyPatchAction, ApplyPatchObservat... method create (line 138) | def create(cls, conv_state: ConversationState) -> Sequence[ApplyPatchT... method to_responses_tool (line 159) | def to_responses_tool( FILE: openhands-tools/openhands/tools/browser_use/definition.py function detect_image_mime_type (line 45) | def detect_image_mime_type(base64_data: str) -> str: class BrowserObservation (line 60) | class BrowserObservation(Observation): method _save_screenshot (line 71) | def _save_screenshot(self, base64_data: str, save_dir: str) -> str | N... method to_llm_content (line 95) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class BrowserAction (line 139) | class BrowserAction(Action): class BrowserNavigateAction (line 152) | class BrowserNavigateAction(BrowserAction): class BrowserNavigateTool (line 175) | class BrowserNavigateTool(ToolDefinition[BrowserNavigateAction, BrowserO... method create (line 179) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserClickAction (line 200) | class BrowserClickAction(BrowserAction): class BrowserClickTool (line 225) | class BrowserClickTool(ToolDefinition[BrowserClickAction, BrowserObserva... method create (line 229) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserTypeAction (line 250) | class BrowserTypeAction(BrowserAction): class BrowserTypeTool (line 272) | class BrowserTypeTool(ToolDefinition[BrowserTypeAction, BrowserObservati... method create (line 276) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserGetStateAction (line 297) | class BrowserGetStateAction(BrowserAction): class BrowserGetStateTool (line 316) | class BrowserGetStateTool(ToolDefinition[BrowserGetStateAction, BrowserO... method create (line 320) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserGetContentAction (line 341) | class BrowserGetContentAction(BrowserAction): class BrowserGetContentTool (line 361) | class BrowserGetContentTool( method create (line 367) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserScrollAction (line 388) | class BrowserScrollAction(BrowserAction): class BrowserScrollTool (line 407) | class BrowserScrollTool(ToolDefinition[BrowserScrollAction, BrowserObser... method create (line 411) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserGoBackAction (line 432) | class BrowserGoBackAction(BrowserAction): class BrowserGoBackTool (line 445) | class BrowserGoBackTool(ToolDefinition[BrowserGoBackAction, BrowserObser... method create (line 449) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserListTabsAction (line 470) | class BrowserListTabsAction(BrowserAction): class BrowserListTabsTool (line 483) | class BrowserListTabsTool(ToolDefinition[BrowserListTabsAction, BrowserO... method create (line 487) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserSwitchTabAction (line 508) | class BrowserSwitchTabAction(BrowserAction): class BrowserSwitchTabTool (line 526) | class BrowserSwitchTabTool(ToolDefinition[BrowserSwitchTabAction, Browse... method create (line 530) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserCloseTabAction (line 551) | class BrowserCloseTabAction(BrowserAction): class BrowserCloseTabTool (line 568) | class BrowserCloseTabTool(ToolDefinition[BrowserCloseTabAction, BrowserO... method create (line 572) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserGetStorageAction (line 593) | class BrowserGetStorageAction(BrowserAction): class BrowserGetStorageTool (line 607) | class BrowserGetStorageTool( method create (line 613) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserSetStorageAction (line 634) | class BrowserSetStorageAction(BrowserAction): class BrowserSetStorageTool (line 655) | class BrowserSetStorageTool( method create (line 661) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserStartRecordingAction (line 682) | class BrowserStartRecordingAction(BrowserAction): class BrowserStartRecordingTool (line 705) | class BrowserStartRecordingTool( method create (line 711) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserStopRecordingAction (line 732) | class BrowserStopRecordingAction(BrowserAction): class BrowserStopRecordingTool (line 751) | class BrowserStopRecordingTool( method create (line 757) | def create(cls, executor: "BrowserToolExecutor") -> Sequence[Self]: class BrowserToolSet (line 776) | class BrowserToolSet(ToolDefinition[BrowserAction, BrowserObservation]): method is_usable (line 792) | def is_usable(cls) -> bool: method create (line 798) | def create( FILE: openhands-tools/openhands/tools/browser_use/event_storage.py class EventStorage (line 17) | class EventStorage: method session_dir (line 26) | def session_dir(self) -> str | None: method file_count (line 30) | def file_count(self) -> int: method total_events (line 34) | def total_events(self) -> int: method create_session_subfolder (line 37) | def create_session_subfolder(self) -> str | None: method save_events (line 47) | def save_events(self, events: list[dict]) -> str | None: method reset (line 64) | def reset(self) -> None: FILE: openhands-tools/openhands/tools/browser_use/impl.py function recording_aware (line 40) | def recording_aware( function _current_platform (line 103) | def _current_platform(platform: str | None = None) -> str: function _windows_browser_install_paths (line 107) | def _windows_browser_install_paths() -> list[Path]: function _standard_chromium_paths (line 128) | def _standard_chromium_paths(platform: str | None = None) -> list[Path]: function _playwright_cache_dirs (line 149) | def _playwright_cache_dirs(platform: str | None = None) -> list[Path]: function _playwright_chromium_paths (line 161) | def _playwright_chromium_paths( function _path_binary_candidates (line 199) | def _path_binary_candidates(platform: str | None = None) -> tuple[str, .... function _format_browser_operation_error (line 211) | def _format_browser_operation_error( function _install_chromium (line 227) | def _install_chromium() -> bool: function _get_chromium_error_message (line 255) | def _get_chromium_error_message() -> str: class BrowserToolExecutor (line 271) | class BrowserToolExecutor(ToolExecutor[BrowserAction, BrowserObservation]): method check_chromium_available (line 283) | def check_chromium_available() -> str | None: method _ensure_chromium_available (line 311) | def _ensure_chromium_available(self) -> str: method __init__ (line 324) | def __init__( method __call__ (line 405) | def __call__( method _handle_timeout_failure (line 439) | def _handle_timeout_failure(self, error_text: str) -> BrowserObservation: method _execute_action (line 480) | async def _execute_action(self, action): method _ensure_initialized (line 555) | async def _ensure_initialized(self): method navigate (line 567) | async def navigate(self, url: str, new_tab: bool = False) -> str: method go_back (line 573) | async def go_back(self) -> str: method click (line 580) | async def click(self, index: int, new_tab: bool = False) -> str: method type_text (line 585) | async def type_text(self, index: int, text: str) -> str: method scroll (line 590) | async def scroll(self, direction: str = "down") -> str: method get_state (line 595) | async def get_state(self, include_screenshot: bool = False): method get_storage (line 625) | async def get_storage(self) -> str: method set_storage (line 630) | async def set_storage(self, storage_state: dict) -> str: method list_tabs (line 636) | async def list_tabs(self) -> str: method switch_tab (line 641) | async def switch_tab(self, tab_id: str) -> str: method close_tab (line 646) | async def close_tab(self, tab_id: str) -> str: method get_content (line 652) | async def get_content(self, extract_links: bool, start_from_char: int)... method start_recording (line 660) | async def start_recording(self) -> str: method stop_recording (line 672) | async def stop_recording(self) -> str: method close_browser (line 682) | async def close_browser(self) -> str: method cleanup (line 690) | async def cleanup(self): method close (line 706) | def close(self): method __del__ (line 727) | def __del__(self): FILE: openhands-tools/openhands/tools/browser_use/js/rrweb-loader.js function loadRrweb (line 19) | function loadRrweb() { FILE: openhands-tools/openhands/tools/browser_use/logging_fix.py function _noop (line 30) | def _noop(*args, **kwargs): class _MockManager (line 35) | class _MockManager: class _MockRoot (line 40) | class _MockRoot: method __getattr__ (line 44) | def __getattr__(self, name: str): FILE: openhands-tools/openhands/tools/browser_use/recording.py class RecordingConfig (line 55) | class RecordingConfig: function _load_js_file (line 82) | def _load_js_file(filename: str) -> str: function get_rrweb_loader_js (line 88) | def get_rrweb_loader_js(cdn_url: str) -> str: function _get_flush_events_js (line 94) | def _get_flush_events_js() -> str: function _get_start_recording_simple_js (line 99) | def _get_start_recording_simple_js() -> str: function _get_start_recording_js (line 104) | def _get_start_recording_js() -> str: function _get_stop_recording_js (line 109) | def _get_stop_recording_js() -> str: function _get_wait_for_rrweb_js (line 114) | def _get_wait_for_rrweb_js() -> str: class RecordingSession (line 125) | class RecordingSession: method __post_init__ (line 143) | def __post_init__(self) -> None: method session_dir (line 148) | def session_dir(self) -> str | None: method is_active (line 152) | def is_active(self) -> bool: method total_events (line 156) | def total_events(self) -> int: method file_count (line 160) | def file_count(self) -> int: method events (line 164) | def events(self) -> list[dict]: method _save_and_clear_events (line 167) | def _save_and_clear_events(self) -> str | None: method _set_recording_flag (line 176) | async def _set_recording_flag( method inject_scripts (line 194) | async def inject_scripts(self, browser_session: BrowserSession) -> lis... method flush_events (line 229) | async def flush_events(self, browser_session: BrowserSession) -> int: method _periodic_flush_loop (line 254) | async def _periodic_flush_loop(self, browser_session: BrowserSession) ... method _wait_for_rrweb_load (line 283) | async def _wait_for_rrweb_load(self, browser_session: BrowserSession) ... method _initialize_session_state (line 317) | def _initialize_session_state(self) -> None: method _handle_rrweb_load_failure (line 326) | async def _handle_rrweb_load_failure( method _ensure_rrweb_loaded (line 365) | async def _ensure_rrweb_loaded(self, browser_session: BrowserSession) ... method _start_flush_task (line 375) | async def _start_flush_task(self, browser_session: BrowserSession) -> ... method _execute_start_recording (line 382) | async def _execute_start_recording(self, browser_session: BrowserSessi... method start (line 413) | async def start(self, browser_session: BrowserSession) -> str: method stop (line 448) | async def stop(self, browser_session: BrowserSession) -> str: method restart_on_new_page (line 520) | async def restart_on_new_page(self, browser_session: BrowserSession) -... method reset (line 565) | def reset(self) -> None: FILE: openhands-tools/openhands/tools/browser_use/server.py class CustomBrowserUseServer (line 16) | class CustomBrowserUseServer(LogSafeBrowserUseServer): method __init__ (line 22) | def __init__(self, session_timeout_minutes: int = 10): method _is_recording (line 32) | def _is_recording(self) -> bool: method _cleanup_recording (line 36) | async def _cleanup_recording(self) -> None: method _close_browser (line 57) | async def _close_browser(self) -> str: method _close_session (line 62) | async def _close_session(self, session_id: str) -> str: method _close_all_sessions (line 69) | async def _close_all_sessions(self) -> str: method set_inject_scripts (line 74) | def set_inject_scripts(self, scripts: list[str]) -> None: method _inject_scripts_to_session (line 83) | async def _inject_scripts_to_session(self) -> None: method _flush_recording_events (line 112) | async def _flush_recording_events(self) -> int: method _restart_recording_on_new_page (line 121) | async def _restart_recording_on_new_page(self) -> None: method _start_recording (line 127) | async def _start_recording(self, output_dir: str | None = None) -> str: method _stop_recording (line 147) | async def _stop_recording(self) -> str: method _get_storage (line 166) | async def _get_storage(self) -> str: method _set_storage (line 183) | async def _set_storage(self, storage_state: dict) -> str: method _get_content (line 256) | async def _get_content(self, extract_links=False, start_from_char: int... FILE: openhands-tools/openhands/tools/delegate/definition.py class DelegateAction (line 35) | class DelegateAction(Action): class DelegateObservation (line 63) | class DelegateObservation(Observation): class DelegateTool (line 69) | class DelegateTool(ToolDefinition[DelegateAction, DelegateObservation]): method create (line 78) | def create( FILE: openhands-tools/openhands/tools/delegate/impl.py class DelegateExecutor (line 33) | class DelegateExecutor(ToolExecutor): method __init__ (line 41) | def __init__( method parent_conversation (line 53) | def parent_conversation(self) -> LocalConversation: method __call__ (line 66) | def __call__( # type: ignore[override] method _format_agent_label (line 89) | def _format_agent_label(agent_id: str, agent_type: str) -> str: method _resolve_agent_type (line 94) | def _resolve_agent_type(self, action: "DelegateAction", index: int) ->... method _run_until_finished (line 100) | def _run_until_finished( method _spawn_agents (line 121) | def _spawn_agents(self, action: "DelegateAction") -> DelegateObservation: method _delegate_tasks (line 254) | def _delegate_tasks(self, action: "DelegateAction") -> "DelegateObserv... FILE: openhands-tools/openhands/tools/delegate/visualizer.py class DelegationVisualizer (line 24) | class DelegationVisualizer(DefaultConversationVisualizer): method __init__ (line 44) | def __init__( method create_sub_visualizer (line 64) | def create_sub_visualizer(self, agent_id: str) -> "DelegationVisualizer": method _format_agent_name (line 83) | def _format_agent_name(name: str) -> str: method _create_event_block (line 120) | def _create_event_block(self, event: Event) -> Group | None: method _create_message_event_block (line 181) | def _create_message_event_block(self, event: MessageEvent) -> Group | ... FILE: openhands-tools/openhands/tools/file_editor/definition.py class FileEditorAction (line 29) | class FileEditorAction(Action): class FileEditorObservation (line 69) | class FileEditorObservation(Observation): method visualize (line 94) | def visualize(self) -> Text: method _has_meaningful_diff (line 126) | def _has_meaningful_diff(self) -> bool: class FileEditorTool (line 193) | class FileEditorTool(ToolDefinition[FileEditorAction, FileEditorObservat... method declared_resources (line 196) | def declared_resources(self, action: Action) -> DeclaredResources: method create (line 209) | def create( FILE: openhands-tools/openhands/tools/file_editor/editor.py class FileEditor (line 46) | class FileEditor: method __init__ (line 64) | def __init__( method __call__ (line 97) | def __call__( method _count_lines (line 152) | def _count_lines(self, path: Path, encoding: str = "utf-8") -> int: method str_replace (line 168) | def str_replace( method view (line 271) | def view( method _format_directory_entry (line 422) | def _format_directory_entry(self, root: Path, entry: Path) -> str: method _count_hidden_children (line 432) | def _count_hidden_children(self, path: Path) -> int: method _list_directory_for_view (line 435) | def _list_directory_for_view(self, path: Path) -> list[str]: method write_file (line 453) | def write_file(self, path: Path, file_text: str, encoding: str = "utf-... method insert (line 473) | def insert( method validate_path (line 567) | def validate_path(self, command: CommandLiteral, path: Path) -> None: method undo_edit (line 614) | def undo_edit(self, path: Path) -> FileEditorObservation: method validate_file (line 637) | def validate_file(self, path: Path) -> None: method read_file (line 675) | def read_file( method _make_output (line 718) | def _make_output( FILE: openhands-tools/openhands/tools/file_editor/exceptions.py class ToolError (line 1) | class ToolError(Exception): method __init__ (line 6) | def __init__(self, message: str): method __str__ (line 10) | def __str__(self): class EditorToolParameterMissingError (line 14) | class EditorToolParameterMissingError(ToolError): method __init__ (line 20) | def __init__(self, command: str, parameter: str): class EditorToolParameterInvalidError (line 28) | class EditorToolParameterInvalidError(ToolError): method __init__ (line 34) | def __init__(self, parameter: str, value: str, hint: str | None = None): class FileValidationError (line 44) | class FileValidationError(ToolError): method __init__ (line 50) | def __init__(self, path: str, reason: str): FILE: openhands-tools/openhands/tools/file_editor/impl.py class FileEditorExecutor (line 22) | class FileEditorExecutor(ToolExecutor): method __init__ (line 25) | def __init__( method __call__ (line 37) | def __call__( function file_editor (line 76) | def file_editor( FILE: openhands-tools/openhands/tools/file_editor/utils/diff.py class EditGroup (line 7) | class EditGroup(BaseModel): function get_edit_groups (line 12) | def get_edit_groups( function visualize_diff (line 67) | def visualize_diff( FILE: openhands-tools/openhands/tools/file_editor/utils/encoding.py class EncodingManager (line 17) | class EncodingManager: method __init__ (line 25) | def __init__(self, max_cache_size=None): method detect_encoding (line 36) | def detect_encoding(self, path: Path) -> str: method get_encoding (line 73) | def get_encoding(self, path: Path) -> str: function with_encoding (line 102) | def with_encoding(method): FILE: openhands-tools/openhands/tools/file_editor/utils/file_cache.py class FileCache (line 14) | class FileCache: method __init__ (line 19) | def __init__(self, directory: str, size_limit: int | None = None): method _get_file_path (line 30) | def _get_file_path(self, key: str) -> Path: method _update_current_size (line 34) | def _update_current_size(self): method set (line 40) | def set(self, key: str, value: Any) -> None: method _evict_oldest (line 90) | def _evict_oldest(self, exclude_path: Path | None = None): method get (line 107) | def get(self, key: str, default: Any = None) -> Any: method delete (line 118) | def delete(self, key: str) -> None: method clear (line 129) | def clear(self) -> None: method __contains__ (line 136) | def __contains__(self, key: str) -> bool: method __len__ (line 141) | def __len__(self) -> int: method __iter__ (line 146) | def __iter__(self): method __getitem__ (line 154) | def __getitem__(self, key: str) -> Any: method __setitem__ (line 157) | def __setitem__(self, key: str, value: Any) -> None: FILE: openhands-tools/openhands/tools/file_editor/utils/history.py class FileHistoryManager (line 10) | class FileHistoryManager: method __init__ (line 17) | def __init__(self, max_history_per_file: int = 5, history_dir: Path | ... method _get_metadata_key (line 38) | def _get_metadata_key(self, file_path: Path) -> str: method _get_history_key (line 41) | def _get_history_key(self, file_path: Path, counter: int) -> str: method add_history (line 44) | def add_history(self, file_path: Path, content: str): method pop_last_history (line 65) | def pop_last_history(self, file_path: Path) -> str | None: method get_metadata (line 91) | def get_metadata(self, file_path: Path): method clear_history (line 97) | def clear_history(self, file_path: Path): method get_all_history (line 110) | def get_all_history(self, file_path: Path) -> list[str]: FILE: openhands-tools/openhands/tools/file_editor/utils/shell.py function run_shell_cmd (line 13) | def run_shell_cmd( function check_tool_installed (line 66) | def check_tool_installed(tool_name: str) -> bool: FILE: openhands-tools/openhands/tools/gemini/edit/definition.py class EditAction (line 24) | class EditAction(Action): class EditObservation (line 46) | class EditObservation(Observation): method visualize (line 68) | def visualize(self) -> Text: class EditTool (line 134) | class EditTool(ToolDefinition[EditAction, EditObservation]): method declared_resources (line 137) | def declared_resources(self, action: Action) -> DeclaredResources: method create (line 151) | def create( FILE: openhands-tools/openhands/tools/gemini/edit/impl.py class EditExecutor (line 15) | class EditExecutor(ToolExecutor[EditAction, EditObservation]): method __init__ (line 18) | def __init__(self, workspace_root: str): method __call__ (line 26) | def __call__( FILE: openhands-tools/openhands/tools/gemini/list_directory/definition.py class FileEntry (line 24) | class FileEntry(BaseModel): class ListDirectoryAction (line 34) | class ListDirectoryAction(Action): class ListDirectoryObservation (line 47) | class ListDirectoryObservation(Observation): method visualize (line 63) | def visualize(self) -> Text: method _format_size (line 108) | def _format_size(self, size: int) -> str: class ListDirectoryTool (line 141) | class ListDirectoryTool(ToolDefinition[ListDirectoryAction, ListDirector... method declared_resources (line 144) | def declared_resources(self, action: Action) -> DeclaredResources: # ... method create (line 154) | def create( FILE: openhands-tools/openhands/tools/gemini/list_directory/impl.py class ListDirectoryExecutor (line 21) | class ListDirectoryExecutor( method __init__ (line 26) | def __init__(self, workspace_root: str): method __call__ (line 34) | def __call__( FILE: openhands-tools/openhands/tools/gemini/read_file/definition.py class ReadFileAction (line 24) | class ReadFileAction(Action): class ReadFileObservation (line 46) | class ReadFileObservation(Observation): method visualize (line 66) | def visualize(self) -> Text: class ReadFileTool (line 109) | class ReadFileTool(ToolDefinition[ReadFileAction, ReadFileObservation]): method declared_resources (line 112) | def declared_resources(self, action: Action) -> DeclaredResources: method create (line 127) | def create( FILE: openhands-tools/openhands/tools/gemini/read_file/impl.py class ReadFileExecutor (line 19) | class ReadFileExecutor(ToolExecutor[ReadFileAction, ReadFileObservation]): method __init__ (line 22) | def __init__(self, workspace_root: str): method __call__ (line 30) | def __call__( FILE: openhands-tools/openhands/tools/gemini/write_file/definition.py class WriteFileAction (line 24) | class WriteFileAction(Action): class WriteFileObservation (line 31) | class WriteFileObservation(Observation): method visualize (line 50) | def visualize(self) -> Text: class WriteFileTool (line 101) | class WriteFileTool(ToolDefinition[WriteFileAction, WriteFileObservation]): method declared_resources (line 104) | def declared_resources(self, action: Action) -> DeclaredResources: method create (line 118) | def create( FILE: openhands-tools/openhands/tools/gemini/write_file/impl.py class WriteFileExecutor (line 18) | class WriteFileExecutor(ToolExecutor[WriteFileAction, WriteFileObservati... method __init__ (line 21) | def __init__(self, workspace_root: str): method __call__ (line 29) | def __call__( FILE: openhands-tools/openhands/tools/glob/definition.py class GlobAction (line 23) | class GlobAction(Action): class GlobObservation (line 38) | class GlobObservation(Observation): class GlobTool (line 65) | class GlobTool(ToolDefinition[GlobAction, GlobObservation]): method declared_resources (line 68) | def declared_resources(self, action: Action) -> DeclaredResources: method create (line 85) | def create( FILE: openhands-tools/openhands/tools/glob/impl.py class GlobExecutor (line 23) | class GlobExecutor(ToolExecutor[GlobAction, GlobObservation]): method __init__ (line 32) | def __init__(self, working_dir: str): method is_parallel_safe (line 43) | def is_parallel_safe(self) -> bool: method __call__ (line 51) | def __call__( method _execute_with_ripgrep (line 136) | def _execute_with_ripgrep( method _execute_with_glob (line 185) | def _execute_with_glob( method _extract_search_path_from_pattern (line 234) | def _extract_search_path_from_pattern(pattern: str) -> tuple[Path | No... FILE: openhands-tools/openhands/tools/grep/definition.py class GrepAction (line 23) | class GrepAction(Action): class GrepObservation (line 43) | class GrepObservation(Observation): class GrepTool (line 67) | class GrepTool(ToolDefinition[GrepAction, GrepObservation]): method declared_resources (line 70) | def declared_resources(self, action: Action) -> DeclaredResources: method create (line 82) | def create( FILE: openhands-tools/openhands/tools/grep/impl.py class GrepExecutor (line 28) | class GrepExecutor(ToolExecutor[GrepAction, GrepObservation]): method __init__ (line 38) | def __init__(self, working_dir: str): method _select_search_backend (line 52) | def _select_search_backend(self) -> str: method __call__ (line 59) | def __call__( method _format_output (line 116) | def _format_output( method _path_matches_filters (line 147) | def _path_matches_filters( method _match_mtime (line 167) | def _match_mtime(self, path: Path) -> float: method _finalize_matches (line 174) | def _finalize_matches( method _build_observation (line 199) | def _build_observation( method _execute_with_ripgrep (line 226) | def _execute_with_ripgrep( method _execute_with_system_grep (line 256) | def _execute_with_system_grep( method _execute_with_python_search (line 281) | def _execute_with_python_search( FILE: openhands-tools/openhands/tools/planning_file_editor/definition.py class PlanningFileEditorAction (line 33) | class PlanningFileEditorAction(FileEditorAction): class PlanningFileEditorObservation (line 41) | class PlanningFileEditorObservation(FileEditorObservation): class PlanningFileEditorTool (line 62) | class PlanningFileEditorTool( method create (line 68) | def create( FILE: openhands-tools/openhands/tools/planning_file_editor/impl.py class PlanningFileEditorExecutor (line 18) | class PlanningFileEditorExecutor(ToolExecutor): method __init__ (line 21) | def __init__(self, workspace_root: str, plan_path: str): method __call__ (line 33) | def __call__( FILE: openhands-tools/openhands/tools/preset/default.py function register_default_tools (line 19) | def register_default_tools(enable_browser: bool = True) -> None: function get_default_tools (line 36) | def get_default_tools( function get_default_condenser (line 70) | def get_default_condenser(llm: LLM) -> CondenserBase: function get_default_agent (line 79) | def get_default_agent( function register_builtins_agents (line 98) | def register_builtins_agents(enable_browser: bool = True) -> list[str]: FILE: openhands-tools/openhands/tools/preset/gemini.py function register_gemini_tools (line 20) | def register_gemini_tools(enable_browser: bool = True) -> None: function get_gemini_tools (line 44) | def get_gemini_tools( function get_gemini_condenser (line 81) | def get_gemini_condenser(llm: LLM) -> CondenserBase: function get_gemini_agent (line 87) | def get_gemini_agent( FILE: openhands-tools/openhands/tools/preset/gpt5.py function register_gpt5_tools (line 19) | def register_gpt5_tools(enable_browser: bool = True) -> None: function get_gpt5_tools (line 35) | def get_gpt5_tools(enable_browser: bool = True) -> list[Tool]: function get_gpt5_condenser (line 59) | def get_gpt5_condenser(llm: LLM) -> CondenserBase: function get_gpt5_agent (line 64) | def get_gpt5_agent(llm: LLM, cli_mode: bool = False) -> Agent: FILE: openhands-tools/openhands/tools/preset/planning.py function format_plan_structure (line 56) | def format_plan_structure() -> str: function get_plan_headers (line 78) | def get_plan_headers() -> str: function register_planning_tools (line 91) | def register_planning_tools() -> None: function get_planning_tools (line 105) | def get_planning_tools(plan_path: str | None = None) -> list[Tool]: function get_planning_condenser (line 136) | def get_planning_condenser(llm: LLM) -> LLMSummarizingCondenser: function get_planning_agent (line 154) | def get_planning_agent( FILE: openhands-tools/openhands/tools/task/definition.py class TaskAction (line 37) | class TaskAction(Action): class TaskObservation (line 65) | class TaskObservation(Observation): method _get_task_info (line 72) | def _get_task_info(self) -> str: method visualize (line 78) | def visualize(self) -> Text: method to_llm_content (line 91) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class TaskTool (line 169) | class TaskTool(ToolDefinition[TaskAction, TaskObservation]): method declared_resources (line 172) | def declared_resources(self, action: Action) -> DeclaredResources: # ... method create (line 176) | def create( class TaskToolSet (line 198) | class TaskToolSet(ToolDefinition[TaskAction, TaskObservation]): method create (line 217) | def create( FILE: openhands-tools/openhands/tools/task/impl.py class TaskExecutor (line 20) | class TaskExecutor(ToolExecutor): method __init__ (line 23) | def __init__(self, manager: TaskManager): method __call__ (line 26) | def __call__( method close (line 68) | def close(self) -> None: FILE: openhands-tools/openhands/tools/task/manager.py class TaskStatus (line 48) | class TaskStatus(StrEnum): class Task (line 61) | class Task(BaseModel): method set_result (line 79) | def set_result(self, result: str) -> None: method set_error (line 85) | def set_error(self, error: str) -> None: class TaskManager (line 92) | class TaskManager: method __init__ (line 95) | def __init__( method _ensure_parent (line 109) | def _ensure_parent(self, conversation: LocalConversation) -> None: method parent_conversation (line 122) | def parent_conversation(self) -> LocalConversation: method _generate_ids (line 130) | def _generate_ids(self) -> tuple[str, uuid.UUID]: method _evict_task (line 137) | def _evict_task(self, task: Task) -> None: method start_task (line 144) | def start_task( method _resume_task (line 183) | def _resume_task(self, resume: str, subagent_type: str) -> Task: method _create_task (line 218) | def _create_task( method _get_conversation (line 263) | def _get_conversation( method _get_sub_agent (line 291) | def _get_sub_agent(self, subagent_type: str) -> Agent: method _get_sub_agent_from_factory (line 300) | def _get_sub_agent_from_factory(self, factory: "AgentFactory") -> Agent: method _run_task (line 319) | def _run_task(self, task: Task, prompt: str) -> Task: method _run_until_finished (line 344) | def _run_until_finished( method _set_confirmation_policy (line 365) | def _set_confirmation_policy( method _update_parent_metrics (line 381) | def _update_parent_metrics(self, parent: LocalConversation, task: Task... method close (line 391) | def close(self) -> None: FILE: openhands-tools/openhands/tools/task_tracker/definition.py class TaskItem (line 32) | class TaskItem(BaseModel): class TaskTrackerAction (line 42) | class TaskTrackerAction(Action): method visualize (line 55) | def visualize(self) -> Text: class TaskTrackerObservation (line 74) | class TaskTrackerObservation(Observation): method visualize (line 85) | def visualize(self) -> Text: class TaskTrackerExecutor (line 148) | class TaskTrackerExecutor(ToolExecutor[TaskTrackerAction, TaskTrackerObs... method __init__ (line 153) | def __init__(self, save_dir: str | None = None): method __call__ (line 168) | def __call__( method _format_task_list (line 212) | def _format_task_list(self, task_list: list[TaskItem]) -> str: method _load_tasks (line 233) | def _load_tasks(self) -> None: method _save_tasks (line 252) | def _save_tasks(self) -> None: class TaskTrackerTool (line 403) | class TaskTrackerTool(ToolDefinition[TaskTrackerAction, TaskTrackerObser... method create (line 407) | def create(cls, conv_state: "ConversationState") -> Sequence["TaskTrac... FILE: openhands-tools/openhands/tools/terminal/definition.py class TerminalAction (line 37) | class TerminalAction(Action): method visualize (line 68) | def visualize(self) -> Text: class TerminalObservation (line 97) | class TerminalObservation(Observation): method command_id (line 120) | def command_id(self) -> int | None: method to_llm_content (line 125) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: method visualize (line 155) | def visualize(self) -> Text: class TerminalTool (line 219) | class TerminalTool(ToolDefinition[TerminalAction, TerminalObservation]): method declared_resources (line 222) | def declared_resources(self, action: Action) -> DeclaredResources: # ... method create (line 234) | def create( FILE: openhands-tools/openhands/tools/terminal/impl.py class TerminalExecutor (line 61) | class TerminalExecutor(ToolExecutor[TerminalAction, TerminalObservation]): method __init__ (line 64) | def __init__( method is_pooled (line 127) | def is_pooled(self) -> bool: method _initialize_pool (line 131) | def _initialize_pool(self) -> None: method _is_recoverable_tmux_pool_error (line 145) | def _is_recoverable_tmux_pool_error(error: Exception) -> bool: method _recover_tmux_pool (line 152) | def _recover_tmux_pool(self, failed_pool: TmuxPanePool) -> None: method _tmux_pool_recovery_observation (line 164) | def _tmux_pool_recovery_observation( method working_dir (line 176) | def working_dir(self) -> str: method session (line 181) | def session(self) -> TerminalSession: method _wrap_session (line 200) | def _wrap_session(self, terminal: PooledTmuxTerminal) -> TerminalSession: method _discard_session (line 214) | def _discard_session(self, terminal: PooledTmuxTerminal) -> None: method _prepare_pooled_session (line 231) | def _prepare_pooled_session(session: TerminalSession) -> None: method _powershell_quote (line 267) | def _powershell_quote(value: str) -> str: method _bash_quote (line 272) | def _bash_quote(value: str) -> str: method _build_env_exports (line 282) | def _build_env_exports( method _export_envs (line 313) | def _export_envs( method _mask_observation (line 353) | def _mask_observation( method reset (line 383) | def reset(self) -> TerminalObservation: method _reset_single_session (line 387) | def _reset_single_session(self) -> TerminalObservation: method _execute_single_session (line 426) | def _execute_single_session( method _execute_pooled (line 464) | def _execute_pooled( method __call__ (line 533) | def __call__( method close (line 546) | def close(self) -> None: FILE: openhands-tools/openhands/tools/terminal/metadata.py class CmdOutputMetadata (line 20) | class CmdOutputMetadata(BaseModel): method to_ps1_prompt (line 45) | def to_ps1_prompt(cls) -> str: method matches_ps1_metadata (line 66) | def matches_ps1_metadata(cls, string: str) -> list[re.Match[str]]: method from_ps1_match (line 82) | def from_ps1_match(cls, match: re.Match[str]) -> "CmdOutputMetadata": FILE: openhands-tools/openhands/tools/terminal/terminal/factory.py function _is_tmux_available (line 16) | def _is_tmux_available() -> bool: function _get_powershell_command (line 31) | def _get_powershell_command(explicit_shell_path: str | None = None) -> s... function _is_powershell_available (line 57) | def _is_powershell_available() -> bool: function _create_windows_terminal (line 62) | def _create_windows_terminal( function create_terminal_session (line 78) | def create_terminal_session( FILE: openhands-tools/openhands/tools/terminal/terminal/interface.py function parse_ctrl_key (line 39) | def parse_ctrl_key(text: str) -> str | None: class TerminalInterface (line 59) | class TerminalInterface(ABC): method __init__ (line 72) | def __init__( method initialize (line 89) | def initialize(self) -> None: method close (line 98) | def close(self) -> None: method send_keys (line 107) | def send_keys(self, text: str, enter: bool = True) -> None: method read_screen (line 124) | def read_screen(self) -> str: method clear_screen (line 132) | def clear_screen(self) -> None: method interrupt (line 140) | def interrupt(self) -> bool: method is_running (line 151) | def is_running(self) -> bool: method initialized (line 162) | def initialized(self) -> bool: method closed (line 167) | def closed(self) -> bool: method is_powershell (line 171) | def is_powershell(self) -> bool: class TerminalSessionBase (line 180) | class TerminalSessionBase(ABC): method __init__ (line 194) | def __init__( method initialize (line 217) | def initialize(self) -> None: method execute (line 226) | def execute(self, action: TerminalAction) -> TerminalObservation: method close (line 241) | def close(self) -> None: method interrupt (line 249) | def interrupt(self) -> bool: method is_running (line 260) | def is_running(self) -> bool: method cwd (line 271) | def cwd(self) -> str: method __del__ (line 275) | def __del__(self) -> None: FILE: openhands-tools/openhands/tools/terminal/terminal/subprocess_terminal.py function _normalize_eols (line 60) | def _normalize_eols(raw: bytes) -> bytes: class SubprocessTerminal (line 66) | class SubprocessTerminal(TerminalInterface): method __init__ (line 82) | def __init__( method initialize (line 102) | def initialize(self) -> None: method close (line 195) | def close(self) -> None: method _write_pty (line 235) | def _write_pty(self, data: bytes) -> None: method _read_output_continuously_pty (line 248) | def _read_output_continuously_pty(self) -> None: method _add_text_to_buffer (line 283) | def _add_text_to_buffer(self, text: str) -> None: method _wait_for_output (line 305) | def _wait_for_output(self, pattern: str | re.Pattern, timeout: float =... method _wait_for_prompt (line 325) | def _wait_for_prompt(self, timeout: float = 5.0) -> bool: method send_keys (line 357) | def send_keys(self, text: str, enter: bool = True) -> None: method _wait_for_pty_writable (line 406) | def _wait_for_pty_writable(self, timeout: float) -> bool: method _send_multiline_with_flow_control (line 416) | def _send_multiline_with_flow_control(self, lines: list[str], enter: b... method read_screen (line 442) | def read_screen(self) -> str: method clear_screen (line 461) | def clear_screen(self) -> None: method interrupt (line 488) | def interrupt(self) -> bool: method is_running (line 501) | def is_running(self) -> bool: FILE: openhands-tools/openhands/tools/terminal/terminal/terminal_session.py class TerminalCommandStatus (line 35) | class TerminalCommandStatus(Enum): function _remove_command_prefix (line 45) | def _remove_command_prefix(command_output: str, command: str) -> str: function _remove_powershell_echo (line 49) | def _remove_powershell_echo(command_output: str, command: str) -> str: class TerminalSession (line 59) | class TerminalSession(TerminalSessionBase): method __init__ (line 70) | def __init__( method attach_to_existing (line 97) | def attach_to_existing( method initialize (line 112) | def initialize(self) -> None: method close (line 118) | def close(self) -> None: method interrupt (line 125) | def interrupt(self) -> bool: method is_running (line 129) | def is_running(self) -> bool: method _is_special_key (line 139) | def _is_special_key(self, command: str) -> bool: method _get_command_output (line 145) | def _get_command_output( method _handle_completed_command (line 189) | def _handle_completed_command( method _handle_nochange_timeout_command (line 292) | def _handle_nochange_timeout_command( method _handle_hard_timeout_command (line 330) | def _handle_hard_timeout_command( method _ready_for_next_command (line 369) | def _ready_for_next_command(self) -> None: method _combine_outputs_between_matches (line 374) | def _combine_outputs_between_matches( method execute (line 402) | def execute(self, action: TerminalAction) -> TerminalObservation: FILE: openhands-tools/openhands/tools/terminal/terminal/tmux_pane_pool.py class PooledTmuxTerminal (line 36) | class PooledTmuxTerminal(TmuxTerminal): method close (line 46) | def close(self) -> None: class PaneHandle (line 54) | class PaneHandle: class TmuxPanePool (line 61) | class TmuxPanePool: method __post_init__ (line 105) | def __post_init__(self) -> None: method initialize (line 110) | def initialize(self) -> None: method close (line 140) | def close(self) -> None: method _create_pane (line 161) | def _create_pane(self) -> PooledTmuxTerminal: method checkout (line 203) | def checkout(self, timeout: float | None = None) -> PooledTmuxTerminal: method checkin (line 238) | def checkin(self, terminal: PooledTmuxTerminal) -> None: method replace (line 250) | def replace(self, old_terminal: PooledTmuxTerminal) -> PooledTmuxTermi... method pane (line 286) | def pane(self, timeout: float | None = None) -> Iterator[PaneHandle]: FILE: openhands-tools/openhands/tools/terminal/terminal/tmux_terminal.py class TmuxTerminal (line 43) | class TmuxTerminal(TerminalInterface): method __init__ (line 56) | def __init__( method initialize (line 64) | def initialize(self) -> None: method close (line 120) | def close(self) -> None: method send_keys (line 134) | def send_keys(self, text: str, enter: bool = True) -> None: method read_screen (line 171) | def read_screen(self) -> str: method clear_screen (line 189) | def clear_screen(self) -> None: method interrupt (line 206) | def interrupt(self) -> bool: method is_running (line 221) | def is_running(self) -> bool: FILE: openhands-tools/openhands/tools/terminal/terminal/windows_terminal.py class WindowsTerminal (line 56) | class WindowsTerminal(TerminalInterface): method __init__ (line 68) | def __init__( method initialize (line 84) | def initialize(self) -> None: method _wait_for_startup_output (line 125) | def _wait_for_startup_output(self) -> None: method _preserve_latest_metadata_block (line 135) | def _preserve_latest_metadata_block(self) -> bool: method _seed_metadata_prompt (line 151) | def _seed_metadata_prompt(self) -> None: method close (line 170) | def close(self) -> None: method send_keys (line 207) | def send_keys(self, text: str, enter: bool = True) -> None: method _metadata_suffix (line 236) | def _metadata_suffix(self) -> str: method _escape_single_quoted (line 269) | def _escape_single_quoted(text: str) -> str: method _write_to_stdin (line 272) | def _write_to_stdin(self, text: str) -> None: method _read_output (line 282) | def _read_output(self) -> None: method _get_buffered_output (line 311) | def _get_buffered_output(self, clear: bool) -> str: method read_screen (line 318) | def read_screen(self) -> str: method clear_screen (line 322) | def clear_screen(self) -> None: method _terminate_child_processes (line 332) | def _terminate_child_processes(self) -> bool: method interrupt (line 388) | def interrupt(self) -> bool: method is_running (line 418) | def is_running(self) -> bool: method is_powershell (line 432) | def is_powershell(self) -> bool: method __enter__ (line 435) | def __enter__(self) -> "WindowsTerminal": method __exit__ (line 439) | def __exit__(self, exc_type: object, exc_val: object, exc_tb: object) ... method __del__ (line 443) | def __del__(self) -> None: FILE: openhands-tools/openhands/tools/terminal/utils/command.py function split_bash_commands (line 14) | def split_bash_commands(commands: str) -> list[str]: function escape_bash_special_chars (line 70) | def escape_bash_special_chars(command: str) -> str: FILE: openhands-tools/openhands/tools/terminal/utils/escape_filter.py function _filter_complete_queries (line 91) | def _filter_complete_queries(output_bytes: bytes) -> bytes: class TerminalQueryFilter (line 101) | class TerminalQueryFilter: method __init__ (line 118) | def __init__(self) -> None: method reset (line 121) | def reset(self) -> None: method filter (line 125) | def filter(self, output: str) -> str: method flush (line 163) | def flush(self) -> str: function filter_terminal_queries (line 181) | def filter_terminal_queries(output: str) -> str: FILE: openhands-tools/openhands/tools/tom_consult/definition.py class ConsultTomAction (line 30) | class ConsultTomAction(Action): class SleeptimeComputeAction (line 51) | class SleeptimeComputeAction(Action): class ConsultTomObservation (line 64) | class ConsultTomObservation(Observation): method to_llm_content (line 79) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class SleeptimeComputeObservation (line 95) | class SleeptimeComputeObservation(Observation): method to_llm_content (line 107) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class TomConsultTool (line 149) | class TomConsultTool(ToolDefinition[ConsultTomAction, ConsultTomObservat... method declared_resources (line 152) | def declared_resources(self, action: Action) -> DeclaredResources: # ... method create (line 162) | def create( class SleeptimeComputeTool (line 210) | class SleeptimeComputeTool( method create (line 217) | def create( FILE: openhands-tools/openhands/tools/tom_consult/executor.py class TomConsultExecutor (line 34) | class TomConsultExecutor( method __init__ (line 43) | def __init__( method _get_tom_agent (line 69) | def _get_tom_agent(self) -> "ToMAgent": method __call__ (line 86) | def __call__( method _format_events (line 105) | def _format_events( method _consult_tom (line 162) | def _consult_tom( method _sleeptime_compute (line 249) | def _sleeptime_compute( method _extract_session_data (line 343) | def _extract_session_data( method _load_processing_history (line 383) | def _load_processing_history(self) -> dict[str, Any]: method _save_processing_history (line 397) | def _save_processing_history(self, session_ids: list[str]) -> None: FILE: openhands-tools/openhands/tools/utils/__init__.py function _check_command_available (line 13) | def _check_command_available( function _check_ripgrep_available (line 36) | def _check_ripgrep_available() -> bool: function _check_grep_available (line 42) | def _check_grep_available() -> bool: function _log_ripgrep_fallback_warning (line 48) | def _log_ripgrep_fallback_warning(tool_name: str, fallback_method: str) ... FILE: openhands-tools/openhands/tools/utils/timeout.py class TimeoutError (line 4) | class TimeoutError(Exception): function run_with_timeout (line 10) | def run_with_timeout(func, timeout, *args, **kwargs): FILE: openhands-workspace/openhands/workspace/__init__.py function __getattr__ (line 37) | def __getattr__(name: str): FILE: openhands-workspace/openhands/workspace/apptainer/workspace.py class ApptainerWorkspace (line 28) | class ApptainerWorkspace(RemoteWorkspace): method model_post_init (line 143) | def model_post_init(self, context: Any) -> None: method _prepare_sif_image (line 211) | def _prepare_sif_image(self) -> str: method _start_container (line 245) | def _start_container(self) -> None: method _stream_logs (line 311) | def _stream_logs(self) -> None: method _wait_for_health (line 330) | def _wait_for_health(self, *, timeout: float) -> None: method __enter__ (line 354) | def __enter__(self) -> "ApptainerWorkspace": method __exit__ (line 358) | def __exit__(self, exc_type, exc_val, exc_tb) -> None: # type: ignore... method __del__ (line 362) | def __del__(self) -> None: method cleanup (line 368) | def cleanup(self) -> None: FILE: openhands-workspace/openhands/workspace/cloud/workspace.py function _is_retryable_error (line 39) | def _is_retryable_error(error: BaseException) -> bool: class OpenHandsCloudWorkspace (line 46) | class OpenHandsCloudWorkspace(RemoteWorkspace): method default_conversation_tags (line 156) | def default_conversation_tags(self) -> dict[str, str]: method client (line 200) | def client(self) -> httpx.Client: method _api_headers (line 217) | def _api_headers(self) -> dict[str, str]: method model_post_init (line 224) | def model_post_init(self, context: Any) -> None: method _init_local_agent_server_mode (line 238) | def _init_local_agent_server_mode(self) -> None: method _start_sandbox (line 290) | def _start_sandbox(self) -> None: method _create_new_sandbox (line 324) | def _create_new_sandbox(self) -> None: method _resume_existing_sandbox (line 348) | def _resume_existing_sandbox(self) -> None: method _wait_until_sandbox_ready (line 364) | def _wait_until_sandbox_ready(self) -> None: method _check_agent_server_health (line 410) | def _check_agent_server_health(self, agent_server_url: str) -> None: method _resume_sandbox (line 425) | def _resume_sandbox(self) -> None: method _get_agent_server_url (line 437) | def _get_agent_server_url(self) -> str | None: method pause (line 448) | def pause(self) -> None: method resume (line 462) | def resume(self) -> None: method _send_api_request (line 478) | def _send_api_request(self, method: str, url: str, **kwargs: Any) -> h... method cleanup (line 503) | def cleanup(self) -> None: method _settings_base_url (line 557) | def _settings_base_url(self) -> str: method _session_headers (line 562) | def _session_headers(self) -> dict[str, str]: method get_llm (line 572) | def get_llm(self, **llm_kwargs: Any) -> LLM: method get_secrets (line 623) | def get_secrets(self, names: list[str] | None = None) -> dict[str, Loo... method get_mcp_config (line 681) | def get_mcp_config(self) -> dict[str, Any]: method _send_settings_request (line 773) | def _send_settings_request( method register_conversation (line 799) | def register_conversation(self, conversation_id: str) -> None: method conversation_id (line 813) | def conversation_id(self) -> str | None: method __del__ (line 821) | def __del__(self) -> None: method __enter__ (line 824) | def __enter__(self) -> OpenHandsCloudWorkspace: method __exit__ (line 827) | def __exit__(self, exc_type: Any, exc_val: Any, exc_tb: Any) -> None: method _send_completion_callback (line 831) | def _send_completion_callback( method _get_secret_value (line 871) | def _get_secret_value(self, name: str) -> str | None: method clone_repos (line 922) | def clone_repos( method get_repos_context (line 933) | def get_repos_context(self, repo_mappings: dict[str, RepoMapping]) -> ... method load_skills_from_agent_server (line 940) | def load_skills_from_agent_server( method _call_skills_api (line 962) | def _call_skills_api( FILE: openhands-workspace/openhands/workspace/docker/__init__.py function __getattr__ (line 14) | def __getattr__(name: str): FILE: openhands-workspace/openhands/workspace/docker/dev_workspace.py class DockerDevWorkspace (line 10) | class DockerDevWorkspace(DockerWorkspace): method _validate_images (line 53) | def _validate_images(self): method _build_image_from_base (line 67) | def _build_image_from_base( method get_image (line 103) | def get_image(self) -> str: FILE: openhands-workspace/openhands/workspace/docker/workspace.py function check_port_available (line 23) | def check_port_available(port: int) -> bool: function find_available_tcp_port (line 38) | def find_available_tcp_port( class DockerWorkspace (line 54) | class DockerWorkspace(RemoteWorkspace): method _validate_server_image (line 136) | def _validate_server_image(self): method _validate_mount_dir (line 143) | def _validate_mount_dir(self): method model_post_init (line 154) | def model_post_init(self, context: Any) -> None: method get_image (line 161) | def get_image(self) -> str: method _start_container (line 174) | def _start_container(self, image: str, context: Any) -> None: method _stream_docker_logs (line 290) | def _stream_docker_logs(self) -> None: method _wait_for_health (line 317) | def _wait_for_health(self, *, timeout: float) -> None: method __enter__ (line 354) | def __enter__(self) -> "DockerWorkspace": method __exit__ (line 358) | def __exit__(self, exc_type, exc_val, exc_tb) -> None: # type: ignore... method __del__ (line 362) | def __del__(self) -> None: method cleanup (line 366) | def cleanup(self) -> None: method pause (line 391) | def pause(self) -> None: method resume (line 409) | def resume(self) -> None: FILE: openhands-workspace/openhands/workspace/remote_api/workspace.py class APIRemoteWorkspace (line 19) | class APIRemoteWorkspace(RemoteWorkspace): method client (line 93) | def client(self) -> httpx.Client: method _api_headers (line 111) | def _api_headers(self): method model_post_init (line 125) | def model_post_init(self, context: Any) -> None: method _start_or_attach_to_runtime (line 141) | def _start_or_attach_to_runtime(self) -> None: method _check_existing_runtime (line 157) | def _check_existing_runtime(self) -> bool: method _start_runtime (line 184) | def _start_runtime(self) -> None: method _resume_runtime (line 235) | def _resume_runtime(self) -> None: method pause (line 245) | def pause(self) -> None: method resume (line 267) | def resume(self) -> None: method _parse_runtime_response (line 283) | def _parse_runtime_response(self, response: httpx.Response) -> None: method _wait_until_runtime_alive (line 292) | def _wait_until_runtime_alive(self) -> None: method _wait_until_runtime_alive_once (line 304) | def _wait_until_runtime_alive_once(self) -> None: method _send_api_request (line 369) | def _send_api_request(self, method: str, url: str, **kwargs: Any) -> h... method cleanup (line 389) | def cleanup(self) -> None: method __del__ (line 418) | def __del__(self) -> None: method __enter__ (line 421) | def __enter__(self) -> "APIRemoteWorkspace": method __exit__ (line 424) | def __exit__(self, exc_type: Any, exc_val: Any, exc_tb: Any) -> None: FILE: scripts/agent_server_ui/static/app-dev.js class OpenHandsWebChat (line 1) | class OpenHandsWebChat { method constructor (line 2) | constructor() { method initializeElements (line 20) | initializeElements() { method attachEventListeners (line 46) | attachEventListeners() { method setupTextareaAutoResize (line 92) | setupTextareaAutoResize() { method showLoading (line 99) | showLoading() { method hideLoading (line 103) | hideLoading() { method updateConnectionStatus (line 107) | updateConnectionStatus(status) { method apiRequest (line 129) | async apiRequest(endpoint, options = {}) { method loadConversations (line 147) | async loadConversations() { method addConversationToSidebar (line 169) | addConversationToSidebar(conversation) { method getConversationTitle (line 192) | getConversationTitle(conversation) { method selectConversation (line 202) | async selectConversation(conversationId) { method loadConversationEvents (line 235) | async loadConversationEvents(conversationId) { method connectWebSocket (line 257) | connectWebSocket(conversationId) { method handleWebSocketMessage (line 290) | handleWebSocketMessage(data) { method displayEvent (line 308) | displayEvent(event) { method displayMessage (line 320) | displayMessage(event, messageElement) { method displaySystemEvent (line 336) | displaySystemEvent(event, messageElement) { method formatMessageContent (line 371) | formatMessageContent(content) { method formatEventContent (line 380) | formatEventContent(event) { method showTypingIndicator (line 398) | showTypingIndicator() { method hideTypingIndicator (line 402) | hideTypingIndicator() { method scrollToBottom (line 406) | scrollToBottom() { method enableChatControls (line 410) | enableChatControls() { method disableChatControls (line 418) | disableChatControls() { method updateConversationStatus (line 426) | updateConversationStatus(status) { method sendMessage (line 443) | async sendMessage() { method pauseConversation (line 469) | async pauseConversation() { method resumeConversation (line 483) | async resumeConversation() { method deleteConversation (line 498) | async deleteConversation() { method showNewConversationModal (line 545) | showNewConversationModal() { method hideNewConversationModal (line 550) | hideNewConversationModal() { method createNewConversation (line 555) | async createNewConversation() { method showError (line 608) | showError(message) { FILE: scripts/agent_server_ui/static/app.js class OpenHandsWebChat (line 1) | class OpenHandsWebChat { method constructor (line 2) | constructor() { method initializeElements (line 22) | initializeElements() { method attachEventListeners (line 51) | attachEventListeners() { method setupTextareaAutoResize (line 112) | setupTextareaAutoResize() { method showLoading (line 119) | showLoading() { method hideLoading (line 123) | hideLoading() { method updateConnectionStatus (line 127) | updateConnectionStatus(status) { method apiRequest (line 149) | async apiRequest(endpoint, options = {}) { method loadConversations (line 167) | async loadConversations() { method addConversationToSidebar (line 189) | addConversationToSidebar(conversation) { method getConversationTitle (line 212) | getConversationTitle(conversation) { method selectConversation (line 222) | async selectConversation(conversationId) { method loadConversationEvents (line 255) | async loadConversationEvents(conversationId) { method connectWebSocket (line 277) | connectWebSocket(conversationId) { method handleWebSocketMessage (line 310) | handleWebSocketMessage(data) { method displayEvent (line 328) | displayEvent(event) { method displayMessage (line 340) | displayMessage(event, messageElement) { method displaySystemEvent (line 356) | displaySystemEvent(event, messageElement) { method formatMessageContent (line 393) | formatMessageContent(content) { method formatEventContent (line 402) | formatEventContent(event) { method showTypingIndicator (line 420) | showTypingIndicator() { method hideTypingIndicator (line 424) | hideTypingIndicator() { method scrollToBottom (line 428) | scrollToBottom() { method enableChatControls (line 432) | enableChatControls() { method disableChatControls (line 440) | disableChatControls() { method updateConversationStatus (line 448) | updateConversationStatus(status) { method sendMessage (line 465) | async sendMessage() { method pauseConversation (line 491) | async pauseConversation() { method resumeConversation (line 505) | async resumeConversation() { method deleteConversation (line 520) | async deleteConversation() { method saveDialogSettings (line 568) | saveDialogSettings() { method loadDialogSettings (line 576) | loadDialogSettings() { method getDefaultJsonParameters (line 597) | getDefaultJsonParameters() { method resetJsonParameters (line 620) | resetJsonParameters() { method showJsonExample (line 625) | showJsonExample() { method validateJsonParameters (line 636) | validateJsonParameters() { method showNewConversationModal (line 658) | showNewConversationModal() { method hideNewConversationModal (line 664) | hideNewConversationModal() { method createNewConversation (line 669) | async createNewConversation() { method showError (line 730) | showError(message) { FILE: scripts/auto_close_duplicate_issues.py function parse_args (line 28) | def parse_args() -> argparse.Namespace: function github_headers (line 41) | def github_headers() -> dict[str, str]: function request_json (line 53) | def request_json( function parse_timestamp (line 90) | def parse_timestamp(value: str) -> datetime: function ensure_page_limit (line 97) | def ensure_page_limit(page: int, resource_name: str) -> None: function list_open_issues (line 102) | def list_open_issues(repository: str) -> list[dict[str, Any]]: function list_issue_comments (line 125) | def list_issue_comments(repository: str, issue_number: int) -> list[dict... function list_comment_reactions (line 144) | def list_comment_reactions(repository: str, comment_id: int) -> list[dic... function extract_duplicate_metadata (line 163) | def extract_duplicate_metadata(comment_body: str) -> tuple[int | None, b... function find_latest_auto_close_comment (line 170) | def find_latest_auto_close_comment( function issue_has_label (line 202) | def issue_has_label(issue: dict[str, Any], label_name: str) -> bool: function user_id_from_item (line 212) | def user_id_from_item(item: dict[str, Any]) -> int | None: function has_reaction_from_user (line 220) | def has_reaction_from_user( function has_veto_note (line 231) | def has_veto_note(comments: list[dict[str, Any]]) -> bool: function is_non_bot_comment (line 237) | def is_non_bot_comment(comment: dict[str, Any]) -> bool: function remove_candidate_label (line 254) | def remove_candidate_label( function post_veto_note (line 271) | def post_veto_note(repository: str, issue_number: int, *, dry_run: bool)... function close_issue_as_duplicate (line 290) | def close_issue_as_duplicate( function keep_open_due_to_newer_comments (line 322) | def keep_open_due_to_newer_comments( function main (line 344) | def main() -> int: FILE: scripts/check_import_rules.py class ImportChecker (line 35) | class ImportChecker(ast.NodeVisitor): method __init__ (line 38) | def __init__(self): method visit_Import (line 41) | def visit_Import(self, node: ast.Import) -> None: method visit_ImportFrom (line 46) | def visit_ImportFrom(self, node: ast.ImportFrom) -> None: function get_imports_from_file (line 52) | def get_imports_from_file(file_path: Path) -> set[str]: function check_sdk_imports (line 68) | def check_sdk_imports(sdk_path: Path) -> list[tuple[Path, str]]: function check_tools_imports (line 83) | def check_tools_imports(tools_path: Path) -> list[tuple[Path, str]]: function check_agent_server_imports (line 98) | def check_agent_server_imports(agent_server_path: Path) -> list[tuple[Pa... function main (line 113) | def main(files: list[str] | None = None) -> int: FILE: scripts/check_tool_registration.py class ToolChecker (line 16) | class ToolChecker(ast.NodeVisitor): method __init__ (line 19) | def __init__(self, file_path: Path): method visit_ImportFrom (line 25) | def visit_ImportFrom(self, node: ast.ImportFrom) -> None: method visit_ClassDef (line 33) | def visit_ClassDef(self, node: ast.ClassDef) -> None: method visit_Expr (line 44) | def visit_Expr(self, node: ast.Expr) -> None: method _get_name (line 56) | def _get_name(self, node: ast.expr) -> str: function check_tool_registration (line 67) | def check_tool_registration( function main (line 125) | def main(files: list[str] | None = None) -> int: FILE: scripts/completion_logs_viewer.py function format_timestamp (line 34) | def format_timestamp(timestamp: float) -> str: function render_message (line 41) | def render_message(msg: dict[str, Any]) -> None: function render_response (line 67) | def render_response(resp: dict[str, Any]) -> None: function load_json (line 82) | def load_json(path_str: str) -> dict[str, Any]: function list_runs (line 92) | def list_runs(root: Path) -> list[Path]: function list_log_files (line 102) | def list_log_files(run_dir: Path) -> list[Path]: function main (line 112) | def main() -> None: FILE: scripts/conversation_viewer.py class Conversation (line 45) | class Conversation: function load_json (line 52) | def load_json(path: Path) -> dict[str, Any]: function add_filename (line 57) | def add_filename(event: dict[str, Any], filename: str) -> dict[str, Any]: function load_conversation (line 64) | def load_conversation(path_str: str) -> Conversation: function get_last_event_timestamp (line 100) | def get_last_event_timestamp(conversation_path_str: str) -> str: function conversation_dirs (line 143) | def conversation_dirs(root: Path) -> list[Path]: function extract_text_blocks (line 160) | def extract_text_blocks(blocks: Iterable[Any] | None) -> str: function get_event_text (line 176) | def get_event_text(event: dict[str, Any]) -> str: function truncate (line 203) | def truncate(text: str, limit: int = 160) -> str: function event_summary_rows (line 210) | def event_summary_rows(events: Sequence[dict[str, Any]]) -> list[dict[st... function draw_base_state (line 233) | def draw_base_state(base_state: dict[str, Any]) -> None: function create_conversation_zip (line 250) | def create_conversation_zip(conversation_path: Path) -> bytes: function draw_event_detail (line 278) | def draw_event_detail(event: dict[str, Any]) -> None: function main (line 302) | def main() -> None: FILE: scripts/convert_legacy_skills.py function normalize_skill_name (line 38) | def normalize_skill_name(name: str) -> str: function validate_skill_name (line 52) | def validate_skill_name(name: str) -> list[str]: function generate_description (line 68) | def generate_description( function convert_legacy_skill (line 96) | def convert_legacy_skill( function convert_skills_directory (line 201) | def convert_skills_directory( function main (line 230) | def main(): FILE: scripts/event_sourcing_benchmarks/bench_persist_latency.py function measure_persist_latencies (line 31) | def measure_persist_latencies(event_files: list[dict]) -> list[dict]: function main (line 65) | def main(): FILE: scripts/event_sourcing_benchmarks/bench_replay_and_recovery.py function collect_event_pool (line 36) | def collect_event_pool(eval_dir: str, target_count: int = 2000) -> list[... function benchmark_replay_and_recovery (line 65) | def benchmark_replay_and_recovery( function main (line 178) | def main(): FILE: scripts/event_sourcing_benchmarks/bench_storage_growth.py function analyze_conversation (line 23) | def analyze_conversation(tarpath: str) -> dict | None: function main (line 62) | def main(): FILE: scripts/event_sourcing_benchmarks/benchmark_utils.py function extract_conversation (line 8) | def extract_conversation(tarpath: str, dest: str) -> str | None: function read_event_files (line 18) | def read_event_files(events_dir: str) -> list[dict]: function register_tool_types (line 44) | def register_tool_types() -> None: FILE: scripts/issue_duplicate_check_openhands.py function parse_args (line 52) | def parse_args() -> argparse.Namespace: function github_headers (line 88) | def github_headers() -> dict[str, str]: function openhands_headers (line 100) | def openhands_headers() -> dict[str, str]: function request_json (line 110) | def request_json( function fetch_issue (line 141) | def fetch_issue(repository: str, issue_number: int) -> dict[str, Any]: function escape_json_text (line 151) | def escape_json_text(value: str | None) -> str: function build_prompt (line 155) | def build_prompt(repository: str, issue: dict[str, Any]) -> str: function start_conversation (line 254) | def start_conversation( function extract_first_item (line 278) | def extract_first_item(payload: Any) -> dict[str, Any] | None: function summarize_openhands_item (line 292) | def summarize_openhands_item(item: dict[str, Any]) -> str: function poll_start_task (line 317) | def poll_start_task( function poll_conversation (line 344) | def poll_conversation( function validate_event_search_results (line 372) | def validate_event_search_results(events: list[dict[str, Any]]) -> list[... function fetch_app_server_events (line 378) | def fetch_app_server_events(app_conversation_id: str) -> list[dict[str, ... function fetch_agent_server_events (line 392) | def fetch_agent_server_events( function fetch_agent_server_final_response (line 408) | def fetch_agent_server_final_response( function extract_agent_server_url (line 421) | def extract_agent_server_url(conversation_url: str) -> str | None: function extract_last_agent_text (line 428) | def extract_last_agent_text(events: list[dict[str, Any]]) -> str: function parse_agent_json (line 457) | def parse_agent_json(text: str) -> dict[str, Any]: function as_bool (line 478) | def as_bool(value: Any) -> bool: function normalize_result (line 488) | def normalize_result(result: dict[str, Any]) -> dict[str, Any]: function main (line 557) | def main() -> int: FILE: scripts/render_examples_report.py class ExampleResult (line 15) | class ExampleResult: function parse_args (line 23) | def parse_args() -> argparse.Namespace: function iter_result_files (line 60) | def iter_result_files(results_dir: Path) -> Iterable[Path]: function load_results (line 64) | def load_results(results_dir: Path) -> list[ExampleResult]: function _coerce_float (line 83) | def _coerce_float(value: object) -> float | None: function _coerce_cost (line 99) | def _coerce_cost(value: object) -> str | None: function _sanitize_reason (line 107) | def _sanitize_reason(value: object) -> str | None: function format_duration (line 114) | def format_duration(seconds: float | None) -> str: function format_cost (line 127) | def format_cost(value: str | None) -> str: function format_total_cost (line 138) | def format_total_cost(values: Iterable[str | None]) -> str | None: function markdown_header (line 156) | def markdown_header(model: str, timestamp: str) -> list[str]: function markdown_table (line 161) | def markdown_table(results: list[ExampleResult]) -> list[str]: function markdown_summary (line 188) | def markdown_summary(results: list[ExampleResult], workflow_url: str) ->... function _escape_cell (line 222) | def _escape_cell(text: str) -> str: function build_report (line 226) | def build_report(args: argparse.Namespace, results: list[ExampleResult])... function main (line 233) | def main() -> int: FILE: tests/agent_server/stress/budgets.py class ParallelSubagentBudget (line 11) | class ParallelSubagentBudget: class ConversationListingBudget (line 24) | class ConversationListingBudget: class ConcurrentConversationsBudget (line 52) | class ConcurrentConversationsBudget: class LongRunningCommandBudget (line 63) | class LongRunningCommandBudget: class EventLoopResponsivenessBudget (line 74) | class EventLoopResponsivenessBudget: class SlowWebhookBudget (line 83) | class SlowWebhookBudget: class SlowWebsocketConsumerBudget (line 93) | class SlowWebsocketConsumerBudget: class WebsocketReconnectStormBudget (line 106) | class WebsocketReconnectStormBudget: class HighVolumeBashOutputBudget (line 115) | class HighVolumeBashOutputBudget: class LeaseContentionBudget (line 131) | class LeaseContentionBudget: FILE: tests/agent_server/stress/conftest.py function conversation_service (line 38) | async def conversation_service(tmp_path: Path) -> AsyncIterator[Conversa... function bash_service (line 53) | async def bash_service( function app (line 72) | def app( function client (line 100) | async def client(app: FastAPI) -> AsyncIterator[httpx.AsyncClient]: function probe (line 109) | async def probe() -> AsyncIterator[ResourceProbe]: FILE: tests/agent_server/stress/probe.py class Sample (line 19) | class Sample: class ResourceProbe (line 28) | class ResourceProbe: method __aenter__ (line 36) | async def __aenter__(self) -> Self: method __aexit__ (line 45) | async def __aexit__(self, *_: object) -> None: method _loop (line 56) | async def _loop(self) -> None: method _take (line 62) | def _take(self) -> Sample: method baseline (line 80) | def baseline(self) -> Sample: method samples (line 85) | def samples(self) -> list[Sample]: method peak_rss_mb (line 88) | def peak_rss_mb(self) -> float: method peak_fds (line 91) | def peak_fds(self) -> int: method peak_threads (line 97) | def peak_threads(self) -> int: method rss_delta_mb (line 100) | def rss_delta_mb(self) -> float: method fd_delta (line 103) | def fd_delta(self) -> int: FILE: tests/agent_server/stress/scripts.py class SlowTestLLM (line 31) | class SlowTestLLM(TestLLM): method __init__ (line 42) | def __init__(self, *, latency_s: float = 0.0, **data: Any) -> None: method completion (line 46) | def completion( function placeholder_llm (line 67) | def placeholder_llm(usage_id: str) -> LLM: function text_message (line 80) | def text_message(text: str) -> Message: function descendants_of (line 84) | def descendants_of(pid: int) -> list[psutil.Process]: function start_conversation_with_test_llm (line 93) | async def start_conversation_with_test_llm( function wait_for_terminal (line 157) | async def wait_for_terminal( FILE: tests/agent_server/stress/test_concurrent_conversations.py function _build_simple_llm (line 36) | def _build_simple_llm(latency_s: float) -> SlowTestLLM: function _start_one (line 52) | async def _start_one( function _run_and_wait (line 70) | async def _run_and_wait( function test_concurrent_conversations_isolated_and_fast (line 80) | async def test_concurrent_conversations_isolated_and_fast( FILE: tests/agent_server/stress/test_conversation_listing.py function _seed_conversations (line 36) | async def _seed_conversations( function _walk_pages (line 71) | async def _walk_pages( function _find_last_page_id (line 107) | async def _find_last_page_id(client, *, page_size: int, sort_order: str)... function _time_first_page (line 127) | async def _time_first_page(client, *, page_size: int) -> float: function _time_deep_page (line 137) | async def _time_deep_page(client, *, page_size: int, page_id: str) -> fl... function test_pagination_is_correct_and_bounded (line 151) | async def test_pagination_is_correct_and_bounded( FILE: tests/agent_server/stress/test_event_loop_responsiveness.py function _measure_health_p95_p99 (line 39) | async def _measure_health_p95_p99(client, *, samples: int) -> tuple[floa... function _assert_within_budget (line 51) | def _assert_within_budget(name: str, p95: float, p99: float) -> None: function test_health_responsive_under_long_bash (line 63) | async def test_health_responsive_under_long_bash( function test_health_responsive_under_busy_listing (line 135) | async def test_health_responsive_under_busy_listing( FILE: tests/agent_server/stress/test_high_volume_bash_output.py function test_high_volume_bash_output_is_bounded (line 31) | async def test_high_volume_bash_output_is_bounded( FILE: tests/agent_server/stress/test_lease_contention.py function _try_start (line 35) | async def _try_start( function test_concurrent_start_of_same_conversation_yields_one_winner (line 56) | async def test_concurrent_start_of_same_conversation_yields_one_winner( FILE: tests/agent_server/stress/test_long_running_command.py function test_long_running_bash_does_not_block_event_loop (line 40) | async def test_long_running_bash_does_not_block_event_loop( function test_bash_timeout_kills_process_cleanly (line 144) | async def test_bash_timeout_kills_process_cleanly( FILE: tests/agent_server/stress/test_parallel_subagents.py function _reset_registry (line 47) | def _reset_registry(): function _task_tool_call (line 54) | def _task_tool_call(call_id: str, subagent_type: str, prompt: str) -> Me... function _register_subagents (line 63) | def _register_subagents(n: int, latency_s: float) -> list[SlowTestLLM]: function _build_parent_llm (line 84) | def _build_parent_llm(n: int, latency_s: float) -> SlowTestLLM: function _run_once (line 107) | async def _run_once( function test_parallel_subagents_all_complete (line 136) | async def test_parallel_subagents_all_complete( FILE: tests/agent_server/stress/test_slow_webhook.py class _SlowReceiver (line 59) | class _SlowReceiver(http.server.BaseHTTPRequestHandler): method do_POST (line 68) | def do_POST(self) -> None: # noqa: N802 — stdlib API method log_message (line 78) | def log_message(self, format: str, *args: object) -> None: # noqa: A002 function slow_webhook_url (line 84) | def slow_webhook_url() -> Iterator[str]: function conversation_service (line 105) | async def conversation_service( function app (line 125) | def app( function baseline_service (line 140) | async def baseline_service(tmp_path: Path) -> AsyncIterator[Conversation... function _run_conversation_and_time (line 150) | async def _run_conversation_and_time( function test_slow_webhook_does_not_unbound_growth (line 173) | async def test_slow_webhook_does_not_unbound_growth( class _AlwaysFailReceiver (line 259) | class _AlwaysFailReceiver(http.server.BaseHTTPRequestHandler): method do_POST (line 260) | def do_POST(self) -> None: # noqa: N802 method log_message (line 268) | def log_message(self, format: str, *args: object) -> None: # noqa: A002 function always_fail_webhook_url (line 273) | def always_fail_webhook_url(): function failing_webhook_service (line 286) | async def failing_webhook_service(tmp_path: Path, always_fail_webhook_ur... function test_webhook_queue_bounded_under_sustained_downstream_failure (line 306) | async def test_webhook_queue_bounded_under_sustained_downstream_failure( FILE: tests/agent_server/stress/test_slow_websocket_consumer.py class _RecordingSubscriber (line 51) | class _RecordingSubscriber(Subscriber[Event]): method __call__ (line 56) | async def __call__(self, event: Event) -> None: class _StalledSubscriber (line 61) | class _StalledSubscriber(Subscriber[Event]): method __call__ (line 71) | async def __call__(self, event: Event) -> None: function _get_event_service (line 76) | async def _get_event_service( function test_stalled_subscriber_does_not_grow_unbounded (line 99) | async def test_stalled_subscriber_does_not_grow_unbounded( FILE: tests/agent_server/stress/test_websocket_reconnect_storm.py class _NoopSubscriber (line 36) | class _NoopSubscriber(Subscriber[Event]): method __call__ (line 37) | async def __call__(self, event: Event) -> None: function _idle_event_service (line 41) | async def _idle_event_service( function test_reconnect_storm_subscriber_accounting_balanced (line 58) | async def test_reconnect_storm_subscriber_accounting_balanced( FILE: tests/agent_server/test_agent_server_wsproto.py function find_free_port (line 18) | def find_free_port(): function run_agent_server (line 25) | def run_agent_server(port, api_key): function agent_server (line 39) | def agent_server(): function test_agent_server_starts_with_wsproto (line 69) | def test_agent_server_starts_with_wsproto(agent_server): function test_agent_server_websocket_with_wsproto (line 78) | async def test_agent_server_websocket_with_wsproto(agent_server): function test_agent_server_websocket_with_wsproto_header_auth (line 119) | async def test_agent_server_websocket_with_wsproto_header_auth(agent_ser... function test_agent_server_websocket_first_message_auth_accepted (line 163) | async def test_agent_server_websocket_first_message_auth_accepted(agent_... function test_agent_server_websocket_first_message_auth_rejected (line 215) | async def test_agent_server_websocket_first_message_auth_rejected(agent_... function test_agent_server_websocket_first_message_auth_malformed (line 238) | async def test_agent_server_websocket_first_message_auth_malformed(agent... FILE: tests/agent_server/test_api.py function clear_web_url_env (line 23) | def clear_web_url_env(monkeypatch): function test_default_server_tmux_tmpdir_uses_current_pid (line 29) | def test_default_server_tmux_tmpdir_uses_current_pid(tmp_path, monkeypat... function test_ensure_server_tmux_tmpdir_defaults_per_process_dir (line 39) | def test_ensure_server_tmux_tmpdir_defaults_per_process_dir(tmp_path, mo... function test_ensure_server_tmux_tmpdir_respects_existing_env (line 52) | def test_ensure_server_tmux_tmpdir_respects_existing_env(tmp_path, monke... class TestStaticFilesServing (line 63) | class TestStaticFilesServing: method test_static_files_not_mounted_when_path_none (line 66) | def test_static_files_not_mounted_when_path_none(self): method test_static_files_not_mounted_when_directory_missing (line 76) | def test_static_files_not_mounted_when_directory_missing(self): method test_static_files_mounted_when_directory_exists (line 86) | def test_static_files_mounted_when_directory_exists(self): method test_static_files_serve_html (line 105) | def test_static_files_serve_html(self): method test_static_files_serve_subdirectory (line 125) | def test_static_files_serve_subdirectory(self): method test_static_files_404_for_missing_file (line 147) | def test_static_files_404_for_missing_file(self): method test_static_files_security_no_directory_traversal (line 160) | def test_static_files_security_no_directory_traversal(self): class TestRootRedirect (line 183) | class TestRootRedirect: method test_root_redirect_to_index_html_when_exists (line 186) | def test_root_redirect_to_index_html_when_exists(self): method test_root_redirect_to_static_dir_when_no_index (line 204) | def test_root_redirect_to_static_dir_when_no_index(self): method test_root_redirect_follows_to_index_html (line 222) | def test_root_redirect_follows_to_index_html(self): method test_no_root_redirect_when_static_files_not_configured (line 242) | def test_no_root_redirect_when_static_files_not_configured(self): method test_no_root_redirect_when_static_directory_missing (line 252) | def test_no_root_redirect_when_static_directory_missing(self): class TestServiceParallelization (line 263) | class TestServiceParallelization: method test_services_start_in_parallel (line 266) | async def test_services_start_in_parallel(self): method test_services_stop_in_parallel (line 328) | async def test_services_stop_in_parallel(self): method test_services_handle_none_values (line 379) | async def test_services_handle_none_values(self): method test_lifespan_defaults_and_restores_tmux_tmpdir (line 406) | async def test_lifespan_defaults_and_restores_tmux_tmpdir( class TestRootPath (line 436) | class TestRootPath: method test_get_root_path_returns_slash_when_web_url_is_none (line 439) | def test_get_root_path_returns_slash_when_web_url_is_none(self): method test_get_root_path_extracts_path_from_url (line 444) | def test_get_root_path_extracts_path_from_url(self): method test_get_root_path_returns_slash_for_root_url (line 449) | def test_get_root_path_returns_slash_for_root_url(self): method test_get_root_path_with_trailing_slash (line 454) | def test_get_root_path_with_trailing_slash(self): method test_get_root_path_with_complex_path (line 459) | def test_get_root_path_with_complex_path(self): method test_fastapi_instance_uses_root_path (line 466) | def test_fastapi_instance_uses_root_path(self): method test_fastapi_instance_uses_default_root_path_when_no_web_url (line 472) | def test_fastapi_instance_uses_default_root_path_when_no_web_url(self): class TestConfigWebUrl (line 479) | class TestConfigWebUrl: method test_web_url_default_is_none_when_env_not_set (line 482) | def test_web_url_default_is_none_when_env_not_set(self): method test_web_url_reads_from_oh_web_url_env (line 488) | def test_web_url_reads_from_oh_web_url_env(self): method test_web_url_ignores_legacy_runtime_url_env (line 494) | def test_web_url_ignores_legacy_runtime_url_env(self): method test_web_url_reads_oh_web_url_when_runtime_url_is_also_set (line 501) | def test_web_url_reads_oh_web_url_when_runtime_url_is_also_set(self): method test_web_url_can_be_set_explicitly (line 514) | def test_web_url_can_be_set_explicitly(self): function test_get_root_path_parametrized (line 539) | def test_get_root_path_parametrized(web_url, expected_root_path): class TestHttpExceptionLogging (line 545) | class TestHttpExceptionLogging: method _build_app_with_failing_route (line 555) | def _build_app_with_failing_route(self, status_code: int): method test_5xx_http_exception_logged_without_traceback_by_default (line 569) | def test_5xx_http_exception_logged_without_traceback_by_default(self, ... method test_5xx_http_exception_includes_traceback_when_debug_enabled (line 606) | def test_5xx_http_exception_includes_traceback_when_debug_enabled( method test_4xx_http_exception_logged_at_info_without_traceback (line 631) | def test_4xx_http_exception_logged_at_info_without_traceback(self, cap... FILE: tests/agent_server/test_api_authentication.py function client (line 15) | def client(): function client_with_auth (line 21) | def client_with_auth(): function client_with_multiple_keys (line 29) | def client_with_multiple_keys(): function test_find_http_exception (line 36) | def test_find_http_exception(): function test_api_no_auth_required (line 66) | def test_api_no_auth_required(client): function test_api_auth_missing_key (line 74) | def test_api_auth_missing_key(client_with_auth): function test_api_auth_invalid_key (line 80) | def test_api_auth_invalid_key(client_with_auth): function test_api_auth_valid_key (line 88) | def test_api_auth_valid_key(client_with_auth): function test_api_auth_multiple_keys_all_valid (line 97) | def test_api_auth_multiple_keys_all_valid(client_with_multiple_keys): function test_api_auth_multiple_keys_invalid (line 106) | def test_api_auth_multiple_keys_invalid(client_with_multiple_keys): function test_api_server_details_no_auth_required (line 114) | def test_api_server_details_no_auth_required(client_with_auth): function test_api_protected_endpoints_require_auth (line 121) | def test_api_protected_endpoints_require_auth(client_with_auth): function test_api_case_sensitive_keys (line 143) | def test_api_case_sensitive_keys(client_with_auth): function test_api_header_case_insensitive (line 163) | def test_api_header_case_insensitive(): function test_api_special_character_keys (line 181) | def test_api_special_character_keys(): function test_api_empty_key_list (line 199) | def test_api_empty_key_list(): function test_api_websocket_authentication (line 210) | def test_api_websocket_authentication(): function test_api_websocket_no_auth_required (line 257) | def test_api_websocket_no_auth_required(): function test_api_options_requests (line 267) | def test_api_options_requests(): function test_api_dependency_injection_openapi (line 279) | def test_api_dependency_injection_openapi(): function test_api_multiple_concurrent_requests (line 298) | def test_api_multiple_concurrent_requests(): function test_api_error_response_format (line 319) | def test_api_error_response_format(): FILE: tests/agent_server/test_bash_service.py function bash_service (line 24) | async def bash_service( function client (line 35) | async def client(bash_service: BashEventService) -> AsyncIterator[httpx.... function test_bash_timeout_runs_sigterm_trap (line 48) | async def test_bash_timeout_runs_sigterm_trap( FILE: tests/agent_server/test_check_browser.py class TestCheckBrowser (line 6) | class TestCheckBrowser: method test_check_browser_success (line 9) | def test_check_browser_success(self, capsys): method test_check_browser_failure_is_error (line 41) | def test_check_browser_failure_is_error(self, capsys): method test_check_browser_failure_exception (line 68) | def test_check_browser_failure_exception(self, capsys): method test_check_browser_cleanup_on_executor_creation_failure (line 91) | def test_check_browser_cleanup_on_executor_creation_failure(self, caps... method test_check_browser_str_conversion_for_content (line 110) | def test_check_browser_str_conversion_for_content(self, capsys): FILE: tests/agent_server/test_cloud_proxy_router.py function _build_app (line 18) | def _build_app() -> FastAPI: function _make_test_client (line 24) | def _make_test_client(app: FastAPI) -> AsyncClient: class TestHostAllowlist (line 28) | class TestHostAllowlist: method test_allows_canonical_cloud_host (line 29) | def test_allows_canonical_cloud_host(self): method test_allows_subdomain_of_allowed_root (line 32) | def test_allows_subdomain_of_allowed_root(self): method test_rejects_loopback (line 35) | def test_rejects_loopback(self): method test_rejects_private_ipv4_addresses (line 39) | def test_rejects_private_ipv4_addresses(self): method test_rejects_link_local_addresses (line 44) | def test_rejects_link_local_addresses(self): method test_rejects_private_ipv6_addresses (line 48) | def test_rejects_private_ipv6_addresses(self): method test_rejects_private_ip_even_when_allowlisted (line 53) | def test_rejects_private_ip_even_when_allowlisted(self, monkeypatch): method test_rejects_unrelated_host (line 59) | def test_rejects_unrelated_host(self): method test_rejects_non_http_scheme (line 62) | def test_rejects_non_http_scheme(self): method test_env_var_overrides_default_allowlist (line 66) | def test_env_var_overrides_default_allowlist(self, monkeypatch): function test_proxy_forwards_get_and_returns_upstream_json (line 75) | async def test_proxy_forwards_get_and_returns_upstream_json(monkeypatch): function test_proxy_propagates_upstream_error_status (line 124) | async def test_proxy_propagates_upstream_error_status(monkeypatch): function test_proxy_rejects_disallowed_host (line 156) | async def test_proxy_rejects_disallowed_host(): function test_proxy_returns_502_on_upstream_network_error (line 173) | async def test_proxy_returns_502_on_upstream_network_error(monkeypatch): function test_proxy_strips_upstream_set_cookie_and_cors_headers (line 198) | async def test_proxy_strips_upstream_set_cookie_and_cors_headers(monkeyp... FILE: tests/agent_server/test_conversation_lease.py function _read_lease_payload (line 20) | def _read_lease_payload(conversation_dir: Path) -> LeasePayload: function _expire_lease (line 27) | def _expire_lease(conversation_dir: Path) -> None: function test_claim_and_renew_persist_same_owner_generation (line 34) | def test_claim_and_renew_persist_same_owner_generation(tmp_path: Path) -... function test_claim_rejects_different_owner_while_lease_is_live (line 63) | def test_claim_rejects_different_owner_while_lease_is_live(tmp_path: Pat... function test_takeover_bumps_generation_and_blocks_stale_owner_writes (line 83) | def test_takeover_bumps_generation_and_blocks_stale_owner_writes( function test_release_keeps_new_owner_lease_intact_after_takeover (line 118) | def test_release_keeps_new_owner_lease_intact_after_takeover(tmp_path: P... function test_claim_writes_owner_host_and_pid (line 140) | def test_claim_writes_owner_host_and_pid(tmp_path: Path) -> None: function test_claim_takes_over_when_previous_owner_pid_is_dead (line 154) | def test_claim_takes_over_when_previous_owner_pid_is_dead( function test_claim_blocks_takeover_when_owner_is_on_a_different_host (line 195) | def test_claim_blocks_takeover_when_owner_is_on_a_different_host( function test_claim_falls_back_to_ttl_for_legacy_lease_files (line 226) | def test_claim_falls_back_to_ttl_for_legacy_lease_files( function test_owner_pid_check_treats_unknown_errors_as_alive (line 251) | def test_owner_pid_check_treats_unknown_errors_as_alive( function test_claim_self_pid_match_is_not_treated_as_dead (line 285) | def test_claim_self_pid_match_is_not_treated_as_dead(tmp_path: Path) -> ... FILE: tests/agent_server/test_conversation_response.py function client (line 22) | def client(): function sample_conversation_id (line 29) | def sample_conversation_id(): function mock_conversation_service (line 34) | def mock_conversation_service(): function mock_event_service (line 39) | def mock_event_service(): function test_get_response_with_finish_action (line 43) | def test_get_response_with_finish_action( function test_get_response_empty_when_no_agent_events (line 72) | def test_get_response_empty_when_no_agent_events( function test_get_response_conversation_not_found (line 95) | def test_get_response_conversation_not_found( function test_event_service_get_agent_final_response_with_finish (line 114) | def test_event_service_get_agent_final_response_with_finish(): function test_event_service_get_agent_final_response_with_message (line 142) | def test_event_service_get_agent_final_response_with_message(): function test_event_service_get_agent_final_response_empty (line 164) | def test_event_service_get_agent_final_response_empty(): function test_event_service_get_agent_final_response_inactive (line 178) | def test_event_service_get_agent_final_response_inactive(): FILE: tests/agent_server/test_conversation_router.py function client (line 35) | def client(): function sample_conversation_id (line 48) | def sample_conversation_id(): function sample_conversation_info (line 54) | def sample_conversation_info(): function mock_conversation_service (line 77) | def mock_conversation_service(): function mock_event_service (line 84) | def mock_event_service(): function llm_security_analyzer (line 91) | def llm_security_analyzer(): function sample_start_conversation_request (line 97) | def sample_start_conversation_request(): function test_search_conversations_default_params (line 115) | def test_search_conversations_default_params( function test_search_conversations_with_all_params (line 147) | def test_search_conversations_with_all_params( function test_search_conversations_limit_validation (line 190) | def test_search_conversations_limit_validation(client, mock_conversation... function test_search_conversations_empty_result (line 217) | def test_search_conversations_empty_result(client, mock_conversation_ser... function test_count_conversations_no_filter (line 239) | def test_count_conversations_no_filter(client, mock_conversation_service): function test_count_conversations_with_status_filter (line 261) | def test_count_conversations_with_status_filter(client, mock_conversatio... function test_count_conversations_zero_result (line 288) | def test_count_conversations_zero_result(client, mock_conversation_servi... function test_get_conversation_success (line 307) | def test_get_conversation_success( function test_get_conversation_not_found (line 335) | def test_get_conversation_not_found( function test_get_conversation_invalid_uuid (line 360) | def test_get_conversation_invalid_uuid(client, mock_conversation_service): function test_batch_get_conversations_success (line 375) | def test_batch_get_conversations_success( function test_batch_get_conversations_empty_list (line 414) | def test_batch_get_conversations_empty_list(client, mock_conversation_se... function test_batch_get_conversations_too_many_ids (line 442) | def test_batch_get_conversations_too_many_ids(client, mock_conversation_... function test_batch_get_conversations_invalid_uuid (line 464) | def test_batch_get_conversations_invalid_uuid(client, mock_conversation_... function test_start_conversation_new (line 479) | def test_start_conversation_new( function test_start_conversation_existing (line 526) | def test_start_conversation_existing( function test_start_conversation_accepts_openhands_agent_settings (line 568) | def test_start_conversation_accepts_openhands_agent_settings( function test_start_conversation_agent_settings_uses_sdk_default_tools (line 613) | def test_start_conversation_agent_settings_uses_sdk_default_tools( function test_start_conversation_accepts_acp_agent (line 671) | def test_start_conversation_accepts_acp_agent(client, mock_conversation_... function test_start_conversation_accepts_acp_agent_settings (line 706) | def test_start_conversation_accepts_acp_agent_settings( function test_start_conversation_rejects_invalid_agent_settings (line 764) | def test_start_conversation_rejects_invalid_agent_settings( function test_start_conversation_agent_takes_precedence_over_agent_settings (line 786) | def test_start_conversation_agent_takes_precedence_over_agent_settings( function test_start_conversation_rejects_acp_agent_without_kind (line 823) | def test_start_conversation_rejects_acp_agent_without_kind( function test_start_conversation_invalid_request (line 845) | def test_start_conversation_invalid_request(client, mock_conversation_se... function test_start_conversation_minimal_request (line 863) | def test_start_conversation_minimal_request( function test_start_conversation_legacy_request_without_agent_kind (line 902) | def test_start_conversation_legacy_request_without_agent_kind( function test_pause_conversation_success (line 937) | def test_pause_conversation_success( function test_pause_conversation_failure (line 964) | def test_pause_conversation_failure( function test_delete_conversation_success (line 989) | def test_delete_conversation_success( function test_delete_conversation_failure (line 1016) | def test_delete_conversation_failure( function test_run_conversation_success (line 1041) | def test_run_conversation_success( function test_run_conversation_not_found (line 1070) | def test_run_conversation_not_found( function test_run_conversation_already_running (line 1095) | def test_run_conversation_already_running( function test_run_conversation_other_error (line 1124) | def test_run_conversation_other_error( function test_update_conversation_secrets_success (line 1147) | def test_update_conversation_secrets_success( function test_update_conversation_secrets_not_found (line 1186) | def test_update_conversation_secrets_not_found( function test_set_conversation_confirmation_policy_success (line 1217) | def test_set_conversation_confirmation_policy_success( function test_set_conversation_confirmation_policy_not_found (line 1251) | def test_set_conversation_confirmation_policy_not_found( function test_update_conversation_success (line 1281) | def test_update_conversation_success( function test_update_conversation_failure (line 1313) | def test_update_conversation_failure( function test_update_conversation_invalid_title (line 1342) | def test_update_conversation_invalid_title( function test_generate_title_endpoint_removed_from_openapi (line 1370) | def test_generate_title_endpoint_removed_from_openapi(client): function test_start_conversation_with_tool_module_qualnames (line 1381) | def test_start_conversation_with_tool_module_qualnames( function test_start_conversation_without_tool_module_qualnames (line 1442) | def test_start_conversation_without_tool_module_qualnames( function test_start_conversation_autotitle_defaults_to_true (line 1489) | def test_start_conversation_autotitle_defaults_to_true( function test_start_conversation_autotitle_false (line 1524) | def test_start_conversation_autotitle_false( function test_set_conversation_security_analyzer_success (line 1560) | def test_set_conversation_security_analyzer_success( function test_set_conversation_security_analyzer_with_none (line 1594) | def test_set_conversation_security_analyzer_with_none( function test_security_analyzer_endpoint_with_malformed_analyzer_data (line 1624) | def test_security_analyzer_endpoint_with_malformed_analyzer_data( function test_update_secrets_with_string_values (line 1649) | def test_update_secrets_with_string_values( function test_update_secrets_with_mixed_formats (line 1691) | def test_update_secrets_with_mixed_formats( function test_switch_conversation_profile_success (line 1744) | def test_switch_conversation_profile_success( function test_switch_conversation_profile_not_found (line 1774) | def test_switch_conversation_profile_not_found( function test_switch_conversation_profile_nonexistent_profile (line 1798) | def test_switch_conversation_profile_nonexistent_profile( function test_switch_conversation_profile_corrupted_profile (line 1826) | def test_switch_conversation_profile_corrupted_profile( function test_switch_conversation_llm_success (line 1852) | def test_switch_conversation_llm_success( function test_switch_conversation_llm_decrypts_encrypted_api_key (line 1888) | def test_switch_conversation_llm_decrypts_encrypted_api_key( function test_switch_conversation_llm_plaintext_with_cipher_passes_through (line 1941) | def test_switch_conversation_llm_plaintext_with_cipher_passes_through( function test_switch_conversation_llm_not_found (line 1986) | def test_switch_conversation_llm_not_found( function test_fork_conversation_success (line 2013) | def test_fork_conversation_success( function test_fork_conversation_not_found (line 2037) | def test_fork_conversation_not_found( function test_fork_conversation_duplicate_id_returns_409 (line 2058) | def test_fork_conversation_duplicate_id_returns_409( FILE: tests/agent_server/test_conversation_router_acp.py function client (line 33) | def client(): function mock_conversation_service (line 40) | def mock_conversation_service(): function sample_acp_conversation_info (line 45) | def sample_acp_conversation_info(): function test_start_acp_conversation_accepts_acp_agent (line 58) | def test_start_acp_conversation_accepts_acp_agent( function test_get_acp_conversation_returns_acp_agent (line 88) | def test_get_acp_conversation_returns_acp_agent( function test_search_acp_conversations_returns_acp_page (line 109) | def test_search_acp_conversations_returns_acp_page( function test_count_acp_conversations_returns_count (line 131) | def test_count_acp_conversations_returns_count(client, mock_conversation... function test_batch_get_acp_conversations_returns_acp_agents (line 147) | def test_batch_get_acp_conversations_returns_acp_agents( FILE: tests/agent_server/test_conversation_service.py function mock_event_service (line 56) | def mock_event_service(): function sample_stored_conversation (line 63) | def sample_stored_conversation(): function _create_running_terminal_action (line 77) | def _create_running_terminal_action(tool_call_id: str = "call_1") -> Act... function _expire_conversation_lease (line 100) | def _expire_conversation_lease(conversations_dir: Path, conversation_id)... function _init_git_repo (line 107) | def _init_git_repo(repo_dir: Path) -> None: function conversation_service (line 128) | def conversation_service(): function test_second_service_does_not_resume_active_running_conversation (line 140) | async def test_second_service_does_not_resume_active_running_conversatio... function test_stale_owner_cannot_append_after_lease_takeover (line 192) | async def test_stale_owner_cannot_append_after_lease_takeover(tmp_path): function test_event_services_use_centralized_lease_renewal (line 245) | async def test_event_services_use_centralized_lease_renewal(tmp_path): function test_centralized_lease_renewal_invokes_renew (line 276) | async def test_centralized_lease_renewal_invokes_renew(tmp_path): function test_event_services_share_dedicated_run_executor (line 322) | async def test_event_services_share_dedicated_run_executor(tmp_path): function test_restart_resumes_conversations_after_non_graceful_shutdown (line 357) | async def test_restart_resumes_conversations_after_non_graceful_shutdown... class TestConversationServiceSearchConversations (line 400) | class TestConversationServiceSearchConversations: method test_search_conversations_inactive_service (line 404) | async def test_search_conversations_inactive_service(self, conversatio... method test_search_conversations_empty_result (line 412) | async def test_search_conversations_empty_result(self, conversation_se... method test_search_conversations_basic (line 421) | async def test_search_conversations_basic( method test_search_conversations_with_critic_redacts_api_key (line 448) | async def test_search_conversations_with_critic_redacts_api_key( method test_search_conversations_status_filter (line 497) | async def test_search_conversations_status_filter(self, conversation_s... method test_search_conversations_sorting (line 554) | async def test_search_conversations_sorting(self, conversation_service): method test_search_conversations_pagination (line 632) | async def test_search_conversations_pagination(self, conversation_serv... method test_search_conversations_combined_filter_and_sort (line 682) | async def test_search_conversations_combined_filter_and_sort( method test_search_conversations_invalid_page_id (line 742) | async def test_search_conversations_invalid_page_id( class TestConversationServiceCountConversations (line 772) | class TestConversationServiceCountConversations: method test_count_conversations_inactive_service (line 776) | async def test_count_conversations_inactive_service(self, conversation... method test_count_conversations_empty_result (line 784) | async def test_count_conversations_empty_result(self, conversation_ser... method test_count_conversations_basic (line 790) | async def test_count_conversations_basic( method test_count_conversations_status_filter (line 813) | async def test_count_conversations_status_filter(self, conversation_se... method test_count_conversations_includes_regular_and_acp (line 871) | async def test_count_conversations_includes_regular_and_acp( class TestConversationServiceStartConversation (line 910) | class TestConversationServiceStartConversation: method test_start_conversation_with_secrets (line 914) | async def test_start_conversation_with_secrets(self, conversation_serv... method test_start_conversation_without_secrets (line 985) | async def test_start_conversation_without_secrets(self, conversation_s... method test_start_conversation_with_worktree_uses_git_worktree (line 1037) | async def test_start_conversation_with_worktree_uses_git_worktree( method test_start_conversation_with_worktree_preserves_relative_workspace (line 1105) | async def test_start_conversation_with_worktree_preserves_relative_wor... method test_start_conversation_with_worktree_ignores_non_git_workspace (line 1161) | async def test_start_conversation_with_worktree_ignores_non_git_worksp... method test_get_worktree_start_point_prefers_origin_default_branch (line 1213) | def test_get_worktree_start_point_prefers_origin_default_branch(self, ... method test_get_worktree_start_point_falls_back_to_local_main (line 1274) | def test_get_worktree_start_point_falls_back_to_local_main(self, tmp_p... method test_get_worktree_start_point_falls_back_to_master (line 1284) | def test_get_worktree_start_point_falls_back_to_master(self, tmp_path): method test_get_worktree_start_point_tolerates_fetch_failure (line 1294) | def test_get_worktree_start_point_tolerates_fetch_failure(self, tmp_pa... method test_start_conversation_with_custom_id (line 1324) | async def test_start_conversation_with_custom_id(self, conversation_se... method test_start_conversation_with_duplicate_id (line 1342) | async def test_start_conversation_with_duplicate_id(self, conversation... method test_start_conversation_reuse_checks_is_open (line 1373) | async def test_start_conversation_reuse_checks_is_open(self, conversat... method test_start_conversation_reuse_when_open (line 1433) | async def test_start_conversation_reuse_when_open(self, conversation_s... method test_start_conversation_returns_existing_acp_conversation (line 1480) | async def test_start_conversation_returns_existing_acp_conversation( method test_start_event_service_failure_cleanup (line 1531) | async def test_start_event_service_failure_cleanup(self, conversation_... method test_start_event_service_success_stores_service (line 1565) | async def test_start_event_service_success_stores_service( class TestConversationServiceUpdateConversation (line 1604) | class TestConversationServiceUpdateConversation: method test_update_conversation_success (line 1608) | async def test_update_conversation_success( method test_update_conversation_strips_whitespace (line 1640) | async def test_update_conversation_strips_whitespace( method test_update_conversation_tags_uses_state_lock (line 1671) | async def test_update_conversation_tags_uses_state_lock( method test_update_conversation_tags_wait_does_not_block_event_loop (line 1705) | async def test_update_conversation_tags_wait_does_not_block_event_loop( method test_update_conversation_not_found (line 1771) | async def test_update_conversation_not_found(self, conversation_service): method test_update_conversation_inactive_service (line 1782) | async def test_update_conversation_inactive_service(self, conversation... method test_update_conversation_notifies_webhooks (line 1791) | async def test_update_conversation_notifies_webhooks( method test_update_acp_conversation_notifies_webhooks_with_acp_shape (line 1830) | async def test_update_acp_conversation_notifies_webhooks_with_acp_shape( method test_update_conversation_persists_changes (line 1871) | async def test_update_conversation_persists_changes( method test_update_conversation_multiple_times (line 1903) | async def test_update_conversation_multiple_times( method test_update_conversation_sets_updated_at (line 1949) | async def test_update_conversation_sets_updated_at( class TestConversationServiceDeleteConversation (line 1980) | class TestConversationServiceDeleteConversation: method test_delete_conversation_inactive_service (line 1984) | async def test_delete_conversation_inactive_service(self, conversation... method test_delete_conversation_not_found (line 1992) | async def test_delete_conversation_not_found(self, conversation_service): method test_delete_conversation_success (line 1998) | async def test_delete_conversation_success(self, conversation_service): method test_delete_conversation_notifies_webhooks_with_deleting_status (line 2049) | async def test_delete_conversation_notifies_webhooks_with_deleting_sta... method test_delete_conversation_webhook_failure (line 2108) | async def test_delete_conversation_webhook_failure(self, conversation_... method test_delete_conversation_close_failure (line 2151) | async def test_delete_conversation_close_failure(self, conversation_se... method test_delete_conversation_directory_removal_failure (line 2199) | async def test_delete_conversation_directory_removal_failure( class TestSafeRmtree (line 2249) | class TestSafeRmtree: method test_safe_rmtree_nonexistent_path (line 2252) | def test_safe_rmtree_nonexistent_path(self): method test_safe_rmtree_empty_path (line 2257) | def test_safe_rmtree_empty_path(self): method test_safe_rmtree_success (line 2265) | def test_safe_rmtree_success(self): method test_safe_rmtree_permission_error (line 2279) | def test_safe_rmtree_permission_error(self): method test_safe_rmtree_os_error (line 2288) | def test_safe_rmtree_os_error(self): method test_safe_rmtree_unexpected_error (line 2297) | def test_safe_rmtree_unexpected_error(self): method test_safe_rmtree_readonly_file_handling (line 2306) | def test_safe_rmtree_readonly_file_handling(self): class TestAutoTitle (line 2322) | class TestAutoTitle: method _make_service (line 2329) | def _make_service( method _user_message_event (line 2354) | def _user_message_event(self, text: str = "Fix the login bug") -> Mess... method _drain_title_task (line 2364) | async def _drain_title_task( method test_autotitle_sets_title_on_first_user_message (line 2380) | async def test_autotitle_sets_title_on_first_user_message(self): method test_autotitle_skips_non_user_events (line 2393) | async def test_autotitle_skips_non_user_events(self): method test_autotitle_skips_when_title_already_set (line 2416) | async def test_autotitle_skips_when_title_already_set(self): method test_autotitle_handles_generate_title_failure (line 2429) | async def test_autotitle_handles_generate_title_failure(self): method test_autotitle_skips_empty_message (line 2444) | async def test_autotitle_skips_empty_message(self): method test_autotitle_uses_llm_profile_when_configured (line 2460) | async def test_autotitle_uses_llm_profile_when_configured(self): method test_autotitle_falls_back_to_agent_llm_when_profile_not_found (line 2490) | async def test_autotitle_falls_back_to_agent_llm_when_profile_not_foun... method test_autotitle_no_profile_uses_agent_llm (line 2518) | async def test_autotitle_no_profile_uses_agent_llm(self): method test_autotitle_handles_profile_load_value_error (line 2538) | async def test_autotitle_handles_profile_load_value_error(self): method test_autotitle_falls_back_for_acp_managed_llm (line 2563) | async def test_autotitle_falls_back_for_acp_managed_llm(self): method test_autotitle_integration_routes_through_profile_store (line 2575) | async def test_autotitle_integration_routes_through_profile_store(self... method test_autotitle_decrypts_cipher_encrypted_title_profile (line 2663) | async def test_autotitle_decrypts_cipher_encrypted_title_profile(self,... class TestACPActivityHeartbeatWiring (line 2746) | class TestACPActivityHeartbeatWiring: method test_acp_agent_gets_on_activity_wired (line 2749) | def test_acp_agent_gets_on_activity_wired(self): method test_non_acp_agent_unchanged (line 2765) | def test_non_acp_agent_unchanged(self): FILE: tests/agent_server/test_conversation_service_plugin.py function create_test_plugin_dir (line 38) | def create_test_plugin_dir( function conversation_service (line 91) | def conversation_service(): function test_start_conversation_request_has_plugins_field (line 101) | def test_start_conversation_request_has_plugins_field(): function test_start_conversation_without_plugin (line 113) | async def test_start_conversation_without_plugin(conversation_service): function test_start_conversation_with_plugins_list (line 156) | async def test_start_conversation_with_plugins_list(conversation_service... function test_start_conversation_with_multiple_plugins (line 219) | async def test_start_conversation_with_multiple_plugins(conversation_ser... function test_plugins_persisted_in_stored_conversation_for_lazy_loading (line 278) | async def test_plugins_persisted_in_stored_conversation_for_lazy_loading( function test_start_conversation_request_has_hook_config_field (line 332) | def test_start_conversation_request_has_hook_config_field(): function test_start_conversation_with_explicit_hook_config (line 339) | async def test_start_conversation_with_explicit_hook_config(conversation... function test_start_conversation_stores_both_hooks_and_plugins_for_lazy_merge (line 393) | async def test_start_conversation_stores_both_hooks_and_plugins_for_lazy... FILE: tests/agent_server/test_conversation_tags.py function client (line 29) | def client(): function mock_conversation_service (line 36) | def mock_conversation_service(): function mock_event_service (line 41) | def mock_event_service(): function sample_conversation_info (line 46) | def sample_conversation_info(): function test_start_conversation_with_tags (line 67) | def test_start_conversation_with_tags( function test_start_conversation_without_tags (line 102) | def test_start_conversation_without_tags( function test_start_conversation_invalid_tag_key (line 136) | def test_start_conversation_invalid_tag_key(client, mock_conversation_se... function test_update_conversation_tags (line 161) | def test_update_conversation_tags(client, mock_conversation_service): function test_update_conversation_title_and_tags (line 186) | def test_update_conversation_title_and_tags(client, mock_conversation_se... function test_get_conversation_includes_tags (line 209) | def test_get_conversation_includes_tags( function test_event_service_start_forwards_tags_to_local_conversation (line 229) | async def test_event_service_start_forwards_tags_to_local_conversation(t... FILE: tests/agent_server/test_dependencies.py function test_create_session_api_key_dependency (line 16) | def test_create_session_api_key_dependency(): function test_create_session_api_key_dependency_no_keys (line 35) | def test_create_session_api_key_dependency_no_keys(): function test_create_session_api_key_dependency_in_fastapi (line 45) | def test_create_session_api_key_dependency_in_fastapi(): FILE: tests/agent_server/test_desktop_router.py class TestDesktopRouter (line 11) | class TestDesktopRouter: method test_get_desktop_url_service_disabled (line 15) | async def test_get_desktop_url_service_disabled(self): method test_get_desktop_url_success (line 28) | async def test_get_desktop_url_success(self): method test_get_desktop_url_default_base_url (line 49) | async def test_get_desktop_url_default_base_url(self): method test_get_desktop_url_service_exception (line 70) | async def test_get_desktop_url_service_exception(self): method test_get_desktop_url_none_response (line 86) | async def test_get_desktop_url_none_response(self): class TestDesktopUrlResponse (line 101) | class TestDesktopUrlResponse: method test_desktop_url_response_with_url (line 104) | def test_desktop_url_response_with_url(self): method test_desktop_url_response_with_none (line 109) | def test_desktop_url_response_with_none(self): method test_desktop_url_response_serialization (line 114) | def test_desktop_url_response_serialization(self): method test_desktop_url_response_none_serialization (line 120) | def test_desktop_url_response_none_serialization(self): FILE: tests/agent_server/test_desktop_service.py class TestDesktopService (line 11) | class TestDesktopService: method test_desktop_service_initialization (line 14) | def test_desktop_service_initialization(self): method test_desktop_service_custom_port (line 20) | def test_desktop_service_custom_port(self): method test_start_desktop_already_running (line 27) | async def test_start_desktop_already_running(self): method test_start_desktop_directory_creation_failure (line 36) | async def test_start_desktop_directory_creation_failure(self): method test_start_desktop_xstartup_creation_failure (line 48) | async def test_start_desktop_xstartup_creation_failure(self): method test_start_desktop_vncserver_failure (line 62) | async def test_start_desktop_vncserver_failure(self): method test_start_desktop_novnc_proxy_not_found (line 79) | async def test_start_desktop_novnc_proxy_not_found(self): method test_start_desktop_success_with_existing_novnc (line 115) | async def test_start_desktop_success_with_existing_novnc(self): method test_start_desktop_success_with_new_novnc (line 147) | async def test_start_desktop_success_with_new_novnc(self): method test_start_desktop_novnc_creation_failure (line 185) | async def test_start_desktop_novnc_creation_failure(self): method test_stop_desktop_no_process (line 219) | async def test_stop_desktop_no_process(self): method test_stop_desktop_graceful (line 227) | async def test_stop_desktop_graceful(self): method test_stop_desktop_timeout (line 241) | async def test_stop_desktop_timeout(self): method test_stop_desktop_exception (line 270) | async def test_stop_desktop_exception(self): method test_is_running_with_process (line 282) | def test_is_running_with_process(self): method test_is_running_with_dead_process (line 291) | def test_is_running_with_dead_process(self): method test_is_running_no_process_vnc_running (line 304) | def test_is_running_no_process_vnc_running(self): method test_is_running_no_process_vnc_not_running (line 315) | def test_is_running_no_process_vnc_not_running(self): method test_is_running_subprocess_exception (line 326) | def test_is_running_subprocess_exception(self): method test_get_vnc_url_running (line 334) | def test_get_vnc_url_running(self): method test_get_vnc_url_not_running (line 342) | def test_get_vnc_url_not_running(self): method test_get_vnc_url_default_base (line 350) | def test_get_vnc_url_default_base(self): class TestGetDesktopService (line 359) | class TestGetDesktopService: method setup_method (line 362) | def setup_method(self): method test_get_desktop_service_vnc_enabled (line 368) | def test_get_desktop_service_vnc_enabled(self): method test_get_desktop_service_vnc_disabled (line 381) | def test_get_desktop_service_vnc_disabled(self): method test_get_desktop_service_singleton (line 393) | def test_get_desktop_service_singleton(self): method test_get_desktop_service_reset_global (line 406) | def test_get_desktop_service_reset_global(self): FILE: tests/agent_server/test_docker_build.py function _create_fake_sdist (line 39) | def _create_fake_sdist(tmp_path: Path) -> Path: function test_git_info_priority_sdk_sha (line 51) | def test_git_info_priority_sdk_sha(): function test_git_info_priority_github_sha (line 75) | def test_git_info_priority_github_sha(): function test_git_info_priority_sdk_ref (line 103) | def test_git_info_priority_sdk_ref(): function test_git_info_priority_github_ref (line 121) | def test_git_info_priority_github_ref(): function test_git_info_submodule_scenario (line 144) | def test_git_info_submodule_scenario(): function test_git_info_empty_sdk_sha_falls_back (line 167) | def test_git_info_empty_sdk_sha_falls_back(): function test_base_slug_short_image (line 188) | def test_base_slug_short_image(): function test_base_slug_no_tag (line 201) | def test_base_slug_no_tag(): function test_truncate_ident_cases (line 212) | def test_truncate_ident_cases(): function test_base_slug_truncation_with_tag (line 222) | def test_base_slug_truncation_with_tag(): function test_base_slug_truncation_no_tag (line 245) | def test_base_slug_truncation_no_tag(): function test_base_slug_preserves_latest_tag_suffix (line 268) | def test_base_slug_preserves_latest_tag_suffix(): function test_base_slug_preserves_tag_with_registry_port (line 283) | def test_base_slug_preserves_tag_with_registry_port(): function test_base_slug_custom_max_len (line 298) | def test_base_slug_custom_max_len(): function test_base_slug_digest_consistency (line 315) | def test_base_slug_digest_consistency(): function test_base_slug_edge_case_exact_max_len (line 336) | def test_base_slug_edge_case_exact_max_len(): function test_release_tag_aliases_expand_semver_parts (line 347) | def test_release_tag_aliases_expand_semver_parts(): function test_release_tag_aliases_sanitize_non_semver_tags (line 354) | def test_release_tag_aliases_sanitize_non_semver_tags(): function test_versioned_tags_use_sdk_version_for_semver_git_tags (line 360) | def test_versioned_tags_use_sdk_version_for_semver_git_tags(): function test_versioned_tags_semver_git_tag_strips_v_when_sdk_version_unknown (line 375) | def test_versioned_tags_semver_git_tag_strips_v_when_sdk_version_unknown(): function test_versioned_tags_fallback_to_sdk_version_aliases (line 389) | def test_versioned_tags_fallback_to_sdk_version_aliases(): function test_versioned_tags_non_semver_git_tag_preserved (line 412) | def test_versioned_tags_non_semver_git_tag_preserved(): function test_versioned_tags_no_custom_tags (line 426) | def test_versioned_tags_no_custom_tags(): function test_all_tags_include_short_long_sha_and_branch (line 439) | def test_all_tags_include_short_long_sha_and_branch(): function test_all_tags_includes_versioned_tags (line 457) | def test_all_tags_includes_versioned_tags(): function test_all_tags_excludes_versioned_tags_when_disabled (line 482) | def test_all_tags_excludes_versioned_tags_when_disabled(): function test_all_tags_with_arch_suffix (line 503) | def test_all_tags_with_arch_suffix(): function test_all_tags_with_target_suffix (line 526) | def test_all_tags_with_target_suffix(): function test_make_build_context_reuses_prebuilt_sdist_without_running_uv_build (line 548) | def test_make_build_context_reuses_prebuilt_sdist_without_running_uv_build( function test_build_with_prebuilt_sdist_preserves_tags_and_docker_args (line 575) | def test_build_with_prebuilt_sdist_preserves_tags_and_docker_args(tmp_pa... function test_build_can_reuse_same_prebuilt_sdist_multiple_times (line 636) | def test_build_can_reuse_same_prebuilt_sdist_multiple_times(tmp_path: Pa... function test_parse_buildkit_telemetry_extracts_phase_timings (line 702) | def test_parse_buildkit_telemetry_extracts_phase_timings(): function test_parse_buildkit_telemetry_cache_export_with_preparing_line (line 716) | def test_parse_buildkit_telemetry_cache_export_with_preparing_line(): function test_build_with_telemetry_returns_parsed_buildkit_fields (line 753) | def test_build_with_telemetry_returns_parsed_buildkit_fields(tmp_path: P... function test_build_with_telemetry_preserves_telemetry_on_failure (line 807) | def test_build_with_telemetry_preserves_telemetry_on_failure(tmp_path: P... function test_cache_export_modes (line 870) | def test_cache_export_modes( FILE: tests/agent_server/test_env_parser.py class NodeModel (line 48) | class NodeModel(BaseModel): class OptionalSubModel (line 56) | class OptionalSubModel(BaseModel): class OptionalModel (line 61) | class OptionalModel(BaseModel): function clean_env (line 66) | def clean_env(): function test_bool_env_parser (line 75) | def test_bool_env_parser(clean_env): function test_int_env_parser (line 95) | def test_int_env_parser(clean_env): function test_float_env_parser (line 118) | def test_float_env_parser(clean_env): function test_str_env_parser (line 145) | def test_str_env_parser(clean_env): function test_none_env_parser (line 163) | def test_none_env_parser(clean_env): function test_dict_env_parser (line 175) | def test_dict_env_parser(clean_env): function test_list_env_parser_with_json (line 203) | def test_list_env_parser_with_json(clean_env): function test_list_env_parser_sequential (line 227) | def test_list_env_parser_sequential(clean_env): function test_list_env_parser_with_complex_items (line 245) | def test_list_env_parser_with_complex_items(clean_env): function test_union_env_parser (line 258) | def test_union_env_parser(clean_env): function test_model_env_parser_simple (line 284) | def test_model_env_parser_simple(clean_env): function test_delayed_parser (line 315) | def test_delayed_parser(clean_env): function test_merge_function (line 329) | def test_merge_function(): function test_get_env_parser_basic_types (line 373) | def test_get_env_parser_basic_types(): function test_get_env_parser_complex_types (line 391) | def test_get_env_parser_complex_types(): function test_get_env_parser_model_type (line 416) | def test_get_env_parser_model_type(): function test_config_class_parsing (line 438) | def test_config_class_parsing(clean_env): function test_config_webhook_specs_parsing (line 455) | def test_config_webhook_specs_parsing(clean_env): function test_config_webhook_specs_sequential_parsing (line 495) | def test_config_webhook_specs_sequential_parsing(clean_env): function test_config_mixed_webhook_parsing (line 520) | def test_config_mixed_webhook_parsing(clean_env): function test_node_model_parsing (line 545) | def test_node_model_parsing(clean_env): function test_node_model_parsing_with_recursion (line 556) | def test_node_model_parsing_with_recursion(clean_env): function test_node_model_with_json (line 574) | def test_node_model_with_json(clean_env): function test_node_model_mixed_parsing (line 587) | def test_node_model_mixed_parsing(clean_env): function test_from_env_with_defaults (line 604) | def test_from_env_with_defaults(clean_env): function test_from_env_with_custom_parsers (line 619) | def test_from_env_with_custom_parsers(clean_env): function test_error_handling_invalid_json (line 637) | def test_error_handling_invalid_json(clean_env): function test_error_handling_unknown_type (line 649) | def test_error_handling_unknown_type(): function test_optional_fields_parsing (line 660) | def test_optional_fields_parsing(clean_env): function test_complex_nested_structure (line 682) | def test_complex_nested_structure(clean_env): function test_optional_parameter_parsing (line 725) | def test_optional_parameter_parsing(clean_env): function test_discriminated_union_parsing (line 732) | def test_discriminated_union_parsing(clean_env): function test_config_vnc_environment_variable_parsing (line 740) | def test_config_vnc_environment_variable_parsing(clean_env): function test_config_vnc_various_boolean_values (line 772) | def test_config_vnc_various_boolean_values(clean_env, env_value, expected): class SampleEnum (line 786) | class SampleEnum(str, Enum): function test_enum_env_parser_creation (line 794) | def test_enum_env_parser_creation(): function test_enum_parsing_valid_values (line 803) | def test_enum_parsing_valid_values(clean_env): function test_enum_parsing_invalid_values (line 819) | def test_enum_parsing_invalid_values(clean_env): function test_enum_parsing_missing_values (line 833) | def test_enum_parsing_missing_values(clean_env): function test_literal_env_parser_creation (line 851) | def test_literal_env_parser_creation(): function test_literal_parsing_valid_values (line 861) | def test_literal_parsing_valid_values(clean_env): function test_literal_parsing_invalid_values (line 876) | def test_literal_parsing_invalid_values(clean_env): function test_literal_parsing_missing_values (line 890) | def test_literal_parsing_missing_values(clean_env): function test_literal_env_parser_direct (line 903) | def test_literal_env_parser_direct(): function test_bool_env_parser_to_env (line 930) | def test_bool_env_parser_to_env(): function test_none_env_parser_to_env (line 945) | def test_none_env_parser_to_env(): function test_literal_env_parser_to_env (line 960) | def test_literal_env_parser_to_env(): function test_list_env_parser_to_env (line 973) | def test_list_env_parser_to_env(): function test_model_env_parser_to_env (line 989) | def test_model_env_parser_to_env(): function test_union_env_parser_to_env (line 1011) | def test_union_env_parser_to_env(): function test_to_env_function_with_enum (line 1025) | def test_to_env_function_with_enum(): function test_to_env_function_with_literal (line 1042) | def test_to_env_function_with_literal(): function test_to_env_function_with_complex_model (line 1059) | def test_to_env_function_with_complex_model(): function test_to_env_function_with_none_values (line 1107) | def test_to_env_function_with_none_values(): function test_to_env_function_with_boolean_values (line 1127) | def test_to_env_function_with_boolean_values(): function test_discriminated_union_single_kind_uses_parser_directly (line 1149) | def test_discriminated_union_single_kind_uses_parser_directly(clean_env): function test_discriminated_union_multiple_kinds_requires_kind (line 1168) | def test_discriminated_union_multiple_kinds_requires_kind(clean_env): function test_discriminated_union_multiple_kinds_with_kind_set (line 1191) | def test_discriminated_union_multiple_kinds_with_kind_set(clean_env): function test_discriminated_union_zero_kinds_returns_missing (line 1214) | def test_discriminated_union_zero_kinds_returns_missing(clean_env): function test_discriminated_union_full_class_name_imports_and_registers (line 1225) | def test_discriminated_union_full_class_name_imports_and_registers(clean... function test_discriminated_union_full_class_name_already_registered (line 1243) | def test_discriminated_union_full_class_name_already_registered(clean_env): function test_discriminated_union_full_class_name_different_classes (line 1263) | def test_discriminated_union_full_class_name_different_classes(clean_env): function test_discriminated_union_full_class_name_invalid_module (line 1290) | def test_discriminated_union_full_class_name_invalid_module(clean_env): function test_discriminated_union_full_class_name_invalid_class (line 1301) | def test_discriminated_union_full_class_name_invalid_class(clean_env): function test_discriminated_union_kind_only_no_other_variables (line 1314) | def test_discriminated_union_kind_only_no_other_variables(clean_env): function test_discriminated_union_kind_only_multiple_kinds (line 1329) | def test_discriminated_union_kind_only_multiple_kinds(clean_env): function test_discriminated_union_no_kind_no_variables_returns_missing (line 1350) | def test_discriminated_union_no_kind_no_variables_returns_missing(clean_... function test_discriminated_union_single_empty_kind_no_variables (line 1369) | def test_discriminated_union_single_empty_kind_no_variables(clean_env): FILE: tests/agent_server/test_event_router.py function test_normalize_datetime_naive_passthrough (line 25) | def test_normalize_datetime_naive_passthrough(): function test_normalize_datetime_utc_converted_to_naive (line 34) | def test_normalize_datetime_utc_converted_to_naive(): function test_normalize_datetime_preserves_microseconds (line 44) | def test_normalize_datetime_preserves_microseconds(): function test_normalize_datetime_fixed_offset_timezone (line 52) | def test_normalize_datetime_fixed_offset_timezone(): function client (line 65) | def client(): function sample_conversation_id (line 73) | def sample_conversation_id(): function mock_event_service (line 79) | def mock_event_service(): class TestSendMessageEndpoint (line 86) | class TestSendMessageEndpoint: method test_send_message_with_run_true (line 90) | async def test_send_message_with_run_true( method test_send_message_with_run_false (line 127) | async def test_send_message_with_run_false( method test_send_message_default_run_value (line 161) | async def test_send_message_default_run_value( method test_send_message_conversation_not_found (line 195) | async def test_send_message_conversation_not_found( method test_send_message_with_different_content_types (line 227) | async def test_send_message_with_different_content_types( method test_send_message_with_system_role (line 270) | async def test_send_message_with_system_role( method test_send_message_invalid_request_data (line 304) | async def test_send_message_invalid_request_data( method test_create_message (line 343) | def test_create_message(self): class TestSearchEventsEndpoint (line 357) | class TestSearchEventsEndpoint: method test_search_events_with_naive_datetime (line 361) | async def test_search_events_with_naive_datetime( method test_search_events_with_timezone_aware_datetime (line 397) | async def test_search_events_with_timezone_aware_datetime( method test_search_events_with_timezone_range (line 433) | async def test_search_events_with_timezone_range( method test_count_events_with_timezone_aware_datetime (line 471) | async def test_count_events_with_timezone_aware_datetime( method test_count_events_with_source_filter (line 504) | async def test_count_events_with_source_filter( method test_search_events_timezone_normalization_consistency (line 537) | async def test_search_events_timezone_normalization_consistency( method test_search_events_with_source_filter (line 593) | async def test_search_events_with_source_filter( method test_search_events_with_multiple_filters (line 628) | async def test_search_events_with_multiple_filters( method test_search_events_with_source_filter_real_events (line 670) | async def test_search_events_with_source_filter_real_events( method test_search_events_with_body_filter_real_events (line 739) | async def test_search_events_with_body_filter_real_events( FILE: tests/agent_server/test_event_router_websocket.py function mock_websocket (line 21) | def mock_websocket(): function mock_event_service (line 33) | def mock_event_service(): function sample_conversation_id (line 44) | def sample_conversation_id(): function test_websocket_subscriber_call_success (line 50) | async def test_websocket_subscriber_call_success(mock_websocket): function test_websocket_subscriber_call_exception (line 67) | async def test_websocket_subscriber_call_exception(mock_websocket): function test_websocket_subscriber_skips_send_when_disconnected (line 84) | async def test_websocket_subscriber_skips_send_when_disconnected(mock_we... function test_websocket_subscriber_send_runtime_error_not_logged_as_exception (line 107) | async def test_websocket_subscriber_send_runtime_error_not_logged_as_exc... function test_websocket_disconnect_breaks_loop (line 133) | async def test_websocket_disconnect_breaks_loop( function test_websocket_no_double_unsubscription (line 158) | async def test_websocket_no_double_unsubscription( function test_websocket_general_exception_continues_loop (line 186) | async def test_websocket_general_exception_continues_loop( function test_websocket_successful_message_processing (line 225) | async def test_websocket_successful_message_processing( function test_disconnect_and_unsubscribe_when_send_error_fails (line 262) | async def test_disconnect_and_unsubscribe_when_send_error_fails( function test_resend_mode_none_no_resend (line 293) | async def test_resend_mode_none_no_resend( function test_resend_mode_all_resends_events (line 321) | async def test_resend_mode_all_resends_events( function test_resend_mode_since_with_timestamp (line 367) | async def test_resend_mode_since_with_timestamp( function test_resend_mode_since_without_timestamp_logs_warning (line 410) | async def test_resend_mode_since_without_timestamp_logs_warning( function test_resend_mode_since_timezone_aware_is_normalized (line 444) | async def test_resend_mode_since_timezone_aware_is_normalized( function test_deprecated_resend_all_true_still_works (line 497) | async def test_deprecated_resend_all_true_still_works( function test_deprecated_resend_all_false_no_resend (line 542) | async def test_deprecated_resend_all_false_no_resend( function test_resend_mode_takes_precedence_over_resend_all (line 570) | async def test_resend_mode_takes_precedence_over_resend_all( FILE: tests/agent_server/test_event_service.py function sample_stored_conversation (line 51) | def sample_stored_conversation(): function event_service (line 66) | def event_service(sample_stored_conversation): function mock_conversation_with_events (line 76) | def mock_conversation_with_events(): function mock_conversation_with_timestamped_events (line 98) | def mock_conversation_with_timestamped_events(): class TestEventServiceSearchEvents (line 131) | class TestEventServiceSearchEvents: method test_search_events_inactive_service (line 135) | async def test_search_events_inactive_service(self, event_service): method test_search_events_empty_result (line 143) | async def test_search_events_empty_result(self, event_service): method test_search_events_basic (line 162) | async def test_search_events_basic( method test_search_events_kind_filter (line 176) | async def test_search_events_kind_filter( method test_search_events_sorting (line 199) | async def test_search_events_sorting( method test_search_events_pagination (line 220) | async def test_search_events_pagination( method test_search_events_combined_filter_and_sort (line 242) | async def test_search_events_combined_filter_and_sort( method test_search_events_pagination_with_filter (line 261) | async def test_search_events_pagination_with_filter( method test_search_events_invalid_page_id (line 286) | async def test_search_events_invalid_page_id( method test_search_events_large_limit (line 301) | async def test_search_events_large_limit( method test_search_events_zero_limit (line 313) | async def test_search_events_zero_limit( method test_search_events_does_not_scan_whole_log (line 326) | async def test_search_events_does_not_scan_whole_log(self, event_servi... method test_search_events_exact_pagination_boundary (line 404) | async def test_search_events_exact_pagination_boundary(self, event_ser... method test_search_events_timestamp_gte_filter (line 431) | async def test_search_events_timestamp_gte_filter( method test_search_events_timestamp_lt_filter (line 451) | async def test_search_events_timestamp_lt_filter( method test_search_events_timestamp_range_filter (line 471) | async def test_search_events_timestamp_range_filter( method test_search_events_timestamp_filter_with_timezone_aware (line 495) | async def test_search_events_timestamp_filter_with_timezone_aware( method test_search_events_timestamp_filter_no_matches (line 517) | async def test_search_events_timestamp_filter_no_matches( method test_search_events_timestamp_filter_all_events (line 531) | async def test_search_events_timestamp_filter_all_events( class TestEventServiceCountEvents (line 546) | class TestEventServiceCountEvents: method test_count_events_inactive_service (line 550) | async def test_count_events_inactive_service(self, event_service): method test_count_events_empty_result (line 558) | async def test_count_events_empty_result(self, event_service): method test_count_events_basic (line 573) | async def test_count_events_basic( method test_count_events_kind_filter (line 583) | async def test_count_events_kind_filter( method test_count_events_timestamp_gte_filter (line 604) | async def test_count_events_timestamp_gte_filter( method test_count_events_timestamp_lt_filter (line 616) | async def test_count_events_timestamp_lt_filter( method test_count_events_timestamp_range_filter (line 628) | async def test_count_events_timestamp_range_filter( method test_count_events_timestamp_filter_with_timezone_aware (line 643) | async def test_count_events_timestamp_filter_with_timezone_aware( method test_count_events_timestamp_filter_no_matches (line 660) | async def test_count_events_timestamp_filter_no_matches( method test_count_events_timestamp_filter_all_events (line 672) | async def test_count_events_timestamp_filter_all_events( class TestEventServiceSendMessage (line 684) | class TestEventServiceSendMessage: method _mock_executor (line 687) | async def _mock_executor(self, *args): method test_send_message_inactive_service (line 692) | async def test_send_message_inactive_service(self, event_service): method test_send_message_with_run_false_default (line 701) | async def test_send_message_with_run_false_default(self, event_service): method test_send_message_with_run_false (line 737) | async def test_send_message_with_run_false(self, event_service): method test_send_message_with_run_true_agent_already_running (line 764) | async def test_send_message_with_run_true_agent_already_running( method test_send_message_with_run_true_agent_idle (line 799) | async def test_send_message_with_run_true_agent_idle(self, event_servi... method test_send_message_with_run_true_logs_exception (line 830) | async def test_send_message_with_run_true_logs_exception(self, event_s... method test_send_message_with_different_message_types (line 869) | async def test_send_message_with_different_message_types(self, event_s... class TestEventServiceRespondToConfirmation (line 907) | class TestEventServiceRespondToConfirmation: method test_respond_to_confirmation_accept_calls_run (line 911) | async def test_respond_to_confirmation_accept_calls_run(self, event_se... method test_respond_to_confirmation_rejects_actions (line 925) | async def test_respond_to_confirmation_rejects_actions(self, event_ser... method test_reject_pending_actions_inactive_service (line 940) | async def test_reject_pending_actions_inactive_service(self, event_ser... method test_reject_pending_actions_invokes_conversation (line 948) | async def test_reject_pending_actions_invokes_conversation(self, event... class TestEventServiceIsOpen (line 969) | class TestEventServiceIsOpen: method test_is_open_when_conversation_is_none (line 972) | def test_is_open_when_conversation_is_none(self, event_service): method test_is_open_when_conversation_exists (line 977) | def test_is_open_when_conversation_exists(self, event_service): method test_is_open_when_conversation_is_falsy (line 983) | def test_is_open_when_conversation_is_falsy(self, event_service): method test_is_open_when_conversation_is_truthy (line 992) | def test_is_open_when_conversation_is_truthy(self, event_service): class TestEventServiceBodyFiltering (line 1009) | class TestEventServiceBodyFiltering: method test_event_matches_body_with_message_event (line 1012) | def test_event_matches_body_with_message_event(self, event_service): method test_event_matches_body_with_non_message_event (line 1030) | def test_event_matches_body_with_non_message_event(self, event_service): method test_event_matches_body_with_empty_content (line 1041) | def test_event_matches_body_with_empty_content(self, event_service): method test_search_events_with_body_filter_integration (line 1053) | async def test_search_events_with_body_filter_integration(self, event_... method test_count_events_with_body_filter_integration (line 1112) | async def test_count_events_with_body_filter_integration(self, event_s... class TestEventServiceRun (line 1164) | class TestEventServiceRun: method test_run_inactive_service (line 1168) | async def test_run_inactive_service(self, event_service): method test_run_already_running_by_status (line 1176) | async def test_run_already_running_by_status(self, event_service): method test_run_already_running_by_task (line 1191) | async def test_run_already_running_by_task(self, event_service): method test_run_starts_background_task (line 1211) | async def test_run_starts_background_task(self, event_service): method test_run_publishes_state_update_on_completion (line 1240) | async def test_run_publishes_state_update_on_completion(self, event_se... method test_run_publishes_state_update_on_error (line 1260) | async def test_run_publishes_state_update_on_error(self, event_service): class TestEventServiceSaveMeta (line 1285) | class TestEventServiceSaveMeta: method test_save_meta_preserves_updated_at (line 1289) | async def test_save_meta_preserves_updated_at(self, event_service, tmp... class TestEventServiceStartWithRunningStatus (line 1313) | class TestEventServiceStartWithRunningStatus: method test_start_sets_error_status_when_running_from_disk (line 1317) | async def test_start_sets_error_status_when_running_from_disk( method test_start_does_not_add_error_event_when_no_unmatched_actions (line 1400) | async def test_start_does_not_add_error_event_when_no_unmatched_actions( method test_start_does_nothing_when_status_not_running (line 1454) | async def test_start_does_nothing_when_status_not_running( method test_start_skips_error_event_when_observation_already_exists (line 1504) | async def test_start_skips_error_event_when_observation_already_exists( method test_start_initializes_workspace_as_git_repo (line 1574) | async def test_start_initializes_workspace_as_git_repo( method test_start_is_idempotent_for_already_initialized_repo (line 1613) | async def test_start_is_idempotent_for_already_initialized_repo( class TestEventServiceConcurrentSubscriptions (line 1661) | class TestEventServiceConcurrentSubscriptions: method mock_conversation_with_real_lock (line 1670) | def mock_conversation_with_real_lock(self): method test_concurrent_subscriptions_no_deadlock (line 1695) | async def test_concurrent_subscriptions_no_deadlock( method test_slow_subscriber_does_not_block_lock (line 1735) | async def test_slow_subscriber_does_not_block_lock( method test_subscription_snapshot_wait_does_not_block_event_loop (line 1771) | async def test_subscription_snapshot_wait_does_not_block_event_loop( method test_subscription_during_state_update (line 1826) | async def test_subscription_during_state_update( method test_multiple_state_updates_with_slow_subscribers (line 1867) | async def test_multiple_state_updates_with_slow_subscribers( class TestSearchEventsBlockedByRunLoop (line 1904) | class TestSearchEventsBlockedByRunLoop: method test_search_events_not_blocked_by_state_lock (line 1916) | async def test_search_events_not_blocked_by_state_lock( class TestEventServiceClose (line 1986) | class TestEventServiceClose: method test_close_awaits_conversation_close (line 1990) | async def test_close_awaits_conversation_close(self, event_service): method test_close_clears_conversation_reference (line 2011) | async def test_close_clears_conversation_reference(self, event_service): method test_close_is_idempotent (line 2021) | async def test_close_is_idempotent(self, event_service): method test_close_pauses_before_closing_conversation (line 2032) | async def test_close_pauses_before_closing_conversation(self, event_se... method test_close_skips_pause_when_no_run_task (line 2063) | async def test_close_skips_pause_when_no_run_task(self, event_service): method test_close_proceeds_on_run_task_timeout (line 2077) | async def test_close_proceeds_on_run_task_timeout(self, event_service,... function real_conversation_service (line 2116) | async def real_conversation_service(tmp_path): class _WedgedSubscriber (line 2124) | class _WedgedSubscriber: method __init__ (line 2127) | def __init__(self) -> None: method __call__ (line 2130) | async def __call__(self, event): method close (line 2133) | async def close(self) -> None: function test_subscribe_to_events_does_not_deadlock_on_wedged_subscriber (line 2138) | async def test_subscribe_to_events_does_not_deadlock_on_wedged_subscriber( function test_close_blocks_until_executor_thread_finishes (line 2162) | async def test_close_blocks_until_executor_thread_finishes( FILE: tests/agent_server/test_event_streaming.py function _make_chunk (line 21) | def _make_chunk( class _CollectorSubscriber (line 35) | class _CollectorSubscriber(Subscriber): method __init__ (line 38) | def __init__(self): method __call__ (line 41) | async def __call__(self, event: Event): method close (line 44) | async def close(self): function event_service (line 49) | def event_service(tmp_path): function _mock_local_conversation (line 71) | def _mock_local_conversation(): function _start_and_capture_callback (line 76) | async def _start_and_capture_callback(event_service, tmp_path): function test_start_wires_token_callback (line 96) | async def test_start_wires_token_callback(event_service, tmp_path): function test_callback_publishes_delta (line 124) | async def test_callback_publishes_delta( function test_callback_ignores_delta_with_no_content_fields (line 142) | async def test_callback_ignores_delta_with_no_content_fields(event_servi... function test_callback_forwards_empty_string_delta (line 157) | async def test_callback_forwards_empty_string_delta(event_service, tmp_p... function test_callback_handles_none_choices (line 172) | async def test_callback_handles_none_choices(event_service, tmp_path): function test_token_callbacks_not_wired_when_stream_disabled (line 188) | async def test_token_callbacks_not_wired_when_stream_disabled(tmp_path): function test_multiple_chunks_produce_multiple_events (line 222) | async def test_multiple_chunks_produce_multiple_events(event_service, tm... FILE: tests/agent_server/test_file_router.py function client (line 23) | def client(): function temp_file (line 30) | def temp_file(tmp_path): function test_upload_file_query_param_success (line 42) | def test_upload_file_query_param_success(client, tmp_path): function test_upload_file_query_param_creates_parent_dirs (line 59) | def test_upload_file_query_param_creates_parent_dirs(client, tmp_path): function test_upload_file_query_param_relative_path_fails (line 75) | def test_upload_file_query_param_relative_path_fails(client): function test_upload_file_query_param_missing_path (line 87) | def test_upload_file_query_param_missing_path(client): function test_upload_file_query_param_missing_file (line 97) | def test_upload_file_query_param_missing_file(client, tmp_path): function test_download_file_query_param_success (line 114) | def test_download_file_query_param_success(client, temp_file): function test_download_file_query_param_not_found (line 126) | def test_download_file_query_param_not_found(client, tmp_path): function test_download_file_query_param_relative_path_fails (line 139) | def test_download_file_query_param_relative_path_fails(client): function test_download_file_query_param_directory_fails (line 150) | def test_download_file_query_param_directory_fails(client, tmp_path): function test_download_file_query_param_missing_path (line 161) | def test_download_file_query_param_missing_path(client): function test_upload_large_file_chunked (line 173) | def test_upload_large_file_chunked(client, tmp_path): function test_upload_overwrites_existing_file (line 192) | def test_upload_overwrites_existing_file(client, tmp_path): function test_download_preserves_filename (line 208) | def test_download_preserves_filename(client, tmp_path): function test_upload_file_with_special_characters_in_path (line 222) | def test_upload_file_with_special_characters_in_path(client, tmp_path): function test_download_trajectory_uses_python_zipfile (line 238) | def test_download_trajectory_uses_python_zipfile(client, monkeypatch, tm... function test_download_file_with_special_characters_in_path (line 276) | def test_download_file_with_special_characters_in_path(client, tmp_path): function test_file_legacy_routes_are_removed_from_openapi (line 290) | def test_file_legacy_routes_are_removed_from_openapi(client): function test_search_subdirs_returns_only_directories_with_absolute_paths (line 304) | def test_search_subdirs_returns_only_directories_with_absolute_paths(cli... function test_search_subdirs_relative_path_returns_400 (line 322) | def test_search_subdirs_relative_path_returns_400(client): function test_search_subdirs_missing_directory_returns_404 (line 328) | def test_search_subdirs_missing_directory_returns_404(client, tmp_path): function test_search_subdirs_path_is_a_file_returns_400 (line 336) | def test_search_subdirs_path_is_a_file_returns_400(client, tmp_path): function test_search_subdirs_paginates_with_limit_and_page_id (line 344) | def test_search_subdirs_paginates_with_limit_and_page_id(client, tmp_path): function test_search_subdirs_limit_too_low_returns_422 (line 385) | def test_search_subdirs_limit_too_low_returns_422(client, tmp_path): function test_get_home_returns_user_home (line 393) | def test_get_home_returns_user_home(client): function test_get_home_returns_dynamic_favorites_and_locations (line 399) | def test_get_home_returns_dynamic_favorites_and_locations( function test_upload_does_not_block_event_loop_on_slow_storage (line 426) | async def test_upload_does_not_block_event_loop_on_slow_storage(tmp_path... FILE: tests/agent_server/test_git_router.py function client (line 17) | def client(): function test_git_changes_query_param_success (line 29) | async def test_git_changes_query_param_success(client): function test_git_changes_query_param_empty_result (line 58) | async def test_git_changes_query_param_empty_result(client): function test_git_changes_query_param_with_exception (line 71) | async def test_git_changes_query_param_with_exception(client): function test_git_changes_query_param_with_command_error (line 82) | async def test_git_changes_query_param_with_command_error(client): function test_git_changes_returns_empty_list_when_path_is_not_git_repo (line 99) | async def test_git_changes_returns_empty_list_when_path_is_not_git_repo(... function test_git_diff_returns_empty_diff_when_path_is_not_git_repo (line 124) | async def test_git_diff_returns_empty_diff_when_path_is_not_git_repo(cli... function test_git_changes_query_param_ref_head_on_empty_repo_returns_200 (line 145) | async def test_git_changes_query_param_ref_head_on_empty_repo_returns_200( function test_git_changes_query_param_ref_head_on_orphan_branch_returns_200 (line 182) | async def test_git_changes_query_param_ref_head_on_orphan_branch_returns... function test_git_changes_missing_path_param (line 228) | async def test_git_changes_missing_path_param(client): function test_git_changes_query_param_absolute_path (line 236) | async def test_git_changes_query_param_absolute_path(client): function test_git_diff_query_param_success (line 255) | async def test_git_diff_query_param_success(client): function test_git_diff_query_param_with_none_values (line 277) | async def test_git_diff_query_param_with_none_values(client): function test_git_diff_query_param_with_command_error (line 295) | async def test_git_diff_query_param_with_command_error(client): function test_git_diff_missing_path_param (line 312) | async def test_git_diff_missing_path_param(client): function test_git_changes_with_all_status_types (line 325) | async def test_git_changes_with_all_status_types(client): function test_git_changes_with_complex_paths (line 351) | async def test_git_changes_with_complex_paths(client): function test_git_changes_forwards_ref_query_param (line 384) | async def test_git_changes_forwards_ref_query_param(client): function test_git_diff_forwards_ref_query_param (line 399) | async def test_git_diff_forwards_ref_query_param(client): function test_git_endpoints_expose_ref_query_param (line 414) | def test_git_endpoints_expose_ref_query_param(client): function test_git_legacy_routes_are_removed_from_openapi (line 428) | def test_git_legacy_routes_are_removed_from_openapi(client): FILE: tests/agent_server/test_hooks_router.py function client (line 15) | def client(): class TestHooksRouter (line 22) | class TestHooksRouter: method test_get_hooks_success (line 25) | def test_get_hooks_success(self, client): method test_get_hooks_file_not_found (line 57) | def test_get_hooks_file_not_found(self, client): method test_get_hooks_no_project_dir (line 69) | def test_get_hooks_no_project_dir(self, client): method test_get_hooks_empty_hooks (line 80) | def test_get_hooks_empty_hooks(self, client): method test_get_hooks_multiple_event_types (line 98) | def test_get_hooks_multiple_event_types(self, client): FILE: tests/agent_server/test_hooks_service.py class TestLoadHooksFromWorkspace (line 10) | class TestLoadHooksFromWorkspace: method test_load_hooks_success (line 13) | def test_load_hooks_success(self): method test_load_hooks_file_not_found (line 41) | def test_load_hooks_file_not_found(self): method test_load_hooks_no_project_dir (line 47) | def test_load_hooks_no_project_dir(self): method test_load_hooks_empty_hooks (line 52) | def test_load_hooks_empty_hooks(self): method test_load_hooks_invalid_json (line 64) | def test_load_hooks_invalid_json(self): method test_load_hooks_multiple_event_types (line 76) | def test_load_hooks_multiple_event_types(self): method test_load_hooks_pascal_case_format (line 111) | def test_load_hooks_pascal_case_format(self): FILE: tests/agent_server/test_llm_router.py function client (line 17) | def client(): function test_list_providers (line 25) | async def test_list_providers(): function test_list_models (line 35) | async def test_list_models(): function test_list_models_filtered_by_provider (line 43) | async def test_list_models_filtered_by_provider(): function test_list_models_unknown_provider (line 53) | async def test_list_models_unknown_provider(): function test_list_verified_models (line 60) | async def test_list_verified_models(): function test_providers_endpoint_integration (line 68) | def test_providers_endpoint_integration(client): function test_models_endpoint_integration (line 78) | def test_models_endpoint_integration(client): function test_models_endpoint_with_provider_filter (line 87) | def test_models_endpoint_with_provider_filter(client): function test_models_endpoint_with_unknown_provider (line 96) | def test_models_endpoint_with_unknown_provider(client): function test_verified_models_endpoint_integration (line 105) | def test_verified_models_endpoint_integration(client): FILE: tests/agent_server/test_models.py function test_update_secrets_request_string_conversion (line 12) | def test_update_secrets_request_string_conversion(): function test_update_secrets_request_proper_secret_source (line 32) | def test_update_secrets_request_proper_secret_source(): function test_update_secrets_request_mixed_formats (line 52) | def test_update_secrets_request_mixed_formats(): function test_update_secrets_request_dict_without_kind (line 72) | def test_update_secrets_request_dict_without_kind(): function test_update_secrets_request_invalid_dict (line 89) | def test_update_secrets_request_invalid_dict(): function test_update_secrets_request_empty_secrets (line 106) | def test_update_secrets_request_empty_secrets(): function test_update_secrets_request_invalid_input (line 113) | def test_update_secrets_request_invalid_input(): FILE: tests/agent_server/test_openapi_discriminator.py function client (line 21) | def client(): function test_action_schema_has_discriminator (line 26) | def test_action_schema_has_discriminator(client): function test_observation_schema_has_discriminator (line 69) | def test_observation_schema_has_discriminator(client): function test_event_schema_has_discriminator (line 96) | def test_event_schema_has_discriminator(client): function test_action_variants_have_proper_schemas (line 123) | def test_action_variants_have_proper_schemas(client): function test_conversation_contracts_use_unified_acp_capable_endpoint (line 175) | def test_conversation_contracts_use_unified_acp_capable_endpoint(client): function test_acp_conversation_response_names_are_type_aliases (line 214) | def test_acp_conversation_response_names_are_type_aliases(): FILE: tests/agent_server/test_preload_modules.py class TestPreloadModules (line 20) | class TestPreloadModules: method test_none_is_noop (line 21) | def test_none_is_noop(self): method test_empty_string_is_noop (line 28) | def test_empty_string_is_noop(self): method test_single_module (line 35) | def test_single_module(self): method test_comma_separated_strips_whitespace (line 42) | def test_comma_separated_strips_whitespace(self): method test_empty_segments_skipped (line 52) | def test_empty_segments_skipped(self): method test_missing_module_raises (line 62) | def test_missing_module_raises(self): method fake_tool_module (line 68) | def fake_tool_module(self, tmp_path, monkeypatch): method test_module_side_effects_execute (line 91) | def test_module_side_effects_execute(self, fake_tool_module): method test_module_not_imported_without_flag (line 99) | def test_module_not_imported_without_flag(self, fake_tool_module): method test_import_error_is_logged_before_raising (line 108) | def test_import_error_is_logged_before_raising(self, caplog): class TestExtendPythonPath (line 121) | class TestExtendPythonPath: method test_none_and_no_env_is_noop (line 125) | def test_none_and_no_env_is_noop(self, monkeypatch): method test_empty_string_and_no_env_is_noop (line 131) | def test_empty_string_and_no_env_is_noop(self, monkeypatch): method test_adds_directory_from_cli_arg (line 137) | def test_adds_directory_from_cli_arg(self, tmp_path, monkeypatch): method test_adds_directory_from_env_var (line 145) | def test_adds_directory_from_env_var(self, tmp_path, monkeypatch): method test_merges_cli_and_env (line 153) | def test_merges_cli_and_env(self, tmp_path, monkeypatch): method test_skips_nonexistent_dir_with_warning (line 165) | def test_skips_nonexistent_dir_with_warning(self, tmp_path, monkeypatc... method test_deduplicates (line 173) | def test_deduplicates(self, tmp_path, monkeypatch): method test_skips_already_on_sys_path (line 182) | def test_skips_already_on_sys_path(self, tmp_path, monkeypatch): method test_multiple_dirs_via_pathsep (line 193) | def test_multiple_dirs_via_pathsep(self, tmp_path, monkeypatch): method test_enables_import_of_external_module (line 205) | def test_enables_import_of_external_module(self, tmp_path, monkeypatch): method test_enables_preload_modules_integration (line 225) | def test_enables_preload_modules_integration(self, tmp_path, monkeypat... function test_get_internal_server_url_rewrites_wildcard_host (line 250) | def test_get_internal_server_url_rewrites_wildcard_host(host): function test_get_internal_server_url_preserves_explicit_host (line 254) | def test_get_internal_server_url_preserves_explicit_host(): function test_get_internal_server_url_brackets_ipv6_host (line 258) | def test_get_internal_server_url_brackets_ipv6_host(): class TestMainCheckBrowserOrdering (line 262) | class TestMainCheckBrowserOrdering: method test_check_browser_exits_before_preload (line 265) | def test_check_browser_exits_before_preload(self): method test_main_sets_internal_server_url (line 293) | def test_main_sets_internal_server_url(self, monkeypatch): FILE: tests/agent_server/test_profiles_router.py function temp_profiles_dir (line 20) | def temp_profiles_dir(): function temp_settings_dir (line 29) | def temp_settings_dir(): function client (line 38) | def client(temp_profiles_dir, temp_settings_dir, monkeypatch): function store (line 62) | def store(temp_profiles_dir): function test_list_profiles_empty (line 70) | def test_list_profiles_empty(client): function test_list_profiles_returns_saved_profiles (line 79) | def test_list_profiles_returns_saved_profiles(client, store): function test_get_profile_returns_config (line 110) | def test_get_profile_returns_config(client, store): function test_get_profile_not_found (line 126) | def test_get_profile_not_found(client): function test_get_profile_invalid_name (line 134) | def test_get_profile_invalid_name(client): function test_save_profile_creates_new (line 149) | def test_save_profile_creates_new(client, store): function test_save_profile_overwrites_existing (line 169) | def test_save_profile_overwrites_existing(client, store): function test_save_profile_without_secrets (line 188) | def test_save_profile_without_secrets(client, store): function test_save_profile_invalid_name (line 205) | def test_save_profile_invalid_name(client): function test_delete_profile_removes_existing (line 218) | def test_delete_profile_removes_existing(client, store): function test_delete_profile_idempotent (line 235) | def test_delete_profile_idempotent(client): function test_rename_profile_success (line 247) | def test_rename_profile_success(client, store): function test_rename_profile_preserves_secrets (line 270) | def test_rename_profile_preserves_secrets(client, store): function test_rename_profile_not_found (line 288) | def test_rename_profile_not_found(client): function test_rename_profile_conflict (line 298) | def test_rename_profile_conflict(client, store): function test_rename_profile_same_name (line 314) | def test_rename_profile_same_name(client, store): function test_rename_profile_same_name_missing_returns_404 (line 328) | def test_rename_profile_same_name_missing_returns_404(client): function test_rename_profile_invalid_new_name (line 337) | def test_rename_profile_invalid_new_name(client, store): function test_valid_profile_names (line 364) | def test_valid_profile_names(client, name): function test_invalid_profile_name_too_long (line 373) | def test_invalid_profile_name_too_long(client): function test_invalid_profile_name_leading_non_alnum (line 384) | def test_invalid_profile_name_leading_non_alnum(client, name): function test_invalid_profile_name_special_chars (line 394) | def test_invalid_profile_name_special_chars(client, name): function test_save_profile_at_limit_returns_409 (line 406) | def test_save_profile_at_limit_returns_409(client, store, monkeypatch): function test_save_profile_at_limit_overwrite_allowed (line 421) | def test_save_profile_at_limit_overwrite_allowed(client, store, monkeypa... function test_list_profiles_timeout_returns_503 (line 439) | def test_list_profiles_timeout_returns_503(client, monkeypatch): function test_get_profile_timeout_returns_503 (line 451) | def test_get_profile_timeout_returns_503(client, store, monkeypatch): function test_delete_profile_invalid_internal_name_returns_400 (line 464) | def test_delete_profile_invalid_internal_name_returns_400(client, store,... function test_list_profiles_skips_corrupted (line 476) | def test_list_profiles_skips_corrupted(client, temp_profiles_dir): function test_list_profiles_api_key_set_for_redacted (line 488) | def test_list_profiles_api_key_set_for_redacted(client, store): function test_save_profile_missing_llm_field (line 503) | def test_save_profile_missing_llm_field(client): function test_save_profile_wrong_type_for_llm (line 509) | def test_save_profile_wrong_type_for_llm(client): function test_rename_profile_missing_new_name (line 518) | def test_rename_profile_missing_new_name(client, store): function test_rename_profile_empty_new_name (line 525) | def test_rename_profile_empty_new_name(client, store): function test_get_profile_corrupted_returns_400 (line 532) | def test_get_profile_corrupted_returns_400(client, temp_profiles_dir): function test_save_profile_timeout_returns_503 (line 540) | def test_save_profile_timeout_returns_503(client, monkeypatch): function test_rename_profile_timeout_returns_503 (line 555) | def test_rename_profile_timeout_returns_503(client, store, monkeypatch): function test_delete_profile_timeout_returns_503 (line 568) | def test_delete_profile_timeout_returns_503(client, store, monkeypatch): function test_whitespace_api_key_reports_not_set (line 581) | def test_whitespace_api_key_reports_not_set(client, store): function test_save_at_limit_does_not_write_partial_state (line 596) | def test_save_at_limit_does_not_write_partial_state(client, store, monke... function test_get_profile_does_not_expose_api_key (line 613) | def test_get_profile_does_not_expose_api_key(client, store): function secret_key (line 631) | def secret_key(): function client_with_cipher (line 639) | def client_with_cipher(temp_profiles_dir, temp_settings_dir, secret_key,... function cipher (line 667) | def cipher(secret_key): function test_get_profile_invalid_expose_secrets_header_returns_400 (line 674) | def test_get_profile_invalid_expose_secrets_header_returns_400(client_wi... function test_get_profile_with_plaintext_header_exposes_secrets (line 683) | def test_get_profile_with_plaintext_header_exposes_secrets( function test_get_profile_with_encrypted_header_encrypts_secrets (line 700) | def test_get_profile_with_encrypted_header_encrypts_secrets( function test_get_profile_with_true_header_treats_as_encrypted (line 723) | def test_get_profile_with_true_header_treats_as_encrypted( function test_save_profile_with_cipher_encrypts_at_rest (line 745) | def test_save_profile_with_cipher_encrypts_at_rest( function test_encrypted_roundtrip_workflow (line 772) | def test_encrypted_roundtrip_workflow(client_with_cipher, store, cipher): function test_save_plaintext_secret_with_cipher_encrypts_at_rest (line 801) | def test_save_plaintext_secret_with_cipher_encrypts_at_rest( function test_get_profile_encrypted_without_cipher_returns_503 (line 824) | def test_get_profile_encrypted_without_cipher_returns_503(client, store): function test_save_without_cipher_stores_plaintext_for_backward_compat (line 840) | def test_save_without_cipher_stores_plaintext_for_backward_compat(client... function test_list_profiles_includes_active_profile_null_by_default (line 863) | def test_list_profiles_includes_active_profile_null_by_default(client): function test_activate_profile_success (line 873) | def test_activate_profile_success(client, store): function test_activate_profile_updates_active_profile (line 887) | def test_activate_profile_updates_active_profile(client, store): function test_activate_profile_applies_llm_config (line 904) | def test_activate_profile_applies_llm_config(client, store): function test_activate_profile_not_found (line 919) | def test_activate_profile_not_found(client): function test_activate_profile_with_api_key (line 927) | def test_activate_profile_with_api_key(client, store): function test_list_profiles_shows_active_after_activation (line 940) | def test_list_profiles_shows_active_after_activation(client, store): function test_activate_profile_invalid_name (line 962) | def test_activate_profile_invalid_name(client): function test_rename_active_profile_updates_active_profile (line 976) | def test_rename_active_profile_updates_active_profile(client, store): function test_rename_inactive_profile_preserves_active_profile (line 1003) | def test_rename_inactive_profile_preserves_active_profile(client, store): function test_list_profiles_auto_creates_profile_named_after_model (line 1029) | def test_list_profiles_auto_creates_profile_named_after_model(client): function test_list_profiles_auto_creates_profile_strips_provider_prefix (line 1057) | def test_list_profiles_auto_creates_profile_strips_provider_prefix(client): function test_list_profiles_auto_creates_profile_sanitizes_special_chars (line 1077) | def test_list_profiles_auto_creates_profile_sanitizes_special_chars(clie... function test_list_profiles_no_auto_create_without_api_key (line 1099) | def test_list_profiles_no_auto_create_without_api_key(client): function test_list_profiles_no_auto_create_when_no_config (line 1115) | def test_list_profiles_no_auto_create_when_no_config(client): function test_list_profiles_no_auto_create_when_profiles_exist (line 1126) | def test_list_profiles_no_auto_create_when_profiles_exist(client, store): function test_list_profiles_auto_create_is_idempotent (line 1151) | def test_list_profiles_auto_create_is_idempotent(client): function test_auto_created_profile_persists (line 1175) | def test_auto_created_profile_persists(client, store): FILE: tests/agent_server/test_pub_sub.py class MockEvent (line 18) | class MockEvent: method __init__ (line 21) | def __init__(self, event_type="test_event", data="test_data"): method model_dump (line 25) | def model_dump(self): class MockLogger (line 30) | class MockLogger: method __init__ (line 33) | def __init__(self): method debug (line 38) | def debug(self, message): method warning (line 41) | def warning(self, message): method error (line 44) | def error(self, message, exc_info=False): class SubscriberForTesting (line 49) | class SubscriberForTesting(ABC): method __call__ (line 51) | async def __call__(self, event): method close (line 54) | async def close(self): class PubSubForTesting (line 60) | class PubSubForTesting: method subscribe (line 66) | def subscribe(self, subscriber: SubscriberForTesting) -> UUID: method unsubscribe (line 73) | def unsubscribe(self, subscriber_id: UUID) -> bool: method __call__ (line 85) | async def __call__(self, event) -> None: method close (line 102) | async def close(self): class MockSubscriber (line 111) | class MockSubscriber(SubscriberForTesting): method __init__ (line 114) | def __init__(self, name="test_subscriber"): method __call__ (line 122) | async def __call__(self, event): method close (line 130) | async def close(self): function pubsub (line 136) | def pubsub(): function sample_event (line 142) | def sample_event(): function sample_events (line 148) | def sample_events(): function mock_subscriber (line 157) | def mock_subscriber(): function mock_subscribers (line 163) | def mock_subscribers(): class TestPubSubSubscribe (line 172) | class TestPubSubSubscribe: method test_subscribe_single_subscriber (line 175) | def test_subscribe_single_subscriber(self, pubsub, mock_subscriber): method test_subscribe_multiple_subscribers (line 193) | def test_subscribe_multiple_subscribers(self, pubsub, mock_subscribers): method test_subscribe_same_subscriber_multiple_times (line 211) | def test_subscribe_same_subscriber_multiple_times(self, pubsub, mock_s... method test_subscribe_returns_unique_uuids (line 224) | def test_subscribe_returns_unique_uuids(self, pubsub): class TestPubSubUnsubscribe (line 237) | class TestPubSubUnsubscribe: method test_unsubscribe_existing_subscriber (line 240) | def test_unsubscribe_existing_subscriber(self, pubsub, mock_subscriber): method test_unsubscribe_nonexistent_subscriber (line 256) | def test_unsubscribe_nonexistent_subscriber(self, pubsub): method test_unsubscribe_multiple_subscribers (line 274) | def test_unsubscribe_multiple_subscribers(self, pubsub, mock_subscribe... method test_unsubscribe_already_unsubscribed (line 295) | def test_unsubscribe_already_unsubscribed(self, pubsub, mock_subscriber): method test_unsubscribe_partial_removal (line 307) | def test_unsubscribe_partial_removal(self, pubsub, mock_subscribers): class TestPubSubCall (line 332) | class TestPubSubCall: method test_call_with_no_subscribers (line 336) | async def test_call_with_no_subscribers(self, pubsub, sample_event): method test_call_with_single_subscriber (line 342) | async def test_call_with_single_subscriber( method test_call_with_multiple_subscribers (line 356) | async def test_call_with_multiple_subscribers( method test_call_with_multiple_events (line 373) | async def test_call_with_multiple_events( method test_call_distributes_to_all_current_subscribers (line 388) | async def test_call_distributes_to_all_current_subscribers( method test_call_with_subscriber_error_isolation (line 407) | async def test_call_with_subscriber_error_isolation( class _TimedSubscriber (line 434) | class _TimedSubscriber(SubscriberForTesting): method __init__ (line 437) | def __init__(self, name: str, delay: float, log: list[tuple[str, float... method __call__ (line 442) | async def __call__(self, event): class TestPubSubConcurrentDispatch (line 448) | class TestPubSubConcurrentDispatch: method test_slow_subscriber_does_not_block_others (line 452) | async def test_slow_subscriber_does_not_block_others(self, pubsub): class TestPubSubEventIsolation (line 469) | class TestPubSubEventIsolation: method test_unsubscribed_subscriber_no_events (line 473) | async def test_unsubscribed_subscriber_no_events( method test_unsubscribe_during_event_processing (line 499) | async def test_unsubscribe_during_event_processing( method test_resubscribe_after_unsubscribe (line 539) | async def test_resubscribe_after_unsubscribe( class TestPubSubClose (line 566) | class TestPubSubClose: method test_close_with_no_subscribers (line 570) | async def test_close_with_no_subscribers(self, pubsub): method test_close_with_single_subscriber (line 577) | async def test_close_with_single_subscriber(self, pubsub, mock_subscri... method test_close_with_multiple_subscribers (line 590) | async def test_close_with_multiple_subscribers(self, pubsub, mock_subs... method test_close_only_calls_current_subscribers (line 606) | async def test_close_only_calls_current_subscribers(self, pubsub, mock... method test_close_handles_subscriber_close_errors (line 632) | async def test_close_handles_subscriber_close_errors( method test_close_concurrent_execution (line 657) | async def test_close_concurrent_execution(self, pubsub): class TestPubSubErrorHandling (line 686) | class TestPubSubErrorHandling: method test_subscriber_exception_isolation (line 690) | async def test_subscriber_exception_isolation( method test_multiple_events_with_errors (line 717) | async def test_multiple_events_with_errors( class TestPubSubIntegration (line 746) | class TestPubSubIntegration: method test_full_lifecycle (line 750) | async def test_full_lifecycle(self, pubsub, sample_events): method test_concurrent_subscribe_unsubscribe (line 791) | async def test_concurrent_subscribe_unsubscribe(self, pubsub, sample_e... method test_stress_test_many_subscribers (line 828) | async def test_stress_test_many_subscribers(self, pubsub, sample_event): class TestPubSubMaxSubscribers (line 857) | class TestPubSubMaxSubscribers: method test_subscribe_rejected_at_limit (line 860) | async def test_subscribe_rejected_at_limit(self): method test_subscribe_allowed_after_unsubscribe (line 878) | async def test_subscribe_allowed_after_unsubscribe(self): method test_no_limit_when_none (line 894) | async def test_no_limit_when_none(self): FILE: tests/agent_server/test_server_details_router.py function reset_initialization_state (line 14) | def reset_initialization_state(): function client (line 22) | def client(): function test_alive_and_health_return_ok_status (line 27) | def test_alive_and_health_return_ok_status(client): function test_ready_returns_503_before_init (line 35) | def test_ready_returns_503_before_init(client): function test_ready_returns_200_after_init (line 42) | def test_ready_returns_200_after_init(client): function test_ready_resets_after_new_event (line 50) | def test_ready_resets_after_new_event(client): function test_server_info_reports_usable_tools (line 61) | def test_server_info_reports_usable_tools(client, monkeypatch: pytest.Mo... FILE: tests/agent_server/test_settings_router.py function temp_persistence_dir (line 29) | def temp_persistence_dir(): function secret_key (line 47) | def secret_key(): function config_with_settings (line 53) | def config_with_settings(temp_persistence_dir, secret_key): function _encrypt (line 62) | def _encrypt(cipher: Cipher, value: str) -> str: function _write_settings_file (line 68) | def _write_settings_file(persistence_dir: Path, payload: dict) -> None: function client_with_settings (line 73) | def client_with_settings(config_with_settings): function test_get_agent_settings_schema (line 78) | def test_get_agent_settings_schema(): function test_get_conversation_settings_schema (line 101) | def test_get_conversation_settings_schema(): function test_get_settings_returns_default_settings (line 124) | def test_get_settings_returns_default_settings(client_with_settings): function test_get_settings_migrates_legacy_openhands_settings_and_resaves_current (line 136) | def test_get_settings_migrates_legacy_openhands_settings_and_resaves_cur... function test_get_settings_migrates_acp_settings_and_resaves_encrypted_env (line 266) | def test_get_settings_migrates_acp_settings_and_resaves_encrypted_env( function test_persisted_settings_from_persisted_rejects_newer_schema_version (line 342) | def test_persisted_settings_from_persisted_rejects_newer_schema_version(... function test_get_settings_without_header_redacts_secrets (line 349) | def test_get_settings_without_header_redacts_secrets( function test_get_settings_with_plaintext_header_exposes_secrets (line 370) | def test_get_settings_with_plaintext_header_exposes_secrets( function test_get_settings_with_encrypted_header_encrypts_secrets (line 392) | def test_get_settings_with_encrypted_header_encrypts_secrets( function test_get_settings_with_true_header_treats_as_encrypted (line 419) | def test_get_settings_with_true_header_treats_as_encrypted( function test_get_settings_with_invalid_header_returns_400 (line 445) | def test_get_settings_with_invalid_header_returns_400(client_with_settin... function test_patch_settings_updates_llm_config (line 458) | def test_patch_settings_updates_llm_config(client_with_settings): function test_patch_settings_encrypts_mcp_env_and_headers_on_disk (line 475) | def test_patch_settings_encrypts_mcp_env_and_headers_on_disk( function test_patch_settings_empty_payload_returns_400 (line 533) | def test_patch_settings_empty_payload_returns_400(client_with_settings): function test_patch_settings_deep_merges (line 541) | def test_patch_settings_deep_merges(client_with_settings): function test_list_secrets_empty (line 564) | def test_list_secrets_empty(client_with_settings): function test_create_and_list_secrets (line 573) | def test_create_and_list_secrets(client_with_settings): function test_get_secret_value (line 596) | def test_get_secret_value(client_with_settings): function test_get_secret_value_not_found (line 612) | def test_get_secret_value_not_found(client_with_settings): function test_delete_secret (line 619) | def test_delete_secret(client_with_settings): function test_secret_name_validation (line 637) | def test_secret_name_validation(client_with_settings): function test_patch_settings_validation_error_returns_422 (line 664) | def test_patch_settings_validation_error_returns_422(client_with_settings): function test_patch_settings_validation_error_does_not_leak_secrets (line 676) | def test_patch_settings_validation_error_does_not_leak_secrets(client_wi... function test_secret_upsert_updates_existing (line 701) | def test_secret_upsert_updates_existing(client_with_settings): function test_secret_name_validation_on_get (line 727) | def test_secret_name_validation_on_get(client_with_settings): function test_secret_name_validation_on_delete (line 734) | def test_secret_name_validation_on_delete(client_with_settings): function test_concurrent_patch_updates_preserve_data (line 744) | def test_concurrent_patch_updates_preserve_data(client_with_settings): function test_get_settings_encrypted_mode_without_cipher_returns_503 (line 795) | def test_get_settings_encrypted_mode_without_cipher_returns_503(temp_per... function test_patch_settings_corrupted_file_returns_409 (line 827) | def test_patch_settings_corrupted_file_returns_409( function test_create_secret_corrupted_file_returns_500 (line 859) | def test_create_secret_corrupted_file_returns_500( function test_delete_secret_corrupted_file_returns_500 (line 886) | def test_delete_secret_corrupted_file_returns_500( FILE: tests/agent_server/test_skills_router.py function client (line 23) | def client(): function mock_installed_skill_info (line 30) | def mock_installed_skill_info(): class TestGetSkillsEndpoint (line 45) | class TestGetSkillsEndpoint: method test_get_skills_default_request (line 48) | def test_get_skills_default_request(self, client): method test_get_skills_with_project_dir (line 67) | def test_get_skills_with_project_dir(self, client): method test_get_skills_with_org_config (line 86) | def test_get_skills_with_org_config(self, client): method test_get_skills_with_sandbox_config (line 110) | def test_get_skills_with_sandbox_config(self, client): method test_get_skills_disabled_sources (line 140) | def test_get_skills_disabled_sources(self, client): method test_get_skills_converts_skill_to_skill_info (line 163) | def test_get_skills_converts_skill_to_skill_info(self, client): method test_get_skills_agent_skill_format (line 192) | def test_get_skills_agent_skill_format(self, client): method test_get_skills_response_sources (line 217) | def test_get_skills_response_sources(self, client): class TestSyncSkillsEndpoint (line 242) | class TestSyncSkillsEndpoint: method test_sync_skills_success (line 245) | def test_sync_skills_success(self, client): method test_sync_skills_failure (line 259) | def test_sync_skills_failure(self, client): class TestPydanticModels (line 275) | class TestPydanticModels: method test_exposed_url_validation (line 278) | def test_exposed_url_validation(self, client): method test_org_config_validation (line 300) | def test_org_config_validation(self, client): method test_invalid_request_body (line 319) | def test_invalid_request_body(self, client): method test_missing_required_org_config_fields (line 329) | def test_missing_required_org_config_fields(self, client): class TestInstallSkillEndpoint (line 343) | class TestInstallSkillEndpoint: method test_install_skill_success (line 346) | def test_install_skill_success(self, client, mock_installed_skill_info): method test_install_skill_with_force (line 364) | def test_install_skill_with_force(self, client, mock_installed_skill_i... method test_install_skill_with_ref (line 384) | def test_install_skill_with_ref(self, client, mock_installed_skill_info): method test_install_skill_already_exists (line 406) | def test_install_skill_already_exists(self, client): method test_install_skill_fetch_error (line 421) | def test_install_skill_fetch_error(self, client): method test_install_skill_extension_fetch_error (line 436) | def test_install_skill_extension_fetch_error(self, client): method test_install_skill_validation_error (line 454) | def test_install_skill_validation_error(self, client): class TestListInstalledSkillsEndpoint (line 470) | class TestListInstalledSkillsEndpoint: method test_list_installed_skills_empty (line 473) | def test_list_installed_skills_empty(self, client): method test_list_installed_skills_with_skills (line 486) | def test_list_installed_skills_with_skills(self, client, mock_installe... class TestGetInstalledSkillEndpoint (line 501) | class TestGetInstalledSkillEndpoint: method test_get_installed_skill_found (line 504) | def test_get_installed_skill_found(self, client, mock_installed_skill_... method test_get_installed_skill_not_found (line 517) | def test_get_installed_skill_not_found(self, client): class TestUpdateSkillStateEndpoint (line 530) | class TestUpdateSkillStateEndpoint: method test_enable_skill_success (line 533) | def test_enable_skill_success(self, client): method test_disable_skill_success (line 550) | def test_disable_skill_success(self, client): method test_update_skill_state_not_found (line 566) | def test_update_skill_state_not_found(self, client): class TestUninstallSkillEndpoint (line 581) | class TestUninstallSkillEndpoint: method test_uninstall_skill_success (line 584) | def test_uninstall_skill_success(self, client): method test_uninstall_skill_not_found (line 597) | def test_uninstall_skill_not_found(self, client): class TestRefreshSkillEndpoint (line 609) | class TestRefreshSkillEndpoint: method test_refresh_skill_success (line 612) | def test_refresh_skill_success(self, client, mock_installed_skill_info): method test_refresh_skill_not_found (line 625) | def test_refresh_skill_not_found(self, client): class TestMarketplaceCatalogEndpoint (line 637) | class TestMarketplaceCatalogEndpoint: method test_get_marketplace_catalog_empty (line 640) | def test_get_marketplace_catalog_empty(self, client): method test_get_marketplace_catalog_with_skills (line 653) | def test_get_marketplace_catalog_with_skills(self, client): method test_get_marketplace_catalog_skill_without_description (line 688) | def test_get_marketplace_catalog_skill_without_description(self, client): FILE: tests/agent_server/test_skills_service.py class TestExposedUrlData (line 20) | class TestExposedUrlData: method test_create_exposed_url_data (line 23) | def test_create_exposed_url_data(self): class TestCreateSandboxSkill (line 35) | class TestCreateSandboxSkill: method test_create_sandbox_skill_with_worker_urls (line 38) | def test_create_sandbox_skill_with_worker_urls(self): method test_create_sandbox_skill_no_worker_urls (line 56) | def test_create_sandbox_skill_no_worker_urls(self): method test_create_sandbox_skill_mixed_urls (line 67) | def test_create_sandbox_skill_mixed_urls(self): method test_create_sandbox_skill_empty_list (line 82) | def test_create_sandbox_skill_empty_list(self): method test_sandbox_worker_url_prefix_constant (line 87) | def test_sandbox_worker_url_prefix_constant(self): class TestMergeSkills (line 92) | class TestMergeSkills: method test_merge_empty_lists (line 95) | def test_merge_empty_lists(self): method test_merge_single_list (line 100) | def test_merge_single_list(self): method test_merge_multiple_lists_no_duplicates (line 112) | def test_merge_multiple_lists_no_duplicates(self): method test_merge_with_duplicates_later_wins (line 123) | def test_merge_with_duplicates_later_wins(self): method test_merge_preserves_precedence_order (line 134) | def test_merge_preserves_precedence_order(self): class TestLoadOrgSkillsFromUrl (line 146) | class TestLoadOrgSkillsFromUrl: method test_load_org_skills_git_clone_failure (line 149) | def test_load_org_skills_git_clone_failure(self): method test_load_org_skills_repo_not_found (line 161) | def test_load_org_skills_repo_not_found(self): method test_load_org_skills_timeout (line 178) | def test_load_org_skills_timeout(self): method test_load_org_skills_custom_working_dir (line 195) | def test_load_org_skills_custom_working_dir(self): class TestLoadAllSkills (line 215) | class TestLoadAllSkills: method test_load_all_skills_returns_skill_load_result (line 220) | def test_load_all_skills_returns_skill_load_result(self): method test_load_all_skills_sources_tracking (line 234) | def test_load_all_skills_sources_tracking(self): method test_load_all_skills_passes_marketplace_path_to_sdk_base (line 259) | def test_load_all_skills_passes_marketplace_path_to_sdk_base(self): method test_load_all_skills_disabled_sources (line 277) | def test_load_all_skills_disabled_sources(self): method test_load_all_skills_with_sandbox_urls (line 292) | def test_load_all_skills_with_sandbox_urls(self): method test_load_all_skills_handles_exceptions (line 311) | def test_load_all_skills_handles_exceptions(self): method test_load_all_skills_merge_precedence (line 334) | def test_load_all_skills_merge_precedence(self): class TestSyncPublicSkills (line 361) | class TestSyncPublicSkills: method test_sync_public_skills_success (line 364) | def test_sync_public_skills_success(self): method test_sync_public_skills_failure (line 382) | def test_sync_public_skills_failure(self): method test_sync_public_skills_exception (line 400) | def test_sync_public_skills_exception(self): method test_sync_public_skills_invalidates_in_memory_cache (line 412) | def test_sync_public_skills_invalidates_in_memory_cache(self): method test_sync_public_skills_failure_does_not_invalidate_cache (line 434) | def test_sync_public_skills_failure_does_not_invalidate_cache(self): class TestSkillLoadResult (line 457) | class TestSkillLoadResult: method test_skill_load_result_creation (line 460) | def test_skill_load_result_creation(self): method test_skill_load_result_empty (line 470) | def test_skill_load_result_empty(self): class TestMarketplaceCatalogCache (line 478) | class TestMarketplaceCatalogCache: method setup_method (line 481) | def setup_method(self): method test_cache_miss_calls_fetch (line 487) | def test_cache_miss_calls_fetch(self): method test_cache_hit_skips_fetch (line 511) | def test_cache_hit_skips_fetch(self): method test_installed_status_always_fresh (line 533) | def test_installed_status_always_fresh(self): method test_cache_expires_after_ttl (line 568) | def test_cache_expires_after_ttl(self): FILE: tests/agent_server/test_terminal_router.py function test_bash_service (line 17) | def test_bash_service(): function client (line 27) | def client(): function test_clear_all_bash_events_empty_storage (line 34) | async def test_clear_all_bash_events_empty_storage(): function test_clear_all_bash_events_with_data (line 49) | async def test_clear_all_bash_events_with_data(): function test_clear_all_bash_events_integration (line 64) | async def test_clear_all_bash_events_integration(test_bash_service): FILE: tests/agent_server/test_terminal_service.py function bash_service (line 23) | def bash_service(): class EventCollector (line 32) | class EventCollector(Subscriber): method __init__ (line 35) | def __init__(self): method __call__ (line 40) | async def __call__(self, event): function test_single_output_command (line 49) | async def test_single_output_command(bash_service): function test_multiple_output_command (line 90) | async def test_multiple_output_command(bash_service): function test_command_with_stderr (line 134) | async def test_command_with_stderr(bash_service): function test_command_with_error_exit_code (line 173) | async def test_command_with_error_exit_code(bash_service): function test_command_timeout (line 195) | async def test_command_timeout(bash_service): function test_large_output_chunking (line 231) | async def test_large_output_chunking(bash_service): function test_concurrent_commands (line 266) | async def test_concurrent_commands(bash_service): function test_event_persistence (line 295) | async def test_event_persistence(bash_service): function test_search_bash_events (line 317) | async def test_search_bash_events(bash_service): function test_service_lifecycle (line 345) | async def test_service_lifecycle(bash_service): function test_clear_all_events_empty_storage (line 360) | async def test_clear_all_events_empty_storage(bash_service): function test_clear_all_events_with_data (line 368) | async def test_clear_all_events_with_data(bash_service): function test_clear_all_events_partial_failure (line 403) | async def test_clear_all_events_partial_failure(bash_service): function test_search_with_filtering (line 424) | async def test_search_with_filtering(bash_service): function test_search_pagination (line 471) | async def test_search_pagination(bash_service): function test_terminal_does_not_expose_session_api_key (line 501) | async def test_terminal_does_not_expose_session_api_key(bash_service, mo... function test_terminal_does_not_expose_session_api_key_via_env_command (line 543) | async def test_terminal_does_not_expose_session_api_key_via_env_command( FILE: tests/agent_server/test_tool_router.py function test_builtin_agents_registered_on_tool_router_import (line 11) | def test_builtin_agents_registered_on_tool_router_import(): FILE: tests/agent_server/test_validation_error_sanitization.py class TestSanitizeValidationErrors (line 25) | class TestSanitizeValidationErrors: method test_redacts_api_key_in_input (line 28) | def test_redacts_api_key_in_input(self): method test_redacts_acp_env_values (line 54) | def test_redacts_acp_env_values(self): method test_preserves_non_secret_fields (line 76) | def test_preserves_non_secret_fields(self): method test_handles_errors_without_input (line 95) | def test_handles_errors_without_input(self): method test_handles_scalar_input (line 107) | def test_handles_scalar_input(self): method test_does_not_mutate_original (line 120) | def test_does_not_mutate_original(self): method test_redacts_multiple_secret_patterns (line 142) | def test_redacts_multiple_secret_patterns(self): method test_empty_errors_list (line 168) | def test_empty_errors_list(self): class TestValidationErrorResponse (line 178) | class TestValidationErrorResponse: method app_with_validation (line 182) | def app_with_validation(self): method test_422_response_redacts_api_key (line 199) | def test_422_response_redacts_api_key(self, app_with_validation): method test_422_response_preserves_error_structure (line 226) | def test_422_response_preserves_error_structure(self, app_with_validat... method test_valid_request_unaffected (line 243) | def test_valid_request_unaffected(self, app_with_validation): method test_422_with_non_json_body (line 257) | def test_422_with_non_json_body(self, app_with_validation): FILE: tests/agent_server/test_vscode_router.py function client (line 18) | def client(): function mock_vscode_service (line 26) | def mock_vscode_service(): function test_get_vscode_url_success (line 33) | async def test_get_vscode_url_success(mock_vscode_service): function test_get_vscode_url_error (line 49) | async def test_get_vscode_url_error(mock_vscode_service): function test_get_vscode_status_running (line 61) | async def test_get_vscode_status_running(mock_vscode_service): function test_get_vscode_status_not_running (line 72) | async def test_get_vscode_status_not_running(mock_vscode_service): function test_get_vscode_status_error (line 82) | async def test_get_vscode_status_error(mock_vscode_service): function test_vscode_router_endpoints_integration (line 93) | def test_vscode_router_endpoints_integration(client): function test_vscode_router_endpoints_with_errors (line 129) | def test_vscode_router_endpoints_with_errors(client): function test_get_vscode_url_disabled (line 159) | async def test_get_vscode_url_disabled(): function test_get_vscode_status_disabled (line 174) | async def test_get_vscode_status_disabled(): function test_vscode_router_disabled_integration (line 190) | def test_vscode_router_disabled_integration(client): FILE: tests/agent_server/test_vscode_service.py function vscode_service (line 15) | def vscode_service(tmp_path): function mock_openvscode_binary (line 23) | def mock_openvscode_binary(tmp_path): function test_vscode_service_initialization (line 38) | def test_vscode_service_initialization(tmp_path): function test_vscode_service_initialization_with_server_base_path (line 48) | def test_vscode_service_initialization_with_server_base_path(): function test_check_vscode_available_false (line 58) | def test_check_vscode_available_false(vscode_service, tmp_path): function test_check_vscode_available_true (line 65) | def test_check_vscode_available_true(vscode_service, mock_openvscode_bin... function test_is_port_available_true (line 72) | async def test_is_port_available_true(tmp_path): function test_is_port_available_false (line 79) | async def test_is_port_available_false(tmp_path): function test_start_success (line 93) | async def test_start_success(vscode_service, mock_openvscode_binary, tmp... function test_start_no_binary (line 109) | async def test_start_no_binary(vscode_service, tmp_path): function test_start_port_unavailable (line 120) | async def test_start_port_unavailable(vscode_service, mock_openvscode_bi... function test_stop_with_process (line 134) | async def test_stop_with_process(vscode_service): function test_stop_with_timeout (line 149) | async def test_stop_with_timeout(vscode_service): function test_stop_no_process (line 166) | async def test_stop_no_process(vscode_service): function test_get_vscode_url_no_token (line 171) | def test_get_vscode_url_no_token(vscode_service): function test_get_vscode_url_with_token (line 177) | def test_get_vscode_url_with_token(vscode_service): function test_get_vscode_url_with_custom_port (line 193) | def test_get_vscode_url_with_custom_port(): function test_is_running_false (line 202) | def test_is_running_false(vscode_service): function test_is_running_true (line 207) | def test_is_running_true(vscode_service): function test_is_running_finished_process (line 216) | def test_is_running_finished_process(vscode_service): function test_start_vscode_process (line 226) | async def test_start_vscode_process(vscode_service, tmp_path): function test_start_vscode_process_with_server_base_path (line 247) | async def test_start_vscode_process_with_server_base_path(): function test_start_vscode_process_without_server_base_path (line 270) | async def test_start_vscode_process_without_server_base_path(): function test_wait_for_startup_success (line 291) | async def test_wait_for_startup_success(vscode_service): function test_wait_for_startup_timeout (line 313) | async def test_wait_for_startup_timeout(vscode_service): function test_get_vscode_service_enabled (line 332) | def test_get_vscode_service_enabled(tmp_path): function test_get_vscode_service_disabled (line 348) | def test_get_vscode_service_disabled(): function test_get_vscode_service_singleton (line 361) | def test_get_vscode_service_singleton(): function test_get_vscode_service_with_custom_port (line 379) | def test_get_vscode_service_with_custom_port(): function test_get_vscode_service_with_base_path (line 396) | def test_get_vscode_service_with_base_path(): function test_vscode_service_with_different_ports (line 413) | def test_vscode_service_with_different_ports(): function test_vscode_port_configuration (line 422) | def test_vscode_port_configuration(): function test_vscode_base_path_configuration (line 438) | def test_vscode_base_path_configuration(): FILE: tests/agent_server/test_webhook_subscriber.py function mock_event_service (line 38) | def mock_event_service(): function webhook_spec (line 64) | def webhook_spec(): function minimal_webhook_spec (line 77) | def minimal_webhook_spec(): function sample_event (line 83) | def sample_event(): function sample_events (line 92) | def sample_events(): function sample_conversation_id (line 104) | def sample_conversation_id(): class TestWebhookSpecValidation (line 109) | class TestWebhookSpecValidation: method test_webhook_spec_default_flush_delay (line 112) | def test_webhook_spec_default_flush_delay(self): method test_webhook_spec_custom_flush_delay (line 117) | def test_webhook_spec_custom_flush_delay(self): method test_webhook_spec_flush_delay_validation_positive (line 122) | def test_webhook_spec_flush_delay_validation_positive(self): method test_webhook_spec_flush_delay_validation_negative (line 132) | def test_webhook_spec_flush_delay_validation_negative(self): method test_webhook_spec_flush_delay_validation_small_positive (line 142) | def test_webhook_spec_flush_delay_validation_small_positive(self): class TestWebhookSubscriberInitialization (line 148) | class TestWebhookSubscriberInitialization: method test_init_with_all_parameters (line 151) | def test_init_with_all_parameters( method test_init_without_session_api_key (line 169) | def test_init_without_session_api_key( method test_init_with_minimal_spec (line 185) | def test_init_with_minimal_spec( class TestWebhookSubscriberCallMethod (line 202) | class TestWebhookSubscriberCallMethod: method test_call_adds_event_to_queue (line 206) | async def test_call_adds_event_to_queue( method test_call_multiple_events_below_buffer_size (line 222) | async def test_call_multiple_events_below_buffer_size( method test_call_triggers_post_when_buffer_full (line 241) | async def test_call_triggers_post_when_buffer_full( method test_call_triggers_post_multiple_times (line 265) | async def test_call_triggers_post_multiple_times( class TestWebhookSubscriberPostEvents (line 303) | class TestWebhookSubscriberPostEvents: method test_post_events_success (line 308) | async def test_post_events_success( method test_post_events_with_session_api_key (line 353) | async def test_post_events_with_session_api_key( method test_post_events_empty_queue (line 397) | async def test_post_events_empty_queue( method test_post_events_http_error_with_retries (line 413) | async def test_post_events_http_error_with_retries( method test_post_events_max_retries_exceeded (line 462) | async def test_post_events_max_retries_exceeded( method test_post_events_drops_oldest_when_requeue_exceeds_max_queue_size (line 507) | async def test_post_events_drops_oldest_when_requeue_exceeds_max_queue... method test_post_events_handles_events_without_model_dump (line 555) | async def test_post_events_handles_events_without_model_dump( class TestWebhookSubscriberCloseMethod (line 599) | class TestWebhookSubscriberCloseMethod: method test_close_posts_remaining_events (line 604) | async def test_close_posts_remaining_events( method test_close_with_empty_queue (line 630) | async def test_close_with_empty_queue( class TestWebhookSubscriberIntegration (line 647) | class TestWebhookSubscriberIntegration: method test_full_workflow (line 652) | async def test_full_workflow( method test_concurrent_event_processing (line 702) | async def test_concurrent_event_processing( class TestWebhookSubscriberErrorHandling (line 738) | class TestWebhookSubscriberErrorHandling: method test_network_error_handling (line 743) | async def test_network_error_handling( method test_timeout_error_handling (line 777) | async def test_timeout_error_handling( class TestWebhookSubscriberFlushDelay (line 810) | class TestWebhookSubscriberFlushDelay: method test_flush_delay_triggers_post (line 815) | async def test_flush_delay_triggers_post( method test_flush_delay_not_reset_on_new_event (line 850) | async def test_flush_delay_not_reset_on_new_event( method test_flush_delay_cancelled_on_buffer_full (line 892) | async def test_flush_delay_cancelled_on_buffer_full( method test_flush_delay_cancelled_on_close (line 934) | async def test_flush_delay_cancelled_on_close( method test_flush_delay_no_post_when_queue_empty (line 974) | async def test_flush_delay_no_post_when_queue_empty( method test_flush_delay_triggers_on_timer (line 993) | async def test_flush_delay_triggers_on_timer( class TestConversationWebhookSubscriber (line 1027) | class TestConversationWebhookSubscriber: method test_post_conversation_info_success (line 1032) | async def test_post_conversation_info_success( method test_post_conversation_info_with_session_api_key (line 1079) | async def test_post_conversation_info_with_session_api_key( method test_post_conversation_info_http_error_with_retries (line 1128) | async def test_post_conversation_info_http_error_with_retries( class TestWebhookSubscriberTimerBehavior (line 1185) | class TestWebhookSubscriberTimerBehavior: method test_timer_not_reset_on_subsequent_events (line 1189) | async def test_timer_not_reset_on_subsequent_events( method test_timer_only_started_once_until_flush (line 1233) | async def test_timer_only_started_once_until_flush( method test_timer_cancelled_when_buffer_full (line 1272) | async def test_timer_cancelled_when_buffer_full( function test_webhook_subscribe_errors_surface (line 1308) | async def test_webhook_subscribe_errors_surface(tmp_path, monkeypatch): FILE: tests/agent_server/test_websocket_first_message_auth.py function _make_mock_websocket (line 14) | def _make_mock_websocket(*, headers=None): function test_no_auth_configured_accepts_immediately (line 30) | async def test_no_auth_configured_accepts_immediately(): function test_legacy_query_param_valid_key (line 45) | async def test_legacy_query_param_valid_key(): function test_legacy_query_param_invalid_key (line 59) | async def test_legacy_query_param_invalid_key(): function test_legacy_query_param_takes_precedence_over_first_message (line 73) | async def test_legacy_query_param_takes_precedence_over_first_message(): function test_legacy_header_valid_key (line 95) | async def test_legacy_header_valid_key(): function test_legacy_header_invalid_key (line 106) | async def test_legacy_header_invalid_key(): function test_first_message_auth_valid_key (line 120) | async def test_first_message_auth_valid_key(): function test_first_message_auth_invalid_key (line 135) | async def test_first_message_auth_invalid_key(): function test_first_message_auth_wrong_type_field (line 150) | async def test_first_message_auth_wrong_type_field(): function test_first_message_auth_missing_key_field (line 163) | async def test_first_message_auth_missing_key_field(): function test_first_message_auth_malformed_json (line 174) | async def test_first_message_auth_malformed_json(): function test_first_message_auth_client_disconnects (line 186) | async def test_first_message_auth_client_disconnects(): function test_first_message_auth_timeout (line 197) | async def test_first_message_auth_timeout(): function test_events_socket_first_message_auth_e2e (line 222) | async def test_events_socket_first_message_auth_e2e(): function test_events_socket_ignores_redundant_auth_control_frame (line 255) | async def test_events_socket_ignores_redundant_auth_control_frame(): function test_events_socket_first_message_auth_rejected (line 303) | async def test_events_socket_first_message_auth_rejected(): FILE: tests/agent_server/test_workspace_cookie_auth.py function client_factory (line 30) | def client_factory(tmp_path): function workspace_with_index (line 60) | def workspace_with_index(tmp_path): function _workspace_url (line 65) | def _workspace_url(cid: UUID, path: str = "index.html") -> str: function test_workspace_rejects_request_without_credentials (line 72) | def test_workspace_rejects_request_without_credentials( function test_workspace_accepts_valid_header (line 81) | def test_workspace_accepts_valid_header(client_factory, workspace_with_i... function test_workspace_rejects_invalid_header (line 93) | def test_workspace_rejects_invalid_header(client_factory, workspace_with... function test_mint_session_requires_header (line 107) | def test_mint_session_requires_header(client_factory, workspace_with_ind... function test_mint_session_rejects_bad_header (line 115) | def test_mint_session_rejects_bad_header(client_factory): function test_mint_session_returns_cookie_attrs_over_https (line 125) | def test_mint_session_returns_cookie_attrs_over_https(client_factory): function test_mint_session_marks_cookie_secure_on_loopback (line 160) | def test_mint_session_marks_cookie_secure_on_loopback(client_factory, ho... function test_mint_session_over_remote_plain_http_drops_secure (line 178) | def test_mint_session_over_remote_plain_http_drops_secure(client_factory): function test_workspace_accepts_valid_cookie (line 204) | def test_workspace_accepts_valid_cookie(client_factory, workspace_with_i... function test_workspace_rejects_bogus_cookie (line 221) | def test_workspace_rejects_bogus_cookie(client_factory, workspace_with_i... function test_cookie_does_not_authenticate_other_api_endpoints (line 233) | def test_cookie_does_not_authenticate_other_api_endpoints(client_factory): function test_delete_session_clears_cookie (line 253) | def test_delete_session_clears_cookie(client_factory): FILE: tests/agent_server/test_workspace_router.py function client_factory (line 22) | def client_factory(tmp_path): function test_url_path_helper_includes_conversation_id (line 55) | def test_url_path_helper_includes_conversation_id(): function test_serve_file_at_workspace_root (line 62) | def test_serve_file_at_workspace_root(client_factory, tmp_path): function test_serve_file_in_subdirectory_with_inferred_content_type (line 73) | def test_serve_file_in_subdirectory_with_inferred_content_type( function test_root_serves_index_html_when_present (line 89) | def test_root_serves_index_html_when_present(client_factory, tmp_path): function test_directory_serves_index_html (line 104) | def test_directory_serves_index_html(client_factory, tmp_path): function test_directory_without_index_returns_404 (line 116) | def test_directory_without_index_returns_404(client_factory, tmp_path): function test_missing_file_returns_404 (line 125) | def test_missing_file_returns_404(client_factory, tmp_path): function test_path_traversal_is_rejected (line 133) | def test_path_traversal_is_rejected(client_factory, tmp_path): function test_unknown_conversation_returns_404 (line 156) | def test_unknown_conversation_returns_404(client_factory, tmp_path): function test_symlink_pointing_outside_workspace_is_rejected (line 165) | def test_symlink_pointing_outside_workspace_is_rejected(client_factory, ... function test_symlink_pointing_inside_workspace_is_served (line 186) | def test_symlink_pointing_inside_workspace_is_served(client_factory, tmp... function test_non_local_workspace_returns_404 (line 203) | def test_non_local_workspace_returns_404(tmp_path): FILE: tests/command_utils.py function shell_join (line 13) | def shell_join(args: list[str]) -> str: function python_command (line 19) | def python_command(script: str) -> str: function touch_command (line 23) | def touch_command(path: str | Path) -> str: function sleep_command (line 27) | def sleep_command(seconds: float) -> str: FILE: tests/conftest.py function pytest_addoption (line 25) | def pytest_addoption(parser: pytest.Parser) -> None: function examples_enabled (line 45) | def examples_enabled(pytestconfig: pytest.Config) -> bool: function examples_results_dir (line 50) | def examples_results_dir(pytestconfig: pytest.Config) -> Path: function tokenizer_fixtures_dir (line 65) | def tokenizer_fixtures_dir() -> Path: function qwen3_tokenizer_config_path (line 71) | def qwen3_tokenizer_config_path(tokenizer_fixtures_dir: Path) -> Path: function mock_llm (line 77) | def mock_llm(): function mock_conversation_state (line 90) | def mock_conversation_state(mock_llm, tmp_path): function mock_tool (line 110) | def mock_tool(): function create_mock_litellm_response (line 124) | def create_mock_litellm_response( function suppress_logging (line 176) | def suppress_logging(monkeypatch): FILE: tests/cross/conftest.py function llm_fixtures_dir (line 10) | def llm_fixtures_dir(): function fncall_raw_logs (line 16) | def fncall_raw_logs(llm_fixtures_dir): function nonfncall_raw_logs (line 28) | def nonfncall_raw_logs(llm_fixtures_dir): FILE: tests/cross/test_agent_loading.py class ModuleScopeOtherAgent (line 36) | class ModuleScopeOtherAgent(Agent): function test_conversation_restart_with_nested_llms (line 41) | def test_conversation_restart_with_nested_llms(tmp_path): function test_conversation_restarted_with_changed_working_directory (line 97) | def test_conversation_restarted_with_changed_working_directory(tmp_path_... function test_conversation_fails_when_removing_tools (line 122) | def test_conversation_fails_when_removing_tools(): function test_conversation_succeeds_when_adding_tools (line 175) | def test_conversation_succeeds_when_adding_tools(): function test_conversation_fails_when_used_tool_is_missing (line 222) | def test_conversation_fails_when_used_tool_is_missing(): function test_conversation_with_same_agent_succeeds (line 289) | def test_conversation_with_same_agent_succeeds(): function test_conversation_with_different_llm_succeeds (line 342) | def test_conversation_with_different_llm_succeeds(): function test_conversation_fails_when_agent_type_changes (line 389) | def test_conversation_fails_when_agent_type_changes(): function test_conversation_persistence_lifecycle (line 425) | def test_conversation_persistence_lifecycle(mock_completion): function test_conversation_resume_overrides_agent_llm_but_preserves_state_settings (line 501) | def test_conversation_resume_overrides_agent_llm_but_preserves_state_set... function test_conversation_restart_with_different_agent_context (line 569) | def test_conversation_restart_with_different_agent_context(): FILE: tests/cross/test_agent_secrets_integration.py function llm (line 34) | def llm() -> LLM: function tools (line 39) | def tools() -> list[Tool]: function agent (line 45) | def agent(llm: LLM, tools: list[Tool]) -> Agent: function conversation (line 50) | def conversation(agent: Agent, tmp_path) -> LocalConversation: function terminal_executor (line 55) | def terminal_executor(conversation: LocalConversation) -> TerminalExecutor: function agent_no_bash (line 64) | def agent_no_bash(llm: LLM) -> Agent: function conversation_no_bash (line 69) | def conversation_no_bash(agent_no_bash: Agent, tmp_path) -> LocalConvers... function test_agent_configures_bash_tools_env_provider (line 73) | def test_agent_configures_bash_tools_env_provider( function test_agent_env_provider_with_callable_secrets (line 100) | def test_agent_env_provider_with_callable_secrets( function test_agent_env_provider_handles_exceptions (line 124) | def test_agent_env_provider_handles_exceptions( function test_agent_env_provider_no_matches (line 156) | def test_agent_env_provider_no_matches( function test_agent_without_bash_throws_warning (line 170) | def test_agent_without_bash_throws_warning(llm): function test_agent_secrets_integration_workflow (line 181) | def test_agent_secrets_integration_workflow( function test_mask_secrets (line 227) | def test_mask_secrets( function test_mask_changing_secrets (line 259) | def test_mask_changing_secrets( function test_masking_persists (line 290) | def test_masking_persists( function test_update_secrets_adds_to_registry (line 334) | def test_update_secrets_adds_to_registry(conversation: LocalConversation): function test_update_secrets_appears_in_dynamic_context (line 353) | def test_update_secrets_appears_in_dynamic_context(conversation: LocalCo... function test_secrets_merges_with_existing_context (line 381) | def test_secrets_merges_with_existing_context(llm: LLM, tmp_path): function test_update_secrets_overrides_existing_secret (line 424) | def test_update_secrets_overrides_existing_secret(conversation: LocalCon... function test_secrets_via_constructor_appear_in_prompt (line 451) | def test_secrets_via_constructor_appear_in_prompt(llm: LLM, tmp_path): FILE: tests/cross/test_agent_server_build_metadata.py function test_server_workflow_passes_git_metadata_build_args (line 15) | def test_server_workflow_passes_git_metadata_build_args() -> None: function test_agent_server_binary_copies_openhands_distribution_metadata (line 23) | def test_agent_server_binary_copies_openhands_distribution_metadata() ->... FILE: tests/cross/test_automatic_naming.py function test_camel_to_snake_conversion (line 4) | def test_camel_to_snake_conversion(): function test_real_tools_have_correct_names (line 26) | def test_real_tools_have_correct_names(): function test_tool_name_consistency (line 44) | def test_tool_name_consistency(): FILE: tests/cross/test_automatic_registration.py function test_bash_tool_automatic_registration (line 10) | def test_bash_tool_automatic_registration(): function test_file_editor_tool_automatic_registration (line 20) | def test_file_editor_tool_automatic_registration(): function test_task_tracker_tool_automatic_registration (line 30) | def test_task_tracker_tool_automatic_registration(): function test_browser_tool_automatic_registration (line 40) | def test_browser_tool_automatic_registration(): function test_browser_tool_usable_listing_respects_chromium_availability (line 50) | def test_browser_tool_usable_listing_respects_chromium_availability( function test_grep_tool_automatic_registration (line 75) | def test_grep_tool_automatic_registration(): function test_glob_tool_automatic_registration (line 85) | def test_glob_tool_automatic_registration(): function test_planning_file_editor_tool_automatic_registration (line 95) | def test_planning_file_editor_tool_automatic_registration(): function test_import_from_init_triggers_registration (line 105) | def test_import_from_init_triggers_registration(): function test_tool_can_be_resolved_after_automatic_registration (line 119) | def test_tool_can_be_resolved_after_automatic_registration(): FILE: tests/cross/test_check_agent_server_rest_api_breakage.py function _load_script_module (line 13) | def _load_script_module(name: str): function _schema_with_operation (line 41) | def _schema_with_operation(path: str, method: str, operation: dict) -> d... function _schema_with_property (line 52) | def _schema_with_property(property_name: str, property_schema: dict) -> ... function test_filter_public_rest_openapi_keeps_only_api_paths (line 66) | def test_filter_public_rest_openapi_keeps_only_api_paths(): function test_find_deprecation_policy_errors_ignores_non_public_paths (line 83) | def test_find_deprecation_policy_errors_ignores_non_public_paths(): function test_find_deprecation_policy_errors_requires_openapi_deprecated_flag (line 113) | def test_find_deprecation_policy_errors_requires_openapi_deprecated_flag(): function test_find_deprecation_policy_errors_accepts_deprecated_operations (line 131) | def test_find_deprecation_policy_errors_accepts_deprecated_operations(): function test_find_deprecation_policy_errors_ignores_non_deprecated_operations (line 147) | def test_find_deprecation_policy_errors_ignores_non_deprecated_operation... function test_find_sdk_deprecated_fastapi_routes_in_file_flags_direct_import (line 160) | def test_find_sdk_deprecated_fastapi_routes_in_file_flags_direct_import(... function test_find_sdk_deprecated_fastapi_routes_in_file_flags_alias_import (line 183) | def test_find_sdk_deprecated_fastapi_routes_in_file_flags_alias_import(t... function test_find_sdk_deprecated_fastapi_routes_in_file_ignores_non_route_usage (line 206) | def test_find_sdk_deprecated_fastapi_routes_in_file_ignores_non_route_us... function test_get_baseline_version_warns_and_returns_none_when_pypi_fails (line 222) | def test_get_baseline_version_warns_and_returns_none_when_pypi_fails( function test_rest_deprecation_regex_matches_deprecation_check_regex (line 237) | def test_rest_deprecation_regex_matches_deprecation_check_regex(): function test_parse_openapi_deprecation_description_extracts_versions_from_example (line 242) | def test_parse_openapi_deprecation_description_extracts_versions_from_ex... function test_validate_removed_operations_rejects_malformed_removal_version (line 251) | def test_validate_removed_operations_rejects_malformed_removal_version(): function test_validate_removed_operations_requires_scheduled_removal_version (line 273) | def test_validate_removed_operations_requires_scheduled_removal_version(): function test_validate_removed_operations_requires_removal_target_to_be_reached (line 297) | def test_validate_removed_operations_requires_removal_target_to_be_reach... function test_validate_removed_operations_allows_scheduled_removal (line 323) | def test_validate_removed_operations_allows_scheduled_removal(capsys): function test_validate_removed_schema_properties_allows_scheduled_removal (line 346) | def test_validate_removed_schema_properties_allows_scheduled_removal(cap... function test_validate_removed_schema_properties_requires_deprecation (line 372) | def test_validate_removed_schema_properties_requires_deprecation(): function test_validate_removed_schema_properties_requires_removal_target_to_be_reached (line 392) | def test_validate_removed_schema_properties_requires_removal_target_to_b... function test_main_allows_scheduled_removal_with_documented_target (line 421) | def test_main_allows_scheduled_removal_with_documented_target(monkeypatc... function test_main_allows_scheduled_property_removal_with_documented_target (line 472) | def test_main_allows_scheduled_property_removal_with_documented_target( function test_main_allows_scheduled_removal_when_baseline_matches_current (line 520) | def test_main_allows_scheduled_removal_when_baseline_matches_current( function test_main_filters_non_public_paths_before_oasdiff (line 572) | def test_main_filters_non_public_paths_before_oasdiff(monkeypatch): function test_main_rejects_non_removal_breakage_even_with_newer_version (line 613) | def test_main_rejects_non_removal_breakage_even_with_newer_version(monke... function test_split_breaking_changes_separates_three_buckets (line 647) | def test_split_breaking_changes_separates_three_buckets(): function test_main_passes_when_only_additive_oneof (line 696) | def test_main_passes_when_only_additive_oneof(monkeypatch, capsys): function test_main_passes_when_body_union_addition_reports_removed_properties (line 730) | def test_main_passes_when_body_union_addition_reports_removed_properties( function test_main_passes_when_oasdiff_reports_only_response_union_artifacts (line 798) | def test_main_passes_when_oasdiff_reports_only_response_union_artifacts( function test_main_fails_when_additive_oneof_mixed_with_real_breakage (line 846) | def test_main_fails_when_additive_oneof_mixed_with_real_breakage(monkeyp... function test_normalize_openapi_converts_numeric_exclusive_bounds (line 885) | def test_normalize_openapi_converts_numeric_exclusive_bounds(): function test_normalize_openapi_preserves_boolean_exclusive (line 926) | def test_normalize_openapi_preserves_boolean_exclusive(): FILE: tests/cross/test_check_deprecations.py function _load_prod_module (line 13) | def _load_prod_module(): function test_gather_rest_route_deprecations_collects_deprecated_route (line 31) | def test_gather_rest_route_deprecations_collects_deprecated_route(tmp_pa... function test_gather_rest_route_deprecations_supports_api_route_methods (line 57) | def test_gather_rest_route_deprecations_supports_api_route_methods(tmp_p... function test_gather_rest_route_deprecations_ignores_non_deprecated_routes (line 77) | def test_gather_rest_route_deprecations_ignores_non_deprecated_routes(tm... function test_gather_rest_route_deprecations_requires_parseable_docstring (line 93) | def test_gather_rest_route_deprecations_requires_parseable_docstring(tmp... function test_should_fail_for_overdue_rest_route_record (line 112) | def test_should_fail_for_overdue_rest_route_record(): FILE: tests/cross/test_check_sdk_api_breakage.py function _load_prod_module (line 18) | def _load_prod_module(): function _write_pkg_init (line 50) | def _write_pkg_init( function _mock_pypi_releases (line 73) | def _mock_pypi_releases(monkeypatch, releases: list[str]) -> None: function test_get_pypi_baseline_version_returns_current_when_published (line 95) | def test_get_pypi_baseline_version_returns_current_when_published(monkey... function test_get_pypi_baseline_version_falls_back_to_previous (line 101) | def test_get_pypi_baseline_version_falls_back_to_previous(monkeypatch): function test_griffe_breakage_removed_attribute_requires_minor_bump (line 107) | def test_griffe_breakage_removed_attribute_requires_minor_bump(tmp_path): function test_griffe_removed_export_from_all_is_breaking (line 138) | def test_griffe_removed_export_from_all_is_breaking(tmp_path): function test_removal_of_deprecated_symbol_does_not_count_as_undeprecated (line 155) | def test_removal_of_deprecated_symbol_does_not_count_as_undeprecated(tmp... function test_removal_with_warn_deprecated_is_not_undeprecated (line 174) | def test_removal_with_warn_deprecated_is_not_undeprecated(tmp_path): function test_removed_public_method_requires_deprecation (line 198) | def test_removed_public_method_requires_deprecation(tmp_path): function test_removed_public_method_with_deprecation_is_not_undeprecated (line 225) | def test_removed_public_method_with_deprecation_is_not_undeprecated(tmp_... function test_missing_all_in_previous_release_skips_breakage_check (line 253) | def test_missing_all_in_previous_release_skips_breakage_check(tmp_path): function test_parse_version_simple (line 270) | def test_parse_version_simple(): function test_parse_version_prerelease (line 277) | def test_parse_version_prerelease(): function test_no_breaks_passes (line 283) | def test_no_breaks_passes(): function test_minor_bump_with_breaks_passes (line 288) | def test_minor_bump_with_breaks_passes(): function test_major_bump_with_breaks_passes (line 294) | def test_major_bump_with_breaks_passes(): function test_patch_bump_with_breaks_fails (line 300) | def test_patch_bump_with_breaks_fails(): function test_same_version_with_breaks_fails (line 306) | def test_same_version_with_breaks_fails(): function test_prerelease_versions (line 311) | def test_prerelease_versions(): function test_find_deprecated_symbols_decorator (line 319) | def test_find_deprecated_symbols_decorator(tmp_path): function test_find_deprecated_symbols_warn_deprecated (line 338) | def test_find_deprecated_symbols_warn_deprecated(tmp_path): function test_find_deprecated_symbols_ignores_syntax_errors (line 349) | def test_find_deprecated_symbols_ignores_syntax_errors(tmp_path): function test_find_deprecated_symbols_records_metadata (line 360) | def test_find_deprecated_symbols_records_metadata(tmp_path): function test_removed_public_method_requires_removal_target_to_be_reached (line 385) | def test_removed_public_method_requires_removal_target_to_be_reached(tmp... function test_removed_public_method_requires_five_minor_release_runway (line 415) | def test_removed_public_method_requires_five_minor_release_runway(tmp_pa... function test_workspace_removed_export_is_breaking (line 445) | def test_workspace_removed_export_is_breaking(tmp_path): function test_unresolved_alias_exports_do_not_crash_breakage_detection (line 469) | def test_unresolved_alias_exports_do_not_crash_breakage_detection(tmp_pa... function test_is_field_metadata_only_change_description_only (line 517) | def test_is_field_metadata_only_change_description_only(): function test_is_field_metadata_only_change_title_and_description (line 524) | def test_is_field_metadata_only_change_title_and_description(): function test_is_field_metadata_only_change_default_changed (line 531) | def test_is_field_metadata_only_change_default_changed(): function test_is_field_metadata_only_change_not_field (line 538) | def test_is_field_metadata_only_change_not_field(): function test_is_field_metadata_only_change_long_description (line 545) | def test_is_field_metadata_only_change_long_description(): function test_is_field_metadata_only_change_multiline_description_with_quotes (line 558) | def test_is_field_metadata_only_change_multiline_description_with_quotes(): function test_is_field_metadata_only_change_deprecated_bool_only (line 579) | def test_is_field_metadata_only_change_deprecated_bool_only(): function test_is_field_metadata_only_change_added_deprecated_kwarg (line 586) | def test_is_field_metadata_only_change_added_deprecated_kwarg(): function test_is_field_metadata_only_change_json_schema_extra_dict (line 593) | def test_is_field_metadata_only_change_json_schema_extra_dict(): function test_is_field_metadata_only_change_json_schema_extra_function_call (line 604) | def test_is_field_metadata_only_change_json_schema_extra_function_call(): function test_is_field_metadata_only_change_json_schema_extra_with_real_change (line 614) | def test_is_field_metadata_only_change_json_schema_extra_with_real_chang... function test_field_deprecated_change_is_not_breaking (line 624) | def test_field_deprecated_change_is_not_breaking(tmp_path): function test_field_added_deprecated_kwarg_is_not_breaking (line 657) | def test_field_added_deprecated_kwarg_is_not_breaking(tmp_path): function test_field_description_change_is_not_breaking (line 694) | def test_field_description_change_is_not_breaking(tmp_path): function test_field_multiline_description_with_quotes_is_not_breaking (line 727) | def test_field_multiline_description_with_quotes_is_not_breaking(tmp_path): function test_field_json_schema_extra_dict_is_not_breaking (line 789) | def test_field_json_schema_extra_dict_is_not_breaking(tmp_path): function test_was_deprecated_direct_qualified_match (line 843) | def test_was_deprecated_direct_qualified_match(): function test_was_deprecated_top_level_match (line 850) | def test_was_deprecated_top_level_match(): function test_was_deprecated_via_parent_class (line 857) | def test_was_deprecated_via_parent_class(): function test_was_deprecated_returns_false_for_undeprecated (line 865) | def test_was_deprecated_returns_false_for_undeprecated(): function test_was_deprecated_parent_different_member (line 873) | def test_was_deprecated_parent_different_member(): function test_subclass_member_deprecated_on_base_is_not_undeprecated (line 884) | def test_subclass_member_deprecated_on_base_is_not_undeprecated(tmp_path): FILE: tests/cross/test_check_version_bumps.py function _load_prod_module (line 11) | def _load_prod_module(): function _write_version (line 30) | def _write_version(pyproject: Path, version: str) -> None: function _init_repo_with_versions (line 36) | def _init_repo_with_versions(tmp_path: Path, version: str) -> Path: function test_get_release_pr_version_accepts_title_or_branch (line 63) | def test_get_release_pr_version_accepts_title_or_branch(): function test_get_release_pr_version_rejects_mismatched_markers (line 68) | def test_get_release_pr_version_rejects_mismatched_markers(): function test_validate_version_changes_rejects_agent_server_bump_in_non_release_pr (line 77) | def test_validate_version_changes_rejects_agent_server_bump_in_non_relea... function test_validate_version_changes_accepts_matching_release_version (line 101) | def test_validate_version_changes_accepts_matching_release_version(): function test_find_version_changes_detects_agent_server_package (line 121) | def test_find_version_changes_detects_agent_server_package(tmp_path: Path): FILE: tests/cross/test_conversation_restore_behavior.py class DifferentAgent (line 57) | class DifferentAgent(Agent): class RestoreLifecycle (line 62) | class RestoreLifecycle: method create_conversation (line 69) | def create_conversation(self, agent: Agent) -> LocalConversation: method send_and_run (line 78) | def send_and_run(self, conversation: LocalConversation, message: str) ... method run_initial_session (line 82) | def run_initial_session(self, agent: Agent) -> dict[str, Any]: method restore (line 96) | def restore(self, agent: Agent) -> LocalConversation: function _agent (line 101) | def _agent( function _tool_call_response (line 153) | def _tool_call_response( function test_conversation_restore_lifecycle_happy_path (line 189) | def test_conversation_restore_lifecycle_happy_path(mock_completion): function test_conversation_restore_preserves_security_risk_and_summary (line 251) | def test_conversation_restore_preserves_security_risk_and_summary(mock_c... function test_conversation_restore_fails_when_removing_tools (line 355) | def test_conversation_restore_fails_when_removing_tools(mock_completion): function test_conversation_restore_succeeds_when_adding_tools (line 399) | def test_conversation_restore_succeeds_when_adding_tools(mock_completion): function test_conversation_restore_fails_when_agent_class_changes (line 441) | def test_conversation_restore_fails_when_agent_class_changes(mock_comple... function test_conversation_restore_fails_when_default_tools_removed (line 484) | def test_conversation_restore_fails_when_default_tools_removed(mock_comp... function test_conversation_restore_succeeds_when_default_tools_added (line 530) | def test_conversation_restore_succeeds_when_default_tools_added(mock_com... function test_conversation_restore_succeeds_when_llm_condenser_and_skills_change (line 574) | def test_conversation_restore_succeeds_when_llm_condenser_and_skills_cha... function test_restore_reasoning_effort_none_strips_temperature (line 633) | def test_restore_reasoning_effort_none_strips_temperature(mock_completion): FILE: tests/cross/test_event_loss_repro.py function server_env_for_repro (line 32) | def server_env_for_repro(tmp_path: Path, monkeypatch: pytest.MonkeyPatch): function test_event_loss_race_condition_with_ws_delay (line 89) | def test_event_loss_race_condition_with_ws_delay( FILE: tests/cross/test_hello_world.py class TestHelloWorld (line 40) | class TestHelloWorld: method setup_method (line 43) | def setup_method(self): method teardown_method (line 58) | def teardown_method(self): method conversation_callback (line 64) | def conversation_callback(self, event: Event): method create_real_llm_responses_from_fixtures (line 75) | def create_real_llm_responses_from_fixtures(self, fncall_raw_logs): method create_mock_llm_responses (line 102) | def create_mock_llm_responses(self): method test_hello_world_with_real_llm_data (line 157) | def test_hello_world_with_real_llm_data(self, mock_completion, fncall_... method test_llm_completion_logging_fidelity (line 281) | def test_llm_completion_logging_fidelity(self, mock_completion, fncall... method _validate_completion_data (line 357) | def _validate_completion_data(self, logged_data, context): method test_non_function_call (line 396) | def test_non_function_call(self): FILE: tests/cross/test_issue_duplicate_scripts.py function load_module (line 18) | def load_module(script_name: str): function make_agent_message (line 29) | def make_agent_message(text: str) -> dict: function iso_timestamp (line 37) | def iso_timestamp(value: datetime) -> str: function test_list_open_issues_filters_by_duplicate_candidate_label (line 41) | def test_list_open_issues_filters_by_duplicate_candidate_label(monkeypat... function test_list_issue_comments_paginates (line 70) | def test_list_issue_comments_paginates(monkeypatch): function test_list_comment_reactions_paginates (line 92) | def test_list_comment_reactions_paginates(monkeypatch): function test_list_helpers_raise_on_non_list_payloads (line 114) | def test_list_helpers_raise_on_non_list_payloads(monkeypatch): function test_ensure_page_limit_raises (line 133) | def test_ensure_page_limit_raises(): function test_parse_timestamp_reports_invalid_values (line 140) | def test_parse_timestamp_reports_invalid_values(): function test_parse_timestamp_accepts_microseconds (line 147) | def test_parse_timestamp_accepts_microseconds(): function test_github_headers_requires_token (line 155) | def test_github_headers_requires_token(monkeypatch): function test_auto_close_parse_args_rejects_invalid_repository (line 166) | def test_auto_close_parse_args_rejects_invalid_repository(monkeypatch): function test_auto_close_request_json_reports_urlerror (line 181) | def test_auto_close_request_json_reports_urlerror(monkeypatch): function test_auto_close_request_json_reports_httperror (line 197) | def test_auto_close_request_json_reports_httperror(monkeypatch): function test_auto_close_request_json_reports_invalid_json (line 218) | def test_auto_close_request_json_reports_invalid_json(monkeypatch): function test_is_non_bot_comment_filters_github_bots (line 240) | def test_is_non_bot_comment_filters_github_bots(): function test_has_reaction_from_user_ignores_missing_user_ids (line 268) | def test_has_reaction_from_user_ignores_missing_user_ids(): function test_is_non_bot_comment_requires_string_login (line 281) | def test_is_non_bot_comment_requires_string_login(): function test_extract_duplicate_metadata_and_veto_helpers (line 287) | def test_extract_duplicate_metadata_and_veto_helpers(): function test_issue_has_label_handles_string_and_object_labels (line 303) | def test_issue_has_label_handles_string_and_object_labels(): function test_find_latest_auto_close_comment_prefers_newest_timestamp (line 318) | def test_find_latest_auto_close_comment_prefers_newest_timestamp(): function test_find_latest_auto_close_comment_returns_latest_candidate (line 339) | def test_find_latest_auto_close_comment_returns_latest_candidate(): function test_close_issue_propagates_comment_failure (line 366) | def test_close_issue_propagates_comment_failure(monkeypatch): function test_dry_run_helpers_skip_api_calls (line 393) | def test_dry_run_helpers_skip_api_calls(monkeypatch): function test_close_issue_as_duplicate_removes_label_on_success (line 420) | def test_close_issue_as_duplicate_removes_label_on_success(monkeypatch): function test_keep_open_due_to_newer_comments_removes_candidate_label (line 446) | def test_keep_open_due_to_newer_comments_removes_candidate_label(monkeyp... function test_auto_close_main_honors_author_veto (line 474) | def test_auto_close_main_honors_author_veto(monkeypatch, capsys): function test_auto_close_main_closes_old_duplicate (line 551) | def test_auto_close_main_closes_old_duplicate(monkeypatch, capsys): function test_auto_close_main_continues_after_close_failure (line 613) | def test_auto_close_main_continues_after_close_failure(monkeypatch, caps... function test_auto_close_main_skips_malformed_issue_data (line 694) | def test_auto_close_main_skips_malformed_issue_data(monkeypatch, capsys): function test_auto_close_main_skips_malformed_duplicate_comment (line 715) | def test_auto_close_main_skips_malformed_duplicate_comment(monkeypatch, ... function test_auto_close_main_skips_non_numeric_issue_number (line 755) | def test_auto_close_main_skips_non_numeric_issue_number(monkeypatch, cap... function test_auto_close_main_skips_non_numeric_comment_id (line 780) | def test_auto_close_main_skips_non_numeric_comment_id(monkeypatch, capsys): function test_auto_close_main_removes_label_when_newer_comment_exists (line 821) | def test_auto_close_main_removes_label_when_newer_comment_exists(monkeyp... function test_auto_close_main_ignores_newer_bot_comments (line 885) | def test_auto_close_main_ignores_newer_bot_comments(monkeypatch, capsys): function test_auto_close_main_ignores_newer_deleted_user_comments (line 961) | def test_auto_close_main_ignores_newer_deleted_user_comments(monkeypatch... function test_auto_close_main_skips_recent_duplicate_comments (line 1020) | def test_auto_close_main_skips_recent_duplicate_comments(monkeypatch, ca... function test_auto_close_main_ignores_newer_comments_with_invalid_timestamps (line 1065) | def test_auto_close_main_ignores_newer_comments_with_invalid_timestamps( function test_parse_agent_json_handles_single_line_fenced_json (line 1126) | def test_parse_agent_json_handles_single_line_fenced_json(): function test_parse_agent_json_handles_multiline_fenced_json (line 1132) | def test_parse_agent_json_handles_multiline_fenced_json(): function test_parse_agent_json_handles_plain_json (line 1138) | def test_parse_agent_json_handles_plain_json(): function test_parse_agent_json_rejects_invalid_json (line 1144) | def test_parse_agent_json_rejects_invalid_json(): function test_parse_agent_json_rejects_trailing_content (line 1151) | def test_parse_agent_json_rejects_trailing_content(): function test_extract_first_item_handles_list_payload (line 1158) | def test_extract_first_item_handles_list_payload(): function test_extract_first_item_handles_dict_without_items (line 1166) | def test_extract_first_item_handles_dict_without_items(): function test_extract_last_agent_text_raises_on_no_agent_messages (line 1174) | def test_extract_last_agent_text_raises_on_no_agent_messages(): function test_as_bool_handles_common_inputs (line 1189) | def test_as_bool_handles_common_inputs(): function test_extract_first_item_handles_invalid_types (line 1198) | def test_extract_first_item_handles_invalid_types(): function test_extract_last_agent_text_returns_full_final_agent_message (line 1205) | def test_extract_last_agent_text_returns_full_final_agent_message(): function test_extract_last_agent_text_raises_on_empty_events (line 1228) | def test_extract_last_agent_text_raises_on_empty_events(): function test_extract_last_agent_text_raises_on_malformed_last_agent_message (line 1235) | def test_extract_last_agent_text_raises_on_malformed_last_agent_message(): function test_extract_last_agent_text_raises_on_last_agent_message_without_text (line 1251) | def test_extract_last_agent_text_raises_on_last_agent_message_without_te... function test_build_prompt_includes_all_sections (line 1269) | def test_build_prompt_includes_all_sections(): function test_build_prompt_handles_missing_fields (line 1292) | def test_build_prompt_handles_missing_fields(): function test_openhands_headers_requires_api_key (line 1302) | def test_openhands_headers_requires_api_key(monkeypatch): function test_app_conversation_helpers_preserve_raw_ids (line 1313) | def test_app_conversation_helpers_preserve_raw_ids(monkeypatch): function test_normalize_result_promotes_actionable_duplicates (line 1360) | def test_normalize_result_promotes_actionable_duplicates(): function test_issue_duplicate_request_json_reports_urlerror (line 1387) | def test_issue_duplicate_request_json_reports_urlerror(monkeypatch): function test_issue_duplicate_request_json_reports_httperror (line 1402) | def test_issue_duplicate_request_json_reports_httperror(monkeypatch): function test_fetch_issue_rejects_invalid_repository_format (line 1425) | def test_fetch_issue_rejects_invalid_repository_format(): function test_fetch_app_server_events_ignores_non_list_items (line 1432) | def test_fetch_app_server_events_ignores_non_list_items(monkeypatch): function test_fetch_agent_server_events_ignores_non_list_items (line 1443) | def test_fetch_agent_server_events_ignores_non_list_items(monkeypatch): function test_normalize_result_sanitizes_invalid_edge_cases (line 1456) | def test_normalize_result_sanitizes_invalid_edge_cases(): function test_normalize_result_disables_invalid_auto_close_states (line 1483) | def test_normalize_result_disables_invalid_auto_close_states(): function test_extract_agent_server_url_returns_runtime_prefix (line 1523) | def test_extract_agent_server_url_returns_runtime_prefix(): function test_validate_event_search_results_raises_when_limit_is_hit (line 1540) | def test_validate_event_search_results_raises_when_limit_is_hit(): function test_normalize_result_lowercases_classification (line 1547) | def test_normalize_result_lowercases_classification(): function test_request_json_reports_invalid_json (line 1567) | def test_request_json_reports_invalid_json(monkeypatch): function test_poll_start_task_retries_after_empty_payload (line 1590) | def test_poll_start_task_retries_after_empty_payload(monkeypatch): function test_poll_start_task_times_out (line 1613) | def test_poll_start_task_times_out(monkeypatch): function test_poll_start_task_raises_on_failed_status (line 1633) | def test_poll_start_task_raises_on_failed_status(monkeypatch): function test_poll_conversation_retries_after_empty_items (line 1663) | def test_poll_conversation_retries_after_empty_items(monkeypatch): function test_poll_conversation_times_out (line 1693) | def test_poll_conversation_times_out(monkeypatch): function test_poll_conversation_raises_on_failed_status (line 1715) | def test_poll_conversation_raises_on_failed_status(monkeypatch): function test_issue_duplicate_main_rejects_pull_requests (line 1750) | def test_issue_duplicate_main_rejects_pull_requests(monkeypatch, tmp_path): function test_issue_duplicate_main_waits_for_start_task_and_writes_output (line 1779) | def test_issue_duplicate_main_waits_for_start_task_and_writes_output( function test_issue_duplicate_main_reports_output_write_failures (line 1853) | def test_issue_duplicate_main_reports_output_write_failures(monkeypatch,... function test_issue_duplicate_main_rejects_non_string_session_api_key (line 1921) | def test_issue_duplicate_main_rejects_non_string_session_api_key(monkeyp... function test_issue_duplicate_main_prefers_agent_final_response (line 1964) | def test_issue_duplicate_main_prefers_agent_final_response(monkeypatch, ... function test_issue_duplicate_main_falls_back_to_agent_server_events (line 2045) | def test_issue_duplicate_main_falls_back_to_agent_server_events(monkeypa... function test_issue_duplicate_main_falls_back_after_final_response_error (line 2125) | def test_issue_duplicate_main_falls_back_after_final_response_error( function test_issue_duplicate_main_reports_missing_start_task_id (line 2206) | def test_issue_duplicate_main_reports_missing_start_task_id(monkeypatch,... function test_issue_duplicate_main_redacts_missing_ready_task_fields (line 2229) | def test_issue_duplicate_main_redacts_missing_ready_task_fields(monkeypa... FILE: tests/cross/test_pr_review_trace.py function test_span_context_requires_json_mode_for_serialization (line 10) | def test_span_context_requires_json_mode_for_serialization(): FILE: tests/cross/test_registry_directories.py class DummyAgent (line 27) | class DummyAgent(AgentBase): method __init__ (line 30) | def __init__(self): method init_state (line 36) | def init_state( method step (line 44) | def step( function test_agent (line 54) | def test_agent(): function register_tools (line 60) | def register_tools(): function test_resolve_tool_with_conversation_directories (line 73) | def test_resolve_tool_with_conversation_directories(test_agent): FILE: tests/cross/test_registry_qualnames.py function test_get_tool_module_qualnames_with_class (line 13) | def test_get_tool_module_qualnames_with_class(): function test_get_tool_module_qualnames_with_callable (line 28) | def test_get_tool_module_qualnames_with_callable(): function test_get_tool_module_qualnames_after_import (line 46) | def test_get_tool_module_qualnames_after_import(): function test_get_tool_module_qualnames_returns_copy (line 65) | def test_get_tool_module_qualnames_returns_copy(): FILE: tests/cross/test_remote_conversation_live_server.py function live_server_env (line 55) | def live_server_env( function test_health_endpoints_return_ok_json (line 165) | def test_health_endpoints_return_ok_json(server_env): function server_env (line 174) | def server_env(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> Gener... function patched_llm (line 180) | def patched_llm(monkeypatch: pytest.MonkeyPatch) -> None: function test_preloaded_custom_tool_resolves_in_live_server (line 228) | def test_preloaded_custom_tool_resolves_in_live_server( function test_websocket_attach_wait_does_not_block_ready_endpoint (line 350) | def test_websocket_attach_wait_does_not_block_ready_endpoint(server_env): function test_remote_conversation_over_real_server (line 455) | def test_remote_conversation_over_real_server(server_env, patched_llm): function test_bash_command_endpoint_with_live_server (line 583) | def test_bash_command_endpoint_with_live_server(server_env): function test_file_upload_endpoint_with_live_server (line 628) | def test_file_upload_endpoint_with_live_server(server_env, tmp_path: Path): function test_conversation_stats_with_live_server (line 678) | def test_conversation_stats_with_live_server( function test_events_not_lost_during_client_disconnection (line 821) | def test_events_not_lost_during_client_disconnection( function test_post_run_reconcile_needed_under_ws_callback_lag (line 989) | def test_post_run_reconcile_needed_under_ws_callback_lag( function test_security_risk_field_with_live_server (line 1135) | def test_security_risk_field_with_live_server( function test_hook_config_sent_to_server (line 1281) | def test_hook_config_sent_to_server( function test_subagent_definitions_forwarded_to_server (line 1457) | def test_subagent_definitions_forwarded_to_server(server_env, patched_llm): function test_agent_final_response_endpoint (line 1536) | def test_agent_final_response_endpoint(server_env, monkeypatch: pytest.M... function test_server_info_exposes_usable_tools (line 1645) | def test_server_info_exposes_usable_tools(server_env): function test_remote_state_exposes_invoked_skills (line 1655) | def test_remote_state_exposes_invoked_skills( function test_settings_and_secrets_api_with_live_server (line 1780) | def test_settings_and_secrets_api_with_live_server(server_env): FILE: tests/cross/test_resolve_model_config.py class LLMConfig (line 24) | class LLMConfig(BaseModel): method model_must_start_with_litellm_proxy (line 36) | def model_must_start_with_litellm_proxy(cls, v: str) -> str: method temperature_in_range (line 43) | def temperature_in_range(cls, v: float | None) -> float | None: method top_p_in_range (line 50) | def top_p_in_range(cls, v: float | None) -> float | None: method reasoning_effort_valid (line 57) | def reasoning_effort_valid(cls, v: str | None) -> str | None: class EvalModelConfig (line 66) | class EvalModelConfig(BaseModel): method id_not_empty (line 75) | def id_not_empty(cls, v: str) -> str: method display_name_not_empty (line 82) | def display_name_not_empty(cls, v: str) -> str: class EvalModelsRegistry (line 88) | class EvalModelsRegistry(BaseModel): method id_matches_key (line 94) | def id_matches_key(self) -> "EvalModelsRegistry": function test_find_models_by_id_single_model (line 103) | def test_find_models_by_id_single_model(): function test_find_models_by_id_multiple_models (line 119) | def test_find_models_by_id_multiple_models(): function test_find_models_by_id_preserves_order (line 136) | def test_find_models_by_id_preserves_order(): function test_find_models_by_id_missing_model_exits (line 152) | def test_find_models_by_id_missing_model_exits(): function test_find_models_by_id_empty_list (line 167) | def test_find_models_by_id_empty_list(): function test_find_models_by_id_preserves_full_config (line 180) | def test_find_models_by_id_preserves_full_config(): function test_all_models_valid_with_pydantic (line 206) | def test_all_models_valid_with_pydantic(): function test_find_all_models (line 222) | def test_find_all_models(): function test_gpt_5_2_high_reasoning_config (line 232) | def test_gpt_5_2_high_reasoning_config(): function test_gpt_oss_20b_config (line 242) | def test_gpt_oss_20b_config(): function test_gpt_5_3_codex_config (line 251) | def test_gpt_5_3_codex_config(): function test_glm_5_config (line 260) | def test_glm_5_config(): function test_glm_5_1_config (line 270) | def test_glm_5_1_config(): class TestTestModel (line 283) | class TestTestModel: method test_successful_response (line 286) | def test_successful_response(self): method test_empty_response (line 302) | def test_empty_response(self): method test_thinking_model_success (line 320) | def test_thinking_model_success(self): method test_model_without_reasoning_content_attribute (line 339) | def test_model_without_reasoning_content_attribute(self): method test_timeout_error (line 362) | def test_timeout_error(self): method test_connection_error (line 383) | def test_connection_error(self): method test_model_not_found_error (line 404) | def test_model_not_found_error(self): method test_passes_llm_config_params (line 425) | def test_passes_llm_config_params(self): class TestRunPreflightCheck (line 447) | class TestRunPreflightCheck: method test_skip_when_no_api_key (line 450) | def test_skip_when_no_api_key(self): method test_skip_when_skip_preflight_true (line 459) | def test_skip_when_skip_preflight_true(self): method test_all_models_pass (line 470) | def test_all_models_pass(self): method test_any_model_fails (line 491) | def test_any_model_fails(self): function test_models_importable_without_litellm (line 518) | def test_models_importable_without_litellm(): function test_gpt_5_4_config (line 561) | def test_gpt_5_4_config(): function test_nemotron_3_super_120b_a12b_config (line 571) | def test_nemotron_3_super_120b_a12b_config(): function test_converse_nemotron_super_3_120b_config (line 584) | def test_converse_nemotron_super_3_120b_config(): function test_qwen3_6_plus_config (line 596) | def test_qwen3_6_plus_config(): function test_trinity_large_thinking_config (line 606) | def test_trinity_large_thinking_config(): function test_claude_opus_4_7_config (line 617) | def test_claude_opus_4_7_config(): function test_kimi_k2_6_config (line 626) | def test_kimi_k2_6_config(): function test_gpt_5_5_config (line 636) | def test_gpt_5_5_config(): function test_deepseek_v4_pro_config (line 646) | def test_deepseek_v4_pro_config(): function test_deepseek_v4_flash_config (line 655) | def test_deepseek_v4_flash_config(): FILE: tests/cross/test_stuck_detector.py function test_history_too_short (line 28) | def test_history_too_short(): class _SpySequence (line 79) | class _SpySequence: method __init__ (line 80) | def __init__(self, items): method __len__ (line 84) | def __len__(self): method __getitem__ (line 87) | def __getitem__(self, idx): class _SpyState (line 94) | class _SpyState: method __init__ (line 95) | def __init__(self, events): function test_is_stuck_uses_only_recent_event_window (line 99) | def test_is_stuck_uses_only_recent_event_window(): function test_is_stuck_without_recent_user_message_still_detects_loop (line 172) | def test_is_stuck_without_recent_user_message_still_detects_loop(): function test_is_stuck_with_fewer_than_20_events_still_detects_loop (line 223) | def test_is_stuck_with_fewer_than_20_events_still_detects_loop(): function test_repeating_action_observation_not_stuck_less_than_4_repeats (line 270) | def test_repeating_action_observation_not_stuck_less_than_4_repeats(): function test_repeating_action_observation_stuck (line 321) | def test_repeating_action_observation_stuck(): function test_repeating_action_error_stuck (line 372) | def test_repeating_action_error_stuck(): function test_agent_monologue_stuck (line 431) | def test_agent_monologue_stuck(): function test_not_stuck_with_different_actions (line 461) | def test_not_stuck_with_different_actions(): function test_reset_after_user_message (line 515) | def test_reset_after_user_message(): FILE: tests/cross/test_stuck_detector_config.py function test_custom_action_observation_threshold (line 14) | def test_custom_action_observation_threshold(): function test_mixed_custom_thresholds (line 74) | def test_mixed_custom_thresholds(): FILE: tests/cross/test_todo_scanner.py function test_scan_python_file_with_todos (line 22) | def test_scan_python_file_with_todos(): function test_scan_typescript_file (line 47) | def test_scan_typescript_file(): function test_scan_java_file (line 67) | def test_scan_java_file(): function test_scan_rust_file (line 89) | def test_scan_rust_file(): function test_scan_unsupported_file_extension (line 108) | def test_scan_unsupported_file_extension(): function test_scan_all_todos (line 123) | def test_scan_all_todos(): function test_scan_directory (line 146) | def test_scan_directory(): function test_todo_with_continuation_lines (line 171) | def test_todo_with_continuation_lines(): function test_todo_without_description (line 197) | def test_todo_without_description(): function test_empty_file (line 219) | def test_empty_file(): function test_custom_todo_identifier (line 232) | def test_custom_todo_identifier(): function test_custom_identifier_with_special_chars (line 255) | def test_custom_identifier_with_special_chars(): FILE: tests/cross/test_validate_sdk_ref.py function _load_prod_module (line 10) | def _load_prod_module(): function test_validate_sdk_ref_accepts_common_branch_names_when_unreleased_refs_allowed (line 27) | def test_validate_sdk_ref_accepts_common_branch_names_when_unreleased_re... function test_validate_sdk_ref_accepts_commit_shas_when_unreleased_refs_allowed (line 39) | def test_validate_sdk_ref_accepts_commit_shas_when_unreleased_refs_allow... function test_validate_sdk_ref_rejects_shell_metacharacters_when_unreleased_refs_allowed (line 50) | def test_validate_sdk_ref_rejects_shell_metacharacters_when_unreleased_r... function test_validate_branch_name_rejects_invalid_git_branch_syntax (line 59) | def test_validate_branch_name_rejects_invalid_git_branch_syntax(): FILE: tests/examples/test_examples.py function _discover_examples (line 62) | def _discover_examples() -> list[Path]: function _iter_examples (line 76) | def _iter_examples() -> Iterable[Path]: function _normalize_path (line 85) | def _normalize_path(path: Path) -> str: function test_directory_example_is_discovered (line 92) | def test_directory_example_is_discovered() -> None: function test_example_scripts (line 103) | def test_example_scripts( FILE: tests/fixtures/llm_data/data_generator.py function get_output_dir (line 32) | def get_output_dir(output_dir: Path | None = None) -> Path: function create_llm (line 39) | def create_llm( function create_tools (line 59) | def create_tools(working_dir: str | None = None) -> list[Tool]: function run_conversation (line 69) | def run_conversation( function generate_test_data (line 114) | def generate_test_data( function copy_log_files (line 144) | def copy_log_files(output_dir: Path): function validate_message_files (line 164) | def validate_message_files(output_dir: Path) -> bool: function validate_log_directories (line 191) | def validate_log_directories(output_dir: Path) -> bool: function validate_generated_data (line 211) | def validate_generated_data(output_dir: Path) -> bool: function generate_all_test_data (line 222) | def generate_all_test_data( function main (line 264) | def main(): FILE: tests/integration/api_compliance/base.py function get_minimal_tool_definitions (line 18) | def get_minimal_tool_definitions() -> "Sequence[ToolDefinition[Any, Any]]": class BaseAPIComplianceTest (line 56) | class BaseAPIComplianceTest(ABC): method pattern_name (line 71) | def pattern_name(self) -> str: method pattern_description (line 77) | def pattern_description(self) -> str: method build_malformed_messages (line 82) | def build_malformed_messages(self) -> list[Message]: method needs_tools (line 90) | def needs_tools(self) -> bool: method get_tool_definitions (line 98) | def get_tool_definitions(self) -> "Sequence[ToolDefinition[Any, Any]]": method run_test (line 105) | def run_test( method _extract_provider (line 188) | def _extract_provider(self, model: str) -> str: function create_test_llm (line 212) | def create_test_llm(llm_config: dict[str, Any]) -> LLM: FILE: tests/integration/api_compliance/result.py class APIResponse (line 9) | class APIResponse(StrEnum): class ComplianceTestResult (line 25) | class ComplianceTestResult(BaseModel): class PatternResults (line 46) | class PatternResults(BaseModel): method add_result (line 53) | def add_result(self, result: ComplianceTestResult) -> None: method rejected_count (line 57) | def rejected_count(self) -> int: method accepted_count (line 61) | def accepted_count(self) -> int: class ComplianceReport (line 65) | class ComplianceReport(BaseModel): method total_tests (line 78) | def total_tests(self) -> int: method total_rejected (line 82) | def total_rejected(self) -> int: method total_accepted (line 86) | def total_accepted(self) -> int: FILE: tests/integration/api_compliance/run_compliance.py function load_compliance_tests (line 66) | def load_compliance_tests(patterns: list[str] | None = None) -> list[tup... function run_single_test (line 108) | def run_single_test( function run_compliance_tests (line 141) | def run_compliance_tests( function save_report (line 230) | def save_report(report: ComplianceReport, output_dir: str) -> str: function generate_markdown_report (line 285) | def generate_markdown_report(report: ComplianceReport) -> str: function main (line 382) | def main(): FILE: tests/integration/base.py function get_tools_for_preset (line 35) | def get_tools_for_preset( class SkipTest (line 69) | class SkipTest(Exception): class TestResult (line 80) | class TestResult(BaseModel): class BaseIntegrationTest (line 88) | class BaseIntegrationTest(ABC): method __init__ (line 105) | def __init__( method conversation_callback (line 161) | def conversation_callback(self, event: Event): method run_integration_test (line 174) | def run_integration_test(self) -> TestResult: method run_instructions (line 239) | def run_instructions(self, conversation: LocalConversation) -> None: method instruction_message (line 245) | def instruction_message(self) -> Message: method enable_browser (line 250) | def enable_browser(self) -> bool: method tools (line 259) | def tools(self) -> list[Tool]: method condenser (line 273) | def condenser(self) -> CondenserBase | None: method max_iteration_per_run (line 282) | def max_iteration_per_run(self) -> int: method setup (line 290) | def setup(self) -> None: method skip_if_model_matches (line 299) | def skip_if_model_matches(self, pattern: str | list[str], reason: str)... method create_llm_copy (line 320) | def create_llm_copy(self, usage_id: str) -> LLM: method verify_result (line 335) | def verify_result(self) -> TestResult: method add_judge_usage (line 348) | def add_judge_usage( method teardown (line 387) | def teardown(self): FILE: tests/integration/behavior_utils.py function find_tool_calls (line 19) | def find_tool_calls(collected_events: list[Event], tool_name: str) -> li... function find_file_editing_operations (line 40) | def find_file_editing_operations(collected_events: list[Event]) -> list[... function find_file_operations (line 71) | def find_file_operations( function check_bash_command_used (line 100) | def check_bash_command_used( function get_conversation_summary (line 126) | def get_conversation_summary( function _matches_pattern (line 179) | def _matches_pattern(path: str, pattern: str) -> bool: function verify_all_actions_have_summary (line 184) | def verify_all_actions_have_summary(collected_events: list[Event]) -> tu... FILE: tests/integration/early_stopper.py class EarlyStopResult (line 20) | class EarlyStopResult(BaseModel): class EarlyStopperBase (line 27) | class EarlyStopperBase(ABC): method check (line 37) | def check(self, events: list[Event]) -> EarlyStopResult: class FileEditPruner (line 49) | class FileEditPruner(EarlyStopperBase): method __init__ (line 56) | def __init__(self, forbidden_commands: list[str] | None = None): method check (line 70) | def check(self, events: list[Event]) -> EarlyStopResult: class BashCommandPruner (line 97) | class BashCommandPruner(EarlyStopperBase): method __init__ (line 103) | def __init__(self, forbidden_patterns: list[str]): method check (line 112) | def check(self, events: list[Event]) -> EarlyStopResult: class CompositeEarlyStopper (line 138) | class CompositeEarlyStopper(EarlyStopperBase): method __init__ (line 144) | def __init__(self, stoppers: list[EarlyStopperBase]): method check (line 148) | def check(self, events: list[Event]) -> EarlyStopResult: FILE: tests/integration/run_infer.py class TestInstance (line 33) | class TestInstance(BaseModel): method required (line 44) | def required(self) -> bool: class EvalOutput (line 49) | class EvalOutput(BaseModel): method required (line 62) | def required(self) -> bool: function load_integration_tests (line 67) | def load_integration_tests() -> list[TestInstance]: function load_test_class (line 102) | def load_test_class(file_path: str) -> type[BaseIntegrationTest]: function process_instance (line 125) | def process_instance( function run_evaluation (line 278) | def run_evaluation( function generate_structured_results (line 322) | def generate_structured_results( function main (line 423) | def main(): FILE: tests/integration/schemas.py function json_serializer (line 11) | def json_serializer(obj): class TokenUsageData (line 18) | class TokenUsageData(BaseModel): method __add__ (line 28) | def __add__(self, other: "TokenUsageData") -> "TokenUsageData": class TestResultData (line 40) | class TestResultData(BaseModel): class TestInstanceResult (line 48) | class TestInstanceResult(BaseModel): class ModelTestResults (line 60) | class ModelTestResults(BaseModel): method from_eval_outputs (line 94) | def from_eval_outputs( class ConsolidatedResults (line 203) | class ConsolidatedResults(BaseModel): method from_model_results (line 221) | def from_model_results( FILE: tests/integration/test_behavior_utils.py function _create_action_event (line 11) | def _create_action_event(tool_name: str, summary: str | None) -> ActionE... function test_verify_all_actions_have_summary_all_present (line 29) | def test_verify_all_actions_have_summary_all_present(): function test_verify_all_actions_have_summary_missing (line 40) | def test_verify_all_actions_have_summary_missing(): function test_verify_all_actions_have_summary_empty_string (line 51) | def test_verify_all_actions_have_summary_empty_string(): function test_verify_all_actions_have_summary_whitespace_only (line 61) | def test_verify_all_actions_have_summary_whitespace_only(): function test_verify_all_actions_have_summary_no_actions (line 71) | def test_verify_all_actions_have_summary_no_actions(): FILE: tests/integration/test_early_stopper.py function create_file_editor_event (line 18) | def create_file_editor_event(command: CommandLiteral, path: str) -> Acti... function create_terminal_event (line 37) | def create_terminal_event(command: str) -> ActionEvent: class TestFileEditPruner (line 56) | class TestFileEditPruner: method test_no_events_returns_no_stop (line 59) | def test_no_events_returns_no_stop(self): method test_view_command_not_blocked (line 66) | def test_view_command_not_blocked(self): method test_create_command_triggers_stop (line 73) | def test_create_command_triggers_stop(self): method test_str_replace_triggers_stop (line 83) | def test_str_replace_triggers_stop(self): method test_custom_forbidden_commands (line 92) | def test_custom_forbidden_commands(self): method test_non_matching_event_not_stopped (line 100) | def test_non_matching_event_not_stopped(self): class TestBashCommandPruner (line 109) | class TestBashCommandPruner: method test_no_events_returns_no_stop (line 112) | def test_no_events_returns_no_stop(self): method test_forbidden_pattern_triggers_stop (line 118) | def test_forbidden_pattern_triggers_stop(self): method test_safe_command_not_stopped (line 127) | def test_safe_command_not_stopped(self): class TestCompositeEarlyStopper (line 135) | class TestCompositeEarlyStopper: method test_empty_stoppers_never_stops (line 138) | def test_empty_stoppers_never_stops(self): method test_stops_on_first_match (line 144) | def test_stops_on_first_match(self): method test_no_match_continues (line 157) | def test_no_match_continues(self): class TestEarlyStopResult (line 168) | class TestEarlyStopResult: method test_default_values (line 171) | def test_default_values(self): method test_with_reason (line 177) | def test_with_reason(self): FILE: tests/integration/test_tool_presets.py function test_get_tools_for_preset_default (line 10) | def test_get_tools_for_preset_default(): function test_get_tools_for_preset_default_with_browser (line 22) | def test_get_tools_for_preset_default_with_browser(): function test_get_tools_for_preset_gemini (line 35) | def test_get_tools_for_preset_gemini(): function test_get_tools_for_preset_gpt5 (line 50) | def test_get_tools_for_preset_gpt5(): function test_get_tools_for_preset_planning (line 62) | def test_get_tools_for_preset_planning(): function test_get_tools_for_preset_invalid (line 76) | def test_get_tools_for_preset_invalid(): function test_tool_preset_type_literal_values (line 83) | def test_tool_preset_type_literal_values(): function test_run_infer_argparse_accepts_all_tool_presets (line 93) | def test_run_infer_argparse_accepts_all_tool_presets(): FILE: tests/integration/tests/a01_unmatched_tool_use.py class UnmatchedToolUseTest (line 29) | class UnmatchedToolUseTest(BaseAPIComplianceTest): method pattern_name (line 33) | def pattern_name(self) -> str: method pattern_description (line 37) | def pattern_description(self) -> str: method build_malformed_messages (line 40) | def build_malformed_messages(self) -> list[Message]: FILE: tests/integration/tests/a02_unmatched_tool_result.py class UnmatchedToolResultTest (line 28) | class UnmatchedToolResultTest(BaseAPIComplianceTest): method pattern_name (line 32) | def pattern_name(self) -> str: method pattern_description (line 36) | def pattern_description(self) -> str: method build_malformed_messages (line 39) | def build_malformed_messages(self) -> list[Message]: FILE: tests/integration/tests/a03_interleaved_user_msg.py class InterleavedUserMessageTest (line 29) | class InterleavedUserMessageTest(BaseAPIComplianceTest): method pattern_name (line 33) | def pattern_name(self) -> str: method pattern_description (line 37) | def pattern_description(self) -> str: method build_malformed_messages (line 40) | def build_malformed_messages(self) -> list[Message]: FILE: tests/integration/tests/a04_interleaved_asst_msg.py class InterleavedAssistantMessageTest (line 28) | class InterleavedAssistantMessageTest(BaseAPIComplianceTest): method pattern_name (line 32) | def pattern_name(self) -> str: method pattern_description (line 36) | def pattern_description(self) -> str: method build_malformed_messages (line 39) | def build_malformed_messages(self) -> list[Message]: FILE: tests/integration/tests/a05_duplicate_tool_call_id.py class DuplicateToolCallIdTest (line 29) | class DuplicateToolCallIdTest(BaseAPIComplianceTest): method pattern_name (line 33) | def pattern_name(self) -> str: method pattern_description (line 37) | def pattern_description(self) -> str: method build_malformed_messages (line 40) | def build_malformed_messages(self) -> list[Message]: FILE: tests/integration/tests/a06_wrong_tool_call_id.py class WrongToolCallIdTest (line 28) | class WrongToolCallIdTest(BaseAPIComplianceTest): method pattern_name (line 32) | def pattern_name(self) -> str: method pattern_description (line 36) | def pattern_description(self) -> str: method build_malformed_messages (line 39) | def build_malformed_messages(self) -> list[Message]: FILE: tests/integration/tests/a07_parallel_missing_result.py class ParallelMissingResultTest (line 28) | class ParallelMissingResultTest(BaseAPIComplianceTest): method pattern_name (line 32) | def pattern_name(self) -> str: method pattern_description (line 36) | def pattern_description(self) -> str: method build_malformed_messages (line 39) | def build_malformed_messages(self) -> list[Message]: FILE: tests/integration/tests/a08_parallel_wrong_order.py class ParallelWrongOrderTest (line 28) | class ParallelWrongOrderTest(BaseAPIComplianceTest): method pattern_name (line 32) | def pattern_name(self) -> str: method pattern_description (line 36) | def pattern_description(self) -> str: method build_malformed_messages (line 39) | def build_malformed_messages(self) -> list[Message]: FILE: tests/integration/tests/b01_no_premature_implementation.py class NoPrematureImplementationTest (line 42) | class NoPrematureImplementationTest(SoftwareAgentSDKBehaviorTest): method get_early_stopper (line 47) | def get_early_stopper(self) -> EarlyStopperBase: method verify_result (line 55) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/b02_no_oververification.py class NoOververificationTest (line 31) | class NoOververificationTest(SoftwareAgentSDKBehaviorTest): method verify_result (line 36) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/b03_no_useless_backward_compatibility.py class NoUselessBackwardCompatibilityTest (line 26) | class NoUselessBackwardCompatibilityTest(SoftwareAgentSDKBehaviorTest): method _collect_run_async_references (line 31) | def _collect_run_async_references(self, repo_dir: Path) -> list[str]: method _async_executor_has_submit (line 57) | def _async_executor_has_submit(self, repo_dir: Path) -> bool: method verify_result (line 76) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/b04_each_tool_call_has_a_concise_explanation.py class EachToolCallHavingExplanation (line 29) | class EachToolCallHavingExplanation(SoftwareAgentSDKBehaviorTest): method verify_result (line 37) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/b05_do_not_create_redundant_files.py class NoRedundantFilesTest (line 26) | class NoRedundantFilesTest(BaseIntegrationTest): method setup (line 32) | def setup(self) -> None: # noqa: D401 method verify_result (line 96) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/c01_thinking_block_condenser.py class FirstToolLoopCondenser (line 35) | class FirstToolLoopCondenser(CondenserBase): method handles_condensation_requests (line 43) | def handles_condensation_requests(self) -> bool: method condense (line 47) | def condense(self, view: View, agent_llm: LLM | None = None) -> View |... class ThinkingBlockCondenserTest (line 99) | class ThinkingBlockCondenserTest(BaseIntegrationTest): method __init__ (line 115) | def __init__(self, *args, **kwargs): method tools (line 124) | def tools(self) -> list[Tool]: method condenser (line 130) | def condenser(self) -> CondenserBase: method max_iteration_per_run (line 135) | def max_iteration_per_run(self) -> int: method setup (line 139) | def setup(self) -> None: method conversation_callback (line 173) | def conversation_callback(self, event): method run_instructions (line 194) | def run_instructions(self, conversation: LocalConversation) -> None: method verify_result (line 239) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/c02_hard_context_reset.py class HardContextResetTest (line 15) | class HardContextResetTest(BaseIntegrationTest): method __init__ (line 27) | def __init__(self, *args, **kwargs): method tools (line 33) | def tools(self) -> list[Tool]: method condenser (line 39) | def condenser(self) -> LLMSummarizingCondenser: method max_iteration_per_run (line 54) | def max_iteration_per_run(self) -> int: method conversation_callback (line 58) | def conversation_callback(self, event): method run_instructions (line 65) | def run_instructions(self, conversation: LocalConversation) -> None: method verify_result (line 108) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/c03_delayed_condensation.py class DelayedCondensationTest (line 24) | class DelayedCondensationTest(BaseIntegrationTest): method __init__ (line 29) | def __init__(self, *args, **kwargs): method tools (line 35) | def tools(self) -> list[Tool]: method condenser (line 41) | def condenser(self) -> LLMSummarizingCondenser: method max_iteration_per_run (line 51) | def max_iteration_per_run(self) -> int: method conversation_callback (line 55) | def conversation_callback(self, event): method run_instructions (line 62) | def run_instructions(self, conversation: LocalConversation) -> None: method verify_result (line 85) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/c04_token_condenser.py class TokenCondenserTest (line 36) | class TokenCondenserTest(BaseIntegrationTest): method __init__ (line 41) | def __init__(self, *args, **kwargs): method tools (line 56) | def tools(self) -> list[Tool]: method condenser (line 64) | def condenser(self) -> LLMSummarizingCondenser: method max_iteration_per_run (line 77) | def max_iteration_per_run(self) -> int: method conversation_callback (line 80) | def conversation_callback(self, event): method setup (line 92) | def setup(self) -> None: method verify_result (line 95) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/c05_size_condenser.py class SizeCondenserTest (line 31) | class SizeCondenserTest(BaseIntegrationTest): method __init__ (line 36) | def __init__(self, *args, **kwargs): method tools (line 51) | def tools(self) -> list[Tool]: method condenser (line 59) | def condenser(self) -> LLMSummarizingCondenser: method max_iteration_per_run (line 72) | def max_iteration_per_run(self) -> int: method conversation_callback (line 75) | def conversation_callback(self, event): method setup (line 86) | def setup(self) -> None: method verify_result (line 89) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/t01_fix_simple_typo.py class TypoFixTest (line 25) | class TypoFixTest(BaseIntegrationTest): method __init__ (line 30) | def __init__(self, *args, **kwargs): method setup (line 34) | def setup(self) -> None: method verify_result (line 43) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/t02_add_bash_hello.py class BashHelloTest (line 15) | class BashHelloTest(BaseIntegrationTest): method __init__ (line 20) | def __init__(self, *args, **kwargs): method setup (line 24) | def setup(self) -> None: method verify_result (line 27) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/t03_jupyter_write_file.py class JupyterWriteFileTest (line 18) | class JupyterWriteFileTest(BaseIntegrationTest): method __init__ (line 23) | def __init__(self, *args, **kwargs): method setup (line 27) | def setup(self) -> None: method verify_result (line 30) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/t04_git_staging.py class GitStagingTest (line 18) | class GitStagingTest(BaseIntegrationTest): method setup (line 23) | def setup(self) -> None: method verify_result (line 59) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/t05_simple_browsing.py class SimpleBrowsingTest (line 92) | class SimpleBrowsingTest(BaseIntegrationTest): method __init__ (line 97) | def __init__(self, *args, **kwargs): method enable_browser (line 102) | def enable_browser(self) -> bool: method setup (line 106) | def setup(self) -> None: method verify_result (line 131) | def verify_result(self) -> TestResult: method teardown (line 174) | def teardown(self): FILE: tests/integration/tests/t06_github_pr_browsing.py class GitHubPRBrowsingTest (line 17) | class GitHubPRBrowsingTest(BaseIntegrationTest): method enable_browser (line 23) | def enable_browser(self) -> bool: method setup (line 27) | def setup(self) -> None: method verify_result (line 30) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/t07_interactive_commands.py class InteractiveCommandsTest (line 31) | class InteractiveCommandsTest(BaseIntegrationTest): method __init__ (line 36) | def __init__(self, *args, **kwargs): method setup (line 40) | def setup(self) -> None: method verify_result (line 55) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/t08_image_file_viewing.py class ImageFileViewingTest (line 22) | class ImageFileViewingTest(BaseIntegrationTest): method __init__ (line 27) | def __init__(self, *args, **kwargs): method setup (line 38) | def setup(self) -> None: method verify_result (line 47) | def verify_result(self) -> TestResult: FILE: tests/integration/tests/t09_invoke_skill.py class InvokeSkillTest (line 85) | class InvokeSkillTest(BaseIntegrationTest): method __init__ (line 90) | def __init__( method _make_skill (line 149) | def _make_skill(self) -> Skill: method tools (line 162) | def tools(self) -> list[Tool]: method setup (line 165) | def setup(self) -> None: method verify_result (line 174) | def verify_result(self) -> TestResult: FILE: tests/integration/utils/behavior_helpers.py function clone_pinned_software_agent_repo (line 26) | def clone_pinned_software_agent_repo(workspace: str) -> Path: function default_behavior_tools (line 89) | def default_behavior_tools(tool_preset: ToolPresetType = "default") -> l... function append_environment_tips (line 103) | def append_environment_tips(body: str) -> str: class SoftwareAgentSDKBehaviorTest (line 110) | class SoftwareAgentSDKBehaviorTest(BaseIntegrationTest): method __init__ (line 115) | def __init__( method tools (line 127) | def tools(self) -> list[Tool]: method get_early_stopper (line 130) | def get_early_stopper(self) -> EarlyStopperBase | None: method setup (line 138) | def setup(self) -> None: method after_workspace_setup (line 144) | def after_workspace_setup(self) -> None: FILE: tests/integration/utils/consolidate_json_results.py function find_json_results (line 18) | def find_json_results(results_dir: str) -> list[Path]: function load_and_validate_results (line 36) | def load_and_validate_results( function extract_matrix_run_suffix (line 69) | def extract_matrix_run_suffix(full_run_suffix: str) -> str | None: function find_artifact_url (line 100) | def find_artifact_url(run_suffix: str, artifacts_dir: str) -> str | None: function consolidate_results (line 134) | def consolidate_results(model_results: list[ModelTestResults]) -> Consol... function save_consolidated_results (line 155) | def save_consolidated_results( function main (line 172) | def main(): FILE: tests/integration/utils/consolidate_results.py function find_result_files (line 19) | def find_result_files(results_dir="all_results"): function extract_success_rate (line 28) | def extract_success_rate(test_report): function process_result_file (line 36) | def process_result_file(filepath): function generate_report (line 55) | def generate_report(results, trigger_text, commit_sha): function determine_trigger_info (line 99) | def determine_trigger_info(event_name, pr_number, manual_reason): function main (line 114) | def main(): FILE: tests/integration/utils/format_costs.py function format_cost (line 8) | def format_cost(value: float) -> str: FILE: tests/integration/utils/generate_markdown_report.py function format_token_usage (line 18) | def format_token_usage(token_usage: TokenUsageData | None) -> str: function format_token_usage_short (line 41) | def format_token_usage_short(token_usage: TokenUsageData | None) -> str: function generate_model_summary_table (line 53) | def generate_model_summary_table(model_results: list[ModelTestResults]) ... function generate_detailed_results (line 80) | def generate_detailed_results(model_results: list[ModelTestResults]) -> ... function generate_markdown_report (line 164) | def generate_markdown_report(consolidated: ConsolidatedResults) -> str: function main (line 228) | def main(): FILE: tests/integration/utils/llm_judge.py class SubmitJudgmentAction (line 19) | class SubmitJudgmentAction(Action): class SubmitJudgmentObservation (line 35) | class SubmitJudgmentObservation(Observation): class SubmitJudgmentExecutor (line 41) | class SubmitJudgmentExecutor( method __call__ (line 46) | def __call__( class SubmitJudgmentTool (line 53) | class SubmitJudgmentTool( method create (line 59) | def create(cls): class JudgmentResult (line 77) | class JudgmentResult(BaseModel): function create_judge_llm (line 89) | def create_judge_llm() -> LLM: function judge_agent_behavior (line 116) | def judge_agent_behavior( FILE: tests/platform_utils.py function symlink_or_skip (line 10) | def symlink_or_skip(source: Path, link_name: Path) -> None: function supports_posix_execute_bits (line 18) | def supports_posix_execute_bits() -> bool: function can_fork_test_process (line 23) | def can_fork_test_process() -> bool: function maybe_mark_forked (line 28) | def maybe_mark_forked[F: Callable[..., object]](test_func: F) -> F: function set_address_space_limit_if_available (line 35) | def set_address_space_limit_if_available(memory_limit: int) -> bool: FILE: tests/sdk/agent/test_acp_agent.py function _make_agent (line 48) | def _make_agent(**kwargs) -> ACPAgent: function _make_state (line 52) | def _make_state(tmp_path) -> ConversationState: class TestACPAgentInstantiation (line 67) | class TestACPAgentInstantiation: method test_creates_with_sentinel_llm (line 68) | def test_creates_with_sentinel_llm(self): method test_creates_with_empty_tools (line 72) | def test_creates_with_empty_tools(self): method test_creates_with_empty_default_tools (line 76) | def test_creates_with_empty_default_tools(self): method test_requires_acp_command (line 80) | def test_requires_acp_command(self): method test_acp_command_stored (line 84) | def test_acp_command_stored(self): method test_acp_args_default_empty (line 88) | def test_acp_args_default_empty(self): method test_acp_env_default_empty (line 92) | def test_acp_env_default_empty(self): method test_get_all_llms_yields_sentinel (line 96) | def test_get_all_llms_yields_sentinel(self): method test_agent_is_frozen (line 102) | def test_agent_is_frozen(self): method test_acp_model_propagated_to_metrics (line 107) | def test_acp_model_propagated_to_metrics(self): method test_acp_model_propagated_to_llm_model (line 116) | def test_acp_model_propagated_to_llm_model(self): method test_sentinel_usage_id_without_acp_model (line 123) | def test_sentinel_usage_id_without_acp_model(self): method test_no_acp_model_keeps_sentinel (line 128) | def test_no_acp_model_keeps_sentinel(self): method test_acp_model_used_in_cost_entries (line 133) | def test_acp_model_used_in_cost_entries(self): class TestACPAgentSerialization (line 145) | class TestACPAgentSerialization: method test_kind_is_acp_agent (line 146) | def test_kind_is_acp_agent(self): method test_roundtrip_serialization (line 151) | def test_roundtrip_serialization(self): method test_acp_env_redacted_by_default (line 166) | def test_acp_env_redacted_by_default(self): method test_acp_env_exposed_with_expose_secrets (line 198) | def test_acp_env_exposed_with_expose_secrets(self): method test_acp_env_serializer_does_not_mutate_in_memory_state (line 215) | def test_acp_env_serializer_does_not_mutate_in_memory_state(self): method test_deserialization_from_dict (line 230) | def test_deserialization_from_dict(self): class TestACPAgentValidation (line 245) | class TestACPAgentValidation: method _init_with_patches (line 248) | def _init_with_patches(self, agent, tmp_path): method test_rejects_mcp_config (line 262) | def test_rejects_mcp_config(self, tmp_path): method test_allows_agent_context_for_prompt_extensions (line 270) | def test_allows_agent_context_for_prompt_extensions(self, tmp_path): method test_allows_agent_context_with_secrets (line 286) | def test_allows_agent_context_with_secrets(self, tmp_path): method test_agent_context_to_acp_prompt_context (line 296) | def test_agent_context_to_acp_prompt_context(self): method test_agent_context_to_acp_prompt_context_returns_none_when_empty (line 326) | def test_agent_context_to_acp_prompt_context_returns_none_when_empty(s... method test_agent_context_to_acp_prompt_context_emits_datetime_by_default (line 331) | def test_agent_context_to_acp_prompt_context_emits_datetime_by_default... method test_agent_context_to_acp_prompt_context_includes_secrets (line 338) | def test_agent_context_to_acp_prompt_context_includes_secrets(self): method test_agent_context_to_acp_prompt_context_includes_legacy_repo_skills (line 364) | def test_agent_context_to_acp_prompt_context_includes_legacy_repo_skil... method test_agent_context_to_acp_prompt_context_lists_legacy_triggered_skills (line 393) | def test_agent_context_to_acp_prompt_context_lists_legacy_triggered_sk... method test_build_acp_prompt_preserves_all_text_blocks (line 414) | def test_build_acp_prompt_preserves_all_text_blocks(self): method test_build_acp_prompt_includes_image_content (line 441) | def test_build_acp_prompt_includes_image_content(self): class TestImageUrlToAcpBlock (line 465) | class TestImageUrlToAcpBlock: method test_data_uri (line 466) | def test_data_uri(self): method test_plain_url (line 472) | def test_plain_url(self): method test_invalid_data_uri_returns_none (line 477) | def test_invalid_data_uri_returns_none(self): method test_real_png_round_trips (line 481) | def test_real_png_round_trips(self): class TestACPAgentInitState (line 515) | class TestACPAgentInitState: method test_init_state_emits_system_prompt_placeholder (line 516) | def test_init_state_emits_system_prompt_placeholder(self, tmp_path): method test_init_state_no_dynamic_context_without_agent_context (line 531) | def test_init_state_no_dynamic_context_without_agent_context(self, tmp... method test_init_state_populates_dynamic_context_from_suffix (line 541) | def test_init_state_populates_dynamic_context_from_suffix(self, tmp_pa... method test_init_state_sets_pending_state_for_new_session (line 554) | def test_init_state_sets_pending_state_for_new_session(self, tmp_path): method test_init_state_sets_installed_for_resumed_session (line 567) | def test_init_state_sets_installed_for_resumed_session(self, tmp_path): method test_init_state_includes_registry_secrets_in_suffix (line 579) | def test_init_state_includes_registry_secrets_in_suffix(self, tmp_path): class TestOpenHandsACPClient (line 607) | class TestOpenHandsACPClient: method test_reset_clears_state (line 608) | def test_reset_clears_state(self): method test_session_update_accumulates_text (line 621) | async def test_session_update_accumulates_text(self): method test_session_update_accumulates_thoughts (line 628) | async def test_session_update_accumulates_thoughts(self): method test_on_token_callback (line 634) | def test_on_token_callback(self): method test_fs_methods_raise (line 648) | async def test_fs_methods_raise(self): method test_terminal_methods_raise (line 656) | async def test_terminal_methods_raise(self): method test_ext_method_returns_empty_dict (line 670) | async def test_ext_method_returns_empty_dict(self): method test_ext_notification_is_noop (line 676) | async def test_ext_notification_is_noop(self): class TestACPActivityHeartbeat (line 686) | class TestACPActivityHeartbeat: method test_reset_clears_on_activity (line 689) | def test_reset_clears_on_activity(self): method test_reset_preserves_last_activity_signal (line 695) | def test_reset_preserves_last_activity_signal(self): method test_tool_call_start_signals_activity (line 703) | async def test_tool_call_start_signals_activity(self): method test_tool_call_progress_signals_activity (line 723) | async def test_tool_call_progress_signals_activity(self): method test_agent_message_chunk_signals_activity (line 757) | async def test_agent_message_chunk_signals_activity(self): method test_activity_signal_is_throttled (line 772) | async def test_activity_signal_is_throttled(self): method test_no_signal_without_callback (line 795) | async def test_no_signal_without_callback(self): method test_activity_callback_error_is_swallowed (line 814) | async def test_activity_callback_error_is_swallowed(self): method test_step_wires_on_activity (line 833) | def test_step_wires_on_activity(self, tmp_path): class TestACPAgentStep (line 891) | class TestACPAgentStep: method _make_conversation_with_message (line 892) | def _make_conversation_with_message(self, tmp_path, text="Hello"): method test_step_emits_finish_action_event (line 913) | def test_step_emits_finish_action_event(self, tmp_path): method _wire_passthrough_mocks (line 942) | def _wire_passthrough_mocks(agent: ACPAgent) -> None: method test_step_sends_skill_catalog_to_acp_server (line 958) | def test_step_sends_skill_catalog_to_acp_server(self, tmp_path): method test_step_sends_legacy_repo_context_to_acp_server (line 1007) | def test_step_sends_legacy_repo_context_to_acp_server(self, tmp_path): method test_step_sends_triggered_skill_content_to_acp_server (line 1060) | def test_step_sends_triggered_skill_content_to_acp_server(self, tmp_pa... method test_step_does_not_re_inject_suffix_on_second_turn (line 1113) | def test_step_does_not_re_inject_suffix_on_second_turn(self, tmp_path): method test_step_suffix_install_state_transitions_to_installed (line 1141) | def test_step_suffix_install_state_transitions_to_installed(self, tmp_... method test_step_with_reasoning_surfaces_via_action_event (line 1165) | def test_step_with_reasoning_surfaces_via_action_event(self, tmp_path): method test_step_sets_finished (line 1191) | def test_step_sets_finished(self, tmp_path): method test_step_no_user_message_finishes (line 1213) | def test_step_no_user_message_finishes(self, tmp_path): method test_step_error_sets_error_status (line 1227) | def test_step_error_sets_error_status(self, tmp_path): method test_step_no_response_text_fallback (line 1250) | def test_step_no_response_text_fallback(self, tmp_path): method test_step_passes_on_token (line 1271) | def test_step_passes_on_token(self, tmp_path): class TestACPAgentCleanup (line 1307) | class TestACPAgentCleanup: method test_close_terminates_process (line 1308) | def test_close_terminates_process(self): method test_close_is_idempotent (line 1320) | def test_close_is_idempotent(self): method test_close_closes_executor (line 1333) | def test_close_closes_executor(self): method test_close_handles_errors_gracefully (line 1344) | def test_close_handles_errors_gracefully(self): class TestFilterJsonrpcLines (line 1362) | class TestFilterJsonrpcLines: method test_passes_jsonrpc_lines (line 1364) | async def test_passes_jsonrpc_lines(self): method test_filters_non_jsonrpc_lines (line 1380) | async def test_filters_non_jsonrpc_lines(self): method test_filters_pretty_printed_json (line 1401) | async def test_filters_pretty_printed_json(self): class TestACPAgentTelemetry (line 1425) | class TestACPAgentTelemetry: method _make_conversation_with_message (line 1426) | def _make_conversation_with_message(self, tmp_path, text="Hello"): method test_get_all_llms_yields_sentinel (line 1447) | def test_get_all_llms_yields_sentinel(self): method _make_step_fixtures (line 1455) | def _make_step_fixtures(self, tmp_path, agent=None, usage=None, cost=N... method test_step_records_token_usage (line 1498) | def test_step_records_token_usage(self, tmp_path): method test_step_handles_no_usage (line 1524) | def test_step_handles_no_usage(self, tmp_path): method test_step_records_cost_from_usage_update (line 1532) | def test_step_records_cost_from_usage_update(self, tmp_path): method test_step_records_incremental_cost (line 1546) | def test_step_records_incremental_cost(self, tmp_path): method test_step_no_cost_when_usage_update_missing (line 1569) | def test_step_no_cost_when_usage_update_missing(self, tmp_path): method test_step_records_partial_metrics_on_usage_timeout (line 1583) | def test_step_records_partial_metrics_on_usage_timeout(self, tmp_path,... method test_step_records_latency (line 1633) | def test_step_records_latency(self, tmp_path): method test_session_update_stores_usage_update (line 1643) | async def test_session_update_stores_usage_update(self): method test_usage_update_updates_context_window (line 1663) | async def test_usage_update_updates_context_window(self): method test_stats_callback_invoked (line 1678) | def test_stats_callback_invoked(self, tmp_path): method test_init_state_sets_bridge_client (line 1689) | def test_init_state_sets_bridge_client(self, tmp_path): method test_reset_preserves_telemetry_state (line 1707) | def test_reset_preserves_telemetry_state(self): class TestACPToolCallAccumulation (line 1736) | class TestACPToolCallAccumulation: method test_session_update_accumulates_tool_call_start (line 1740) | async def test_session_update_accumulates_tool_call_start(self): method test_session_update_merges_tool_call_progress (line 1768) | async def test_session_update_merges_tool_call_progress(self): method test_multiple_tool_calls_accumulated (line 1806) | async def test_multiple_tool_calls_accumulated(self): method test_reset_clears_accumulated_tool_calls (line 1830) | def test_reset_clears_accumulated_tool_calls(self): class TestACPToolCallLiveEmission (line 1849) | class TestACPToolCallLiveEmission: method test_session_update_fires_on_event_live (line 1858) | async def test_session_update_fires_on_event_live(self): method test_session_update_preserves_interleaved_order (line 1901) | async def test_session_update_preserves_interleaved_order(self): method test_session_update_no_on_event_when_unset (line 1996) | async def test_session_update_no_on_event_when_unset(self): method test_on_event_errors_are_swallowed (line 2018) | async def test_on_event_errors_are_swallowed(self): method test_reset_clears_on_event (line 2037) | def test_reset_clears_on_event(self): class TestACPCancelInflightToolCalls (line 2045) | class TestACPCancelInflightToolCalls: method _push_entry (line 2056) | def _push_entry( method test_emits_failed_event_for_pending_entries (line 2071) | def test_emits_failed_event_for_pending_entries(self, tmp_path): method test_skips_already_terminal_entries (line 2087) | def test_skips_already_terminal_entries(self, tmp_path): method test_callback_errors_are_swallowed (line 2102) | def test_callback_errors_are_swallowed(self): method test_noop_when_on_event_unset (line 2120) | def test_noop_when_on_event_unset(self): method test_retry_cancels_pending_events_before_reset (line 2130) | def test_retry_cancels_pending_events_before_reset(self, tmp_path): class TestACPToolCallEmission (line 2224) | class TestACPToolCallEmission: method _make_conversation_with_message (line 2227) | def _make_conversation_with_message(self, tmp_path, text="Hello"): method test_step_emits_tool_call_events_before_message (line 2248) | def test_step_emits_tool_call_events_before_message(self, tmp_path): method test_step_clears_live_callbacks_on_return (line 2312) | def test_step_clears_live_callbacks_on_return(self, tmp_path): method test_step_clears_live_callbacks_on_error (line 2358) | def test_step_clears_live_callbacks_on_error(self, tmp_path): method test_step_emits_no_tool_call_events_when_none (line 2383) | def test_step_emits_no_tool_call_events_when_none(self, tmp_path): method test_tool_call_events_cleared_between_turns (line 2407) | def test_tool_call_events_cleared_between_turns(self, tmp_path): class TestACPAgentAskAgent (line 2453) | class TestACPAgentAskAgent: method test_ask_agent_raises_if_not_initialized (line 2454) | def test_ask_agent_raises_if_not_initialized(self): method test_ask_agent_raises_if_session_id_missing (line 2461) | def test_ask_agent_raises_if_session_id_missing(self): method test_ask_agent_forks_and_prompts (line 2469) | def test_ask_agent_forks_and_prompts(self): method test_ask_agent_records_token_usage (line 2509) | def test_ask_agent_records_token_usage(self): method test_ask_agent_cleans_up_fork_state (line 2561) | def test_ask_agent_cleans_up_fork_state(self): class TestClientForkTextRouting (line 2605) | class TestClientForkTextRouting: method test_fork_text_routed_to_fork_accumulator (line 2607) | async def test_fork_text_routed_to_fork_accumulator(self): method test_main_text_unaffected_by_active_fork (line 2626) | async def test_main_text_unaffected_by_active_fork(self): method test_no_fork_normal_routing (line 2644) | async def test_no_fork_normal_routing(self): class TestSelectAuthMethod (line 2671) | class TestSelectAuthMethod: method _make_auth_method (line 2675) | def _make_auth_method(method_id: str) -> MagicMock: method test_openai_api_key (line 2680) | def test_openai_api_key(self): method test_codex_api_key_preferred_over_openai (line 2688) | def test_codex_api_key_preferred_over_openai(self): method test_chatgpt_preferred_over_api_key (line 2697) | def test_chatgpt_preferred_over_api_key(self, tmp_path): method test_api_key_fallback_when_no_chatgpt_file (line 2711) | def test_api_key_fallback_when_no_chatgpt_file(self, tmp_path): method test_no_matching_credentials (line 2721) | def test_no_matching_credentials(self, tmp_path): method test_chatgpt_auth_file (line 2730) | def test_chatgpt_auth_file(self, tmp_path): method test_empty_auth_methods (line 2739) | def test_empty_auth_methods(self): method test_method_not_in_server_list (line 2742) | def test_method_not_in_server_list(self, tmp_path): class TestMaybeSetSessionModel (line 2755) | class TestMaybeSetSessionModel: method test_codex_agent_uses_protocol_model_override (line 2757) | async def test_codex_agent_uses_protocol_model_override(self): method test_non_codex_agent_skips_protocol_override (line 2766) | async def test_non_codex_agent_skips_protocol_override(self): method test_missing_model_skips_protocol_override (line 2777) | async def test_missing_model_skips_protocol_override(self): class TestACPSessionMode (line 2788) | class TestACPSessionMode: method test_default_is_none (line 2789) | def test_default_is_none(self): method test_can_set_explicit_mode (line 2793) | def test_can_set_explicit_mode(self): method test_serialization_roundtrip (line 2797) | def test_serialization_roundtrip(self): class TestACPPromptRetry (line 2813) | class TestACPPromptRetry: method _make_conversation_with_message (line 2816) | def _make_conversation_with_message(self, tmp_path, text="Hello"): method test_retry_on_connection_error_then_success (line 2837) | def test_retry_on_connection_error_then_success(self, tmp_path): method test_no_retry_on_non_connection_error (line 2874) | def test_no_retry_on_non_connection_error(self, tmp_path): method test_no_retry_on_timeout (line 2902) | def test_no_retry_on_timeout(self, tmp_path): method test_max_retries_exceeded (line 2928) | def test_max_retries_exceeded(self, tmp_path): method test_retry_on_acp_server_error_then_success (line 2957) | def test_retry_on_acp_server_error_then_success(self, tmp_path): method test_no_retry_on_non_retriable_acp_error (line 2995) | def test_no_retry_on_non_retriable_acp_error(self, tmp_path): method test_max_retries_exceeded_acp_server_error (line 3025) | def test_max_retries_exceeded_acp_server_error(self, tmp_path): class TestGeminiSessionModel (line 3063) | class TestGeminiSessionModel: method test_gemini_cli_uses_protocol_model_override (line 3065) | async def test_gemini_cli_uses_protocol_model_override(self): class TestExtractTokenUsage (line 3081) | class TestExtractTokenUsage: method test_from_response_usage (line 3082) | def test_from_response_usage(self): method test_from_field_meta_quota (line 3092) | def test_from_field_meta_quota(self): method test_none_response (line 3101) | def test_none_response(self): method test_no_usage_no_meta (line 3104) | def test_no_usage_no_meta(self): method test_empty_quota (line 3110) | def test_empty_quota(self): class TestEstimateCostFromTokens (line 3122) | class TestEstimateCostFromTokens: method test_unknown_model_returns_zero (line 3123) | def test_unknown_model_returns_zero(self): method test_zero_tokens_returns_zero (line 3126) | def test_zero_tokens_returns_zero(self): method test_known_model_returns_positive (line 3129) | def test_known_model_returns_positive(self): method test_import_failure_returns_zero (line 3142) | def test_import_failure_returns_zero(self): class TestSerializeToolContent (line 3154) | class TestSerializeToolContent: method test_none_returns_none (line 3155) | def test_none_returns_none(self): method test_empty_list_returns_none (line 3158) | def test_empty_list_returns_none(self): method test_pydantic_model (line 3161) | def test_pydantic_model(self): method test_plain_dict_passthrough (line 3175) | def test_plain_dict_passthrough(self): method test_mixed_content (line 3180) | def test_mixed_content(self): class TestACPSessionIdPersistence (line 3193) | class TestACPSessionIdPersistence: method _transport_patches (line 3200) | def _transport_patches(conn): method _patched_start_acp_server (line 3244) | def _patched_start_acp_server(agent, state, *, conn): method _make_conn (line 3253) | def _make_conn( method test_fresh_state_has_no_session_id (line 3282) | def test_fresh_state_has_no_session_id(self, tmp_path): method test_first_launch_calls_new_session (line 3287) | def test_first_launch_calls_new_session(self, tmp_path): method test_init_state_writes_session_id_into_agent_state (line 3299) | def test_init_state_writes_session_id_into_agent_state(self, tmp_path): method test_resume_reads_session_id_from_agent_state (line 3320) | def test_resume_reads_session_id_from_agent_state(self, tmp_path): method test_load_session_failure_falls_back_to_new_session (line 3336) | def test_load_session_failure_falls_back_to_new_session(self, tmp_path): method test_session_id_not_on_serialized_agent (line 3352) | def test_session_id_not_on_serialized_agent(self): method test_init_state_writes_cwd_alongside_session_id (line 3361) | def test_init_state_writes_cwd_alongside_session_id(self, tmp_path): method test_cwd_mismatch_skips_load_and_calls_new_session (line 3380) | def test_cwd_mismatch_skips_load_and_calls_new_session(self, tmp_path,... method test_resume_without_stored_cwd_still_works (line 3405) | def test_resume_without_stored_cwd_still_works(self, tmp_path): method test_fallback_replacement_id_lands_in_agent_state (line 3420) | def test_fallback_replacement_id_lands_in_agent_state(self, tmp_path): method test_resume_path_still_applies_session_mode_and_model (line 3448) | def test_resume_path_still_applies_session_mode_and_model(self, tmp_pa... method test_roundtrip_via_conversation_state_persistence (line 3481) | def test_roundtrip_via_conversation_state_persistence(self, tmp_path): class TestACPSecretsEnvInjection (line 3548) | class TestACPSecretsEnvInjection: method _make_conn (line 3557) | def _make_conn(): method _run_start_capturing_env (line 3576) | def _run_start_capturing_env(agent, tmp_path) -> dict: method test_static_secret_injected_into_subprocess_env (line 3628) | def test_static_secret_injected_into_subprocess_env(self, tmp_path): method test_acp_env_takes_precedence_over_agent_context_secret (line 3647) | def test_acp_env_takes_precedence_over_agent_context_secret(self, tmp_... method test_none_value_secret_not_injected (line 3662) | def test_none_value_secret_not_injected(self, tmp_path): method test_empty_string_secret_not_injected (line 3674) | def test_empty_string_secret_not_injected(self, tmp_path): class TestACPEnvConflictSuppression (line 3689) | class TestACPEnvConflictSuppression: method _make_conn (line 3702) | def _make_conn(): method _run_start_capturing_env (line 3721) | def _run_start_capturing_env(agent, tmp_path, *, extra_os_env=None) ->... method test_claude_config_dir_suppresses_api_key_from_acp_env (line 3774) | def test_claude_config_dir_suppresses_api_key_from_acp_env(self, tmp_p... method test_claude_config_dir_suppresses_api_key_from_os_environ (line 3789) | def test_claude_config_dir_suppresses_api_key_from_os_environ(self, tm... method test_claude_config_dir_suppresses_api_key_from_secrets (line 3807) | def test_claude_config_dir_suppresses_api_key_from_secrets(self, tmp_p... method test_no_suppression_without_claude_config_dir (line 3832) | def test_no_suppression_without_claude_config_dir(self, tmp_path): FILE: tests/sdk/agent/test_acp_dedup_and_truncation.py function _make_tool_call_event (line 22) | def _make_tool_call_event(tool_call_id: str, raw_output: str = "") -> AC... function _make_events_list (line 30) | def _make_events_list() -> RemoteEventsList: class TestACPToolCallDeduplication (line 37) | class TestACPToolCallDeduplication(unittest.TestCase): method setUp (line 38) | def setUp(self) -> None: method _add (line 41) | def _add(self, event: ACPToolCallEvent) -> None: method test_first_event_is_added (line 45) | def test_first_event_is_added(self) -> None: method test_subsequent_events_replace_not_append (line 51) | def test_subsequent_events_replace_not_append(self) -> None: method test_different_tool_call_ids_are_kept_separately (line 67) | def test_different_tool_call_ids_are_kept_separately(self) -> None: method test_index_stays_consistent_after_replacement (line 81) | def test_index_stays_consistent_after_replacement(self) -> None: method test_stale_index_entry_is_cleaned_up_with_warning (line 89) | def test_stale_index_entry_is_cleaned_up_with_warning(self) -> None: method test_thread_safety_concurrent_updates (line 110) | def test_thread_safety_concurrent_updates(self) -> None: class TestSerializeToolContentTruncation (line 137) | class TestSerializeToolContentTruncation(unittest.TestCase): method test_short_text_is_not_truncated (line 138) | def test_short_text_is_not_truncated(self) -> None: method test_long_text_is_truncated_to_max (line 144) | def test_long_text_is_truncated_to_max(self) -> None: method test_non_text_blocks_are_not_modified (line 151) | def test_non_text_blocks_are_not_modified(self) -> None: method test_none_content_returns_none (line 158) | def test_none_content_returns_none(self) -> None: method test_empty_content_returns_none (line 161) | def test_empty_content_returns_none(self) -> None: method test_mixed_blocks_only_truncates_text (line 164) | def test_mixed_blocks_only_truncates_text(self) -> None: method test_pydantic_model_content_is_serialized (line 176) | def test_pydantic_model_content_is_serialized(self) -> None: FILE: tests/sdk/agent/test_action_batch.py function _ae (line 14) | def _ae(tool_name: str = "tool", action_id: str | None = None) -> Action... function test_truncate_at_finish (line 37) | def test_truncate_at_finish(names, expected_names, expected_finish): function _make_state (line 44) | def _make_state(blocked: dict[str, str] | None = None): function _make_executor (line 52) | def _make_executor(side_effect: Any = None) -> Any: function _run (line 64) | def _run(ae: ActionEvent) -> list[Any]: function test_prepare_simple (line 68) | def test_prepare_simple(): function test_prepare_with_blocked (line 78) | def test_prepare_with_blocked(): function test_prepare_truncates_before_blocking (line 94) | def test_prepare_truncates_before_blocking(): function test_prepare_all_blocked (line 106) | def test_prepare_all_blocked(): function test_prepare_empty (line 119) | def test_prepare_empty(): function _obs (line 129) | def _obs(label: str) -> ObservationEvent: function test_emit_results_in_order (line 136) | def test_emit_results_in_order(): function test_emit_blocked_produces_rejection (line 149) | def test_emit_blocked_produces_rejection(): function test_finalize_noop_when_no_finish (line 170) | def test_finalize_noop_when_no_finish(): function test_finalize_marks_finished (line 181) | def test_finalize_marks_finished(): function test_finalize_emits_followup_on_refinement (line 197) | def test_finalize_emits_followup_on_refinement(): function test_finalize_noop_when_finish_blocked (line 214) | def test_finalize_noop_when_finish_blocked(): FILE: tests/sdk/agent/test_agent_browser_auto_detect.py function _make_llm (line 11) | def _make_llm() -> LLM: function test_browser_auto_detect (line 36) | def test_browser_auto_detect(tools, prompt_kwargs, expect_browser): FILE: tests/sdk/agent/test_agent_context_window_condensation.py class RaisingLLM (line 22) | class RaisingLLM(LLM): method __init__ (line 25) | def __init__(self, *, model: str = "test-model", force_responses: bool... method uses_responses_api (line 29) | def uses_responses_api(self) -> bool: # override gating method completion (line 32) | def completion(self, *, messages, tools=None, **kwargs): # type: igno... method responses (line 35) | def responses(self, *, messages, tools=None, **kwargs): # type: ignor... class MalformedHistoryRaisingLLM (line 39) | class MalformedHistoryRaisingLLM(LLM): method __init__ (line 42) | def __init__(self, *, model: str = "test-model", force_responses: bool... method uses_responses_api (line 46) | def uses_responses_api(self) -> bool: # override gating method completion (line 49) | def completion(self, *, messages, tools=None, **kwargs): # type: igno... method responses (line 55) | def responses(self, *, messages, tools=None, **kwargs): # type: ignor... class HandlesRequestsCondenser (line 62) | class HandlesRequestsCondenser(CondenserBase): method condense (line 63) | def condense( method handles_condensation_requests (line 68) | def handles_condensation_requests(self) -> bool: function test_agent_triggers_condensation_request_when_ctx_exceeded_with_condenser (line 73) | def test_agent_triggers_condensation_request_when_ctx_exceeded_with_cond... function test_agent_triggers_condensation_request_when_history_is_malformed (line 93) | def test_agent_triggers_condensation_request_when_history_is_malformed( function test_agent_raises_ctx_exceeded_when_no_condenser (line 122) | def test_agent_raises_ctx_exceeded_when_no_condenser(force_responses: bo... function test_agent_raises_malformed_history_error_when_no_condenser (line 134) | def test_agent_raises_malformed_history_error_when_no_condenser( function test_agent_logs_warning_when_no_condenser_on_ctx_exceeded (line 158) | def test_agent_logs_warning_when_no_condenser_on_ctx_exceeded( class NoHandlesRequestsCondenser (line 181) | class NoHandlesRequestsCondenser(CondenserBase): method condense (line 184) | def condense( method handles_condensation_requests (line 189) | def handles_condensation_requests(self) -> bool: function test_agent_logs_warning_with_non_handling_condenser_on_ctx_exceeded (line 194) | def test_agent_logs_warning_with_non_handling_condenser_on_ctx_exceeded( FILE: tests/sdk/agent/test_agent_immutability.py class TestAgentImmutability (line 10) | class TestAgentImmutability: method setup_method (line 13) | def setup_method(self): method test_agent_is_frozen (line 19) | def test_agent_is_frozen(self): method test_system_message_is_computed_property (line 35) | def test_system_message_is_computed_property(self): method test_condenser_property_access (line 57) | def test_condenser_property_access(self): method test_agent_properties_are_accessible (line 67) | def test_agent_properties_are_accessible(self): method test_agent_is_truly_stateless (line 84) | def test_agent_is_truly_stateless(self): method test_multiple_agents_are_independent (line 107) | def test_multiple_agents_are_independent(self): method test_agent_model_copy_creates_new_instance (line 129) | def test_agent_model_copy_creates_new_instance(self): FILE: tests/sdk/agent/test_agent_init_state_invariants.py function _make_agent (line 18) | def _make_agent() -> Agent: function _make_state (line 23) | def _make_state(agent: Agent, tmp_path) -> ConversationState: function test_agent_init_state_adds_system_prompt_via_callback (line 33) | def test_agent_init_state_adds_system_prompt_via_callback(tmp_path) -> N... function test_agent_init_state_skips_when_system_prompt_already_present (line 49) | def test_agent_init_state_skips_when_system_prompt_already_present(tmp_p... function test_agent_init_state_skips_when_system_prompt_is_second_event_remote_prefix (line 71) | def test_agent_init_state_skips_when_system_prompt_is_second_event_remot... function test_agent_init_state_raises_if_user_message_before_system_prompt_in_prefix (line 96) | def test_agent_init_state_raises_if_user_message_before_system_prompt_in... FILE: tests/sdk/agent/test_agent_llms_are_discoverable.py function check_usage_id_exists (line 7) | def check_usage_id_exists(usage_id: str, llms: list[LLM]): class CustomAgentWithRouters (line 15) | class CustomAgentWithRouters(Agent): function test_automatic_llm_discovery (line 21) | def test_automatic_llm_discovery(): function test_automatic_llm_discovery_for_multiple_llms (line 30) | def test_automatic_llm_discovery_for_multiple_llms(): function test_automatic_llm_discovery_for_custom_agent_with_duplicates (line 48) | def test_automatic_llm_discovery_for_custom_agent_with_duplicates(): function test_automatic_llm_discovery_with_multimodal_router (line 76) | def test_automatic_llm_discovery_with_multimodal_router(): function test_automatic_llm_discovery_with_llm_as_base_class (line 103) | def test_automatic_llm_discovery_with_llm_as_base_class(): FILE: tests/sdk/agent/test_agent_serialization.py function create_mock_mcp_tool (line 20) | def create_mock_mcp_tool(name: str) -> MCPToolDefinition: function test_agent_supports_polymorphic_json_serialization (line 38) | def test_agent_supports_polymorphic_json_serialization() -> None: function test_mcp_tool_serialization (line 55) | def test_mcp_tool_serialization(): function test_agent_serialization_redacts_mcp_config_by_default (line 62) | def test_agent_serialization_redacts_mcp_config_by_default() -> None: function test_agent_serialization_exposes_mcp_config_with_expose_secrets (line 97) | def test_agent_serialization_exposes_mcp_config_with_expose_secrets() ->... function test_agent_serialization_encrypts_mcp_config_with_cipher (line 123) | def test_agent_serialization_encrypts_mcp_config_with_cipher() -> None: function test_agent_mcp_config_encryption_decryption_roundtrip (line 147) | def test_agent_mcp_config_encryption_decryption_roundtrip() -> None: function test_agent_mcp_config_decryption_without_cipher_logs_warning (line 174) | def test_agent_mcp_config_decryption_without_cipher_logs_warning() -> None: function test_agent_mcp_config_backward_compatibility_plaintext (line 194) | def test_agent_mcp_config_backward_compatibility_plaintext() -> None: function test_agent_mcp_config_empty_not_encrypted (line 212) | def test_agent_mcp_config_empty_not_encrypted() -> None: function test_agent_supports_polymorphic_field_json_serialization (line 228) | def test_agent_supports_polymorphic_field_json_serialization() -> None: function test_agent_supports_nested_polymorphic_json_serialization (line 250) | def test_agent_supports_nested_polymorphic_json_serialization() -> None: function test_agent_model_validate_json_dict (line 277) | def test_agent_model_validate_json_dict() -> None: function test_agent_fallback_behavior_json (line 294) | def test_agent_fallback_behavior_json() -> None: function test_agent_preserves_pydantic_parameters_json (line 305) | def test_agent_preserves_pydantic_parameters_json() -> None: function test_agent_type_annotation_works_json (line 321) | def test_agent_type_annotation_works_json() -> None: function test_agent_type_annotation_on_basemodel_works_json (line 345) | def test_agent_type_annotation_on_basemodel_works_json() -> None: function test_include_default_tools_serialization_default (line 369) | def test_include_default_tools_serialization_default() -> None: function test_include_default_tools_serialization_empty (line 383) | def test_include_default_tools_serialization_empty() -> None: function test_include_default_tools_serialization_partial (line 396) | def test_include_default_tools_serialization_partial() -> None: function test_include_default_tools_deserialization_roundtrip (line 409) | def test_include_default_tools_deserialization_roundtrip() -> None: function test_include_default_tools_deserialization_all_tools (line 425) | def test_include_default_tools_deserialization_all_tools() -> None: function test_include_default_tools_deserialization_empty (line 441) | def test_include_default_tools_deserialization_empty() -> None: function test_include_default_tools_deserialization_from_dict (line 457) | def test_include_default_tools_deserialization_from_dict() -> None: FILE: tests/sdk/agent/test_agent_step_responses_gating.py class DummyLLM (line 14) | class DummyLLM(LLM): method __init__ (line 18) | def __init__(self, *, model: str, force_responses: bool): method uses_responses_api (line 22) | def uses_responses_api(self) -> bool: # override gating method completion (line 26) | def completion(self, *, messages, tools=None, **kwargs) -> LLMResponse... method responses (line 40) | def responses(self, *, messages, tools=None, **kwargs) -> LLMResponse:... function test_agent_step_routes_to_responses_or_completion (line 61) | def test_agent_step_routes_to_responses_or_completion(force_responses, e... class ModelGateLLM (line 82) | class ModelGateLLM(LLM): method __init__ (line 85) | def __init__(self, *, model: str): method completion (line 88) | def completion(self, *, messages, tools=None, **kwargs) -> LLMResponse... method responses (line 101) | def responses(self, *, messages, tools=None, **kwargs) -> LLMResponse:... function test_agent_step_model_features_gate_to_responses_or_completion (line 122) | def test_agent_step_model_features_gate_to_responses_or_completion(model... FILE: tests/sdk/agent/test_agent_tool_init.py class _Action (line 17) | class _Action(Action): class _Obs (line 21) | class _Obs(Observation): method to_llm_content (line 25) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class _Exec (line 29) | class _Exec(ToolExecutor[_Action, _Obs]): method __call__ (line 30) | def __call__(self, action: _Action, conversation=None) -> _Obs: class _UpperTool (line 34) | class _UpperTool(ToolDefinition[_Action, _Obs]): method create (line 40) | def create(cls, conv_state=None, **params) -> Sequence["_UpperTool"]: function _make_tool (line 51) | def _make_tool(conv_state=None, **kwargs) -> Sequence[ToolDefinition]: function test_agent_initializes_tools_from_toolspec_locally (line 55) | def test_agent_initializes_tools_from_toolspec_locally(monkeypatch): function test_agent_include_only_finish_tool (line 79) | def test_agent_include_only_finish_tool(): function test_agent_include_only_think_tool (line 94) | def test_agent_include_only_think_tool(): function test_agent_disable_all_default_tools (line 109) | def test_agent_disable_all_default_tools(): class _CustomFinishAction (line 125) | class _CustomFinishAction(Action): method visualize (line 130) | def visualize(self) -> Text: class _CustomFinishObs (line 134) | class _CustomFinishObs(Observation): method to_llm_content (line 136) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class _CustomFinishExec (line 140) | class _CustomFinishExec(ToolExecutor[_CustomFinishAction, _CustomFinishO... method __call__ (line 141) | def __call__( class _CustomFinishTool (line 147) | class _CustomFinishTool(ToolDefinition[_CustomFinishAction, _CustomFinis... method create (line 153) | def create(cls, conv_state=None, **params) -> Sequence["_CustomFinishT... function _make_custom_finish_tool (line 164) | def _make_custom_finish_tool(conv_state=None, **kwargs) -> Sequence[Tool... function test_agent_replace_finish_with_custom_tool (line 168) | def test_agent_replace_finish_with_custom_tool(): FILE: tests/sdk/agent/test_agent_utils.py function mock_llm (line 26) | def mock_llm(): function sample_events (line 34) | def sample_events(): function sample_messages (line 62) | def sample_messages(): function mock_condenser (line 81) | def mock_condenser(): class MockAgentUtilsAction (line 86) | class MockAgentUtilsAction(Action): class MockAgentUtilsObservation (line 92) | class MockAgentUtilsObservation(Observation): method to_llm_content (line 98) | def to_llm_content(self): class MockAgentUtilsTool (line 102) | class MockAgentUtilsTool( method create (line 108) | def create(cls, conv_state=None, **params): function sample_tools (line 113) | def sample_tools(): function test_prepare_llm_messages_without_condenser (line 131) | def test_prepare_llm_messages_without_condenser( function test_prepare_llm_messages_with_additional_messages (line 152) | def test_prepare_llm_messages_with_additional_messages( function test_prepare_llm_messages_with_condenser_returns_view (line 184) | def test_prepare_llm_messages_with_condenser_returns_view( function test_prepare_llm_messages_with_condenser_returns_condensation (line 216) | def test_prepare_llm_messages_with_condenser_returns_condensation( function test_prepare_llm_messages_empty_events (line 242) | def test_prepare_llm_messages_empty_events(mock_events_to_messages, mock... function test_make_llm_completion_with_completion_api (line 264) | def test_make_llm_completion_with_completion_api(mock_llm, sample_messag... function test_make_llm_completion_with_responses_api (line 286) | def test_make_llm_completion_with_responses_api(mock_llm, sample_messages): function test_make_llm_completion_with_tools_completion_api (line 310) | def test_make_llm_completion_with_tools_completion_api( function test_make_llm_completion_with_tools_responses_api (line 333) | def test_make_llm_completion_with_tools_responses_api( function test_make_llm_completion_with_none_tools (line 358) | def test_make_llm_completion_with_none_tools(mock_llm, sample_messages): function test_make_llm_completion_with_empty_tools_list (line 378) | def test_make_llm_completion_with_empty_tools_list(mock_llm, sample_mess... function test_make_llm_completion_empty_messages (line 398) | def test_make_llm_completion_empty_messages(mock_llm): function test_prepare_llm_messages_and_make_llm_completion_integration (line 425) | def test_prepare_llm_messages_and_make_llm_completion_integration( function test_make_llm_completion_api_selection (line 455) | def test_make_llm_completion_api_selection(): FILE: tests/sdk/agent/test_extract_security_risk.py class MockNonLLMAnalyzer (line 18) | class MockNonLLMAnalyzer(SecurityAnalyzerBase): method security_risk (line 21) | def security_risk(self, action: ActionEvent) -> SecurityRisk: function mock_llm (line 26) | def mock_llm(): function agent_with_llm_analyzer (line 37) | def agent_with_llm_analyzer(mock_llm): function agent_with_non_llm_analyzer (line 44) | def agent_with_non_llm_analyzer(mock_llm): function agent_without_analyzer (line 51) | def agent_without_analyzer(mock_llm): function test_extract_security_risk (line 89) | def test_extract_security_risk( function test_extract_security_risk_arguments_mutation (line 114) | def test_extract_security_risk_arguments_mutation(): function test_extract_security_risk_with_empty_arguments (line 143) | def test_extract_security_risk_with_empty_arguments(): function test_extract_security_risk_with_read_only_tool (line 162) | def test_extract_security_risk_with_read_only_tool(): FILE: tests/sdk/agent/test_extract_summary.py function agent (line 16) | def agent(): function test_extract_summary (line 42) | def test_extract_summary(agent, summary_value, expected_result): function _make_mcp_tool_with_summary (line 53) | def _make_mcp_tool_with_summary(): function test_extract_summary_preserves_mcp_tool_summary_param (line 72) | def test_extract_summary_preserves_mcp_tool_summary_param(agent): function test_mcp_tool_with_summary_param_roundtrip (line 90) | def test_mcp_tool_with_summary_param_roundtrip(agent): function test_extract_summary_mcp_tool_summary_missing_falls_back (line 108) | def test_extract_summary_mcp_tool_summary_missing_falls_back(agent): function test_extract_summary_still_pops_for_tools_without_summary_param (line 125) | def test_extract_summary_still_pops_for_tools_without_summary_param(agent): FILE: tests/sdk/agent/test_fix_malformed_tool_arguments.py class JsonDecodingTestAction (line 18) | class JsonDecodingTestAction(Action): class JsonDecodingAnnotatedAction (line 26) | class JsonDecodingAnnotatedAction(Action): class JsonDecodingAliasAction (line 33) | class JsonDecodingAliasAction(Action): class JsonDecodingOptionalAction (line 40) | class JsonDecodingOptionalAction(Action): class _NestedActionForMalformedArgs (line 47) | class _NestedActionForMalformedArgs(Action): function test_decode_json_string_list (line 60) | def test_decode_json_string_list(): function test_decode_json_string_dict (line 75) | def test_decode_json_string_dict(): function test_native_list_dict_passthrough (line 90) | def test_native_list_dict_passthrough(): function test_regular_string_not_decoded (line 105) | def test_regular_string_not_decoded(): function test_annotated_types (line 121) | def test_annotated_types(): function test_field_aliases (line 134) | def test_field_aliases(): function test_optional_fields_with_json_strings (line 147) | def test_optional_fields_with_json_strings(): function test_optional_fields_with_none (line 160) | def test_optional_fields_with_none(): function test_optional_fields_with_native_values (line 170) | def test_optional_fields_with_native_values(): function test_invalid_json_string_rejected (line 183) | def test_invalid_json_string_rejected(): function test_json_string_with_wrong_type_rejected (line 199) | def test_json_string_with_wrong_type_rejected(): function test_nested_structures (line 215) | def test_nested_structures(): function test_empty_collections (line 228) | def test_empty_collections(): function test_mixed_native_and_json_strings (line 242) | def test_mixed_native_and_json_strings(): function test_unicode_in_json_strings (line 257) | def test_unicode_in_json_strings(): function test_whitespace_in_json_strings (line 271) | def test_whitespace_in_json_strings(): function test_trailing_garbage_truncation (line 308) | def test_trailing_garbage_truncation(field, raw_value, expected): function test_trailing_garbage_with_nested_braces (line 321) | def test_trailing_garbage_with_nested_braces(): FILE: tests/sdk/agent/test_iterative_refinement.py class MockCritic (line 23) | class MockCritic(CriticBase): method evaluate (line 26) | def evaluate(self, events, git_patch=None): class MockCriticMixin (line 30) | class MockCriticMixin(CriticMixin): method __init__ (line 33) | def __init__(self, critic=None): function create_mock_conversation (line 37) | def create_mock_conversation(iteration: int = 0): function create_finish_action_event (line 49) | def create_finish_action_event(critic_result: CriticResult | None = None): class TestIterativeRefinementConfig (line 72) | class TestIterativeRefinementConfig: method test_default_values (line 75) | def test_default_values(self): method test_custom_values (line 81) | def test_custom_values(self): method test_threshold_validation_bounds (line 90) | def test_threshold_validation_bounds(self): method test_max_iterations_validation (line 102) | def test_max_iterations_validation(self): class TestCheckIterativeRefinement (line 110) | class TestCheckIterativeRefinement: method test_no_critic_returns_false (line 113) | def test_no_critic_returns_false(self): method test_no_iterative_config_returns_false (line 126) | def test_no_iterative_config_returns_false(self): method test_max_iterations_reached (line 141) | def test_max_iterations_reached(self): method test_no_critic_result_returns_false (line 162) | def test_no_critic_result_returns_false(self): method test_score_meets_threshold (line 177) | def test_score_meets_threshold(self): method test_score_exactly_at_threshold (line 197) | def test_score_exactly_at_threshold(self): method test_high_probability_issue_continues_even_when_score_meets_threshold (line 214) | def test_high_probability_issue_continues_even_when_score_meets_thresh... method test_score_below_threshold_continues (line 252) | def test_score_below_threshold_continues(self): method test_iteration_only_increments_on_continue (line 274) | def test_iteration_only_increments_on_continue(self): method test_multiple_iterations (line 300) | def test_multiple_iterations(self): class TestShouldEvaluateWithCritic (line 329) | class TestShouldEvaluateWithCritic: method test_no_critic_returns_false (line 332) | def test_no_critic_returns_false(self): method test_all_actions_mode (line 338) | def test_all_actions_mode(self): method test_finish_and_message_mode (line 347) | def test_finish_and_message_mode(self): FILE: tests/sdk/agent/test_message_while_finishing.py class SleepAction (line 76) | class SleepAction(Action): class SleepObservation (line 81) | class SleepObservation(Observation): method to_llm_content (line 85) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class SleepExecutor (line 89) | class SleepExecutor(ToolExecutor): method __call__ (line 93) | def __call__(self, action: SleepAction, conversation=None) -> SleepObs... class SleepTool (line 132) | class SleepTool(ToolDefinition[SleepAction, SleepObservation]): method create (line 138) | def create(cls, conv_state=None, **params) -> Sequence["SleepTool"]: function _make_sleep_tool (line 149) | def _make_sleep_tool(conv_state=None, **kwargs) -> Sequence[ToolDefiniti... class TestMessageWhileFinishing (line 158) | class TestMessageWhileFinishing: method setup_method (line 161) | def setup_method(self): method _mock_llm_response (line 173) | def _mock_llm_response(self, messages, **kwargs): method test_message_processing_fix_verification (line 292) | def test_message_processing_fix_verification(self): function _run_parallel_main (line 518) | def _run_parallel_main(): # pragma: no cover - helper for manual stress... FILE: tests/sdk/agent/test_non_executable_action_emission.py function test_emits_action_event_with_none_action_then_error_on_missing_tool (line 25) | def test_emits_action_event_with_none_action_then_error_on_missing_tool(... FILE: tests/sdk/agent/test_nonexistent_tool_handling.py function test_nonexistent_tool_returns_error_and_continues_conversation (line 21) | def test_nonexistent_tool_returns_error_and_continues_conversation(): function test_nonexistent_tool_error_includes_available_tools (line 114) | def test_nonexistent_tool_error_includes_available_tools(): function test_conversation_continues_after_tool_error (line 189) | def test_conversation_continues_after_tool_error(): FILE: tests/sdk/agent/test_parallel_execution_integration.py class SlowAction (line 34) | class SlowAction(Action): class SlowObservation (line 39) | class SlowObservation(Observation): class SlowExecutor (line 44) | class SlowExecutor(ToolExecutor[SlowAction, SlowObservation]): method __call__ (line 45) | def __call__( class SlowTool (line 56) | class SlowTool(ToolDefinition[SlowAction, SlowObservation]): method declared_resources (line 59) | def declared_resources(self, action: Action) -> DeclaredResources: method create (line 64) | def create(cls, conv_state: "ConversationState | None" = None) -> Sequ... class ParallelFailingAction (line 75) | class ParallelFailingAction(Action): class ParallelFailingObservation (line 79) | class ParallelFailingObservation(Observation): class ParallelFailingExecutor (line 83) | class ParallelFailingExecutor( method __call__ (line 86) | def __call__( class ParallelFailingTool (line 94) | class ParallelFailingTool( method create (line 100) | def create(cls, conv_state: "ConversationState | None" = None) -> Sequ... function _tool_call (line 118) | def _tool_call(call_id: str, name: str, arguments: str) -> MessageToolCall: function _run_step (line 124) | def _run_step(agent, conversation, collected_events): function test_parallel_execution_multiple_tools (line 132) | def test_parallel_execution_multiple_tools(): function test_parallel_execution_faster_than_sequential (line 163) | def test_parallel_execution_faster_than_sequential(): function test_sequential_execution_with_default_limit (line 194) | def test_sequential_execution_with_default_limit(): function test_limit_one_preserves_sequential_semantics (line 222) | def test_limit_one_preserves_sequential_semantics(): function test_finish_tool_truncates_subsequent_tools (line 274) | def test_finish_tool_truncates_subsequent_tools(): function test_error_in_parallel_batch_preserves_other_results (line 318) | def test_error_in_parallel_batch_preserves_other_results(): function test_blocked_action_with_parallel_execution (line 375) | def test_blocked_action_with_parallel_execution(): function test_tool_concurrency_limit_wires_to_executor (line 408) | def test_tool_concurrency_limit_wires_to_executor(): function test_tool_concurrency_limit_rejects_invalid_values (line 421) | def test_tool_concurrency_limit_rejects_invalid_values(value): FILE: tests/sdk/agent/test_parallel_executor.py function test_default_max_workers (line 12) | def test_default_max_workers(): function test_custom_max_workers (line 17) | def test_custom_max_workers(): function test_empty_batch (line 22) | def test_empty_batch(): function test_single_action_bypasses_thread_pool (line 28) | def test_single_action_bypasses_thread_pool(): function test_multi_action_limit_one_runs_sequentially_on_caller_thread (line 38) | def test_multi_action_limit_one_runs_sequentially_on_caller_thread(): function test_result_ordering_preserved_despite_variable_duration (line 60) | def test_result_ordering_preserved_despite_variable_duration(): function test_actions_run_concurrently (line 81) | def test_actions_run_concurrently(): function test_concurrency_limited_by_max_workers (line 103) | def test_concurrency_limited_by_max_workers(): function test_multiple_events_per_action (line 125) | def test_multiple_events_per_action(): function _make_action (line 140) | def _make_action(name: str = "test_tool", tool_call_id: str = "call_1") ... function test_error_returns_agent_error_event_for_single_action (line 148) | def test_error_returns_agent_error_event_for_single_action(): function test_error_returns_agent_error_event_in_batch (line 163) | def test_error_returns_agent_error_event_in_batch(): function test_all_exceptions_wrapped_in_agent_error_event (line 192) | def test_all_exceptions_wrapped_in_agent_error_event(): function test_nested_execution_no_deadlock (line 214) | def test_nested_execution_no_deadlock(): FILE: tests/sdk/agent/test_parallel_executor_locking.py function _make_action (line 15) | def _make_action( function _make_tool (line 28) | def _make_tool( function _ok_event (line 42) | def _ok_event() -> Any: function test_undeclared_resources_serializes_via_tool_mutex (line 49) | def test_undeclared_resources_serializes_via_tool_mutex(): function test_declared_empty_keys_skips_locking (line 78) | def test_declared_empty_keys_skips_locking(): function test_specific_resource_keys_serialize_same_resource (line 105) | def test_specific_resource_keys_serialize_same_resource(): function test_no_tools_dict_skips_locking (line 143) | def test_no_tools_dict_skips_locking(): function test_none_action_falls_back_to_tool_mutex (line 156) | def test_none_action_falls_back_to_tool_mutex(): FILE: tests/sdk/agent/test_reasoning_only_responses.py class ReasoningOnlyLLM (line 16) | class ReasoningOnlyLLM(LLM): method __init__ (line 21) | def __init__(self): method completion (line 24) | def completion( # type: ignore[override] function test_agent_continues_after_reasoning_only_response (line 66) | def test_agent_continues_after_reasoning_only_response(): class ContentOnlyLLM (line 85) | class ContentOnlyLLM(LLM): method __init__ (line 90) | def __init__(self): method completion (line 93) | def completion( # type: ignore[override] function test_agent_finishes_after_content_only_response (line 113) | def test_agent_finishes_after_content_only_response(): class EmptyResponseLLM (line 139) | class EmptyResponseLLM(LLM): method __init__ (line 144) | def __init__(self): method completion (line 147) | def completion( # type: ignore[override] function test_agent_handles_empty_response (line 189) | def test_agent_handles_empty_response(): FILE: tests/sdk/agent/test_response_dispatch.py function _msg (line 26) | def _msg(**kwargs) -> Message: function _tool_call (line 31) | def _tool_call() -> MessageToolCall: function test_tool_calls_response (line 72) | def test_tool_calls_response(kwargs): function test_content_response (line 102) | def test_content_response(kwargs): function test_reasoning_only_response (line 141) | def test_reasoning_only_response(kwargs): function test_empty_response (line 160) | def test_empty_response(kwargs): function _make_metrics (line 170) | def _make_metrics() -> MetricsSnapshot: function _make_llm_response (line 179) | def _make_llm_response(message: Message) -> LLMResponse: function _run_single_step (line 187) | def _run_single_step( function test_content_response_sets_finished (line 219) | def test_content_response_sets_finished(): function test_empty_response_sends_nudge (line 230) | def test_empty_response_sends_nudge(): function test_reasoning_only_sends_nudge (line 245) | def test_reasoning_only_sends_nudge(): function test_tool_calls_response_executes_actions (line 257) | def test_tool_calls_response_executes_actions(): FILE: tests/sdk/agent/test_sanitize_json_control_chars.py function test_valid_json_unchanged (line 14) | def test_valid_json_unchanged(): function test_literal_newline_escaped (line 20) | def test_literal_newline_escaped(): function test_literal_tab_escaped (line 29) | def test_literal_tab_escaped(): function test_multiple_control_chars (line 38) | def test_multiple_control_chars(): function test_null_byte_escaped (line 46) | def test_null_byte_escaped(): function test_form_feed_and_backspace (line 55) | def test_form_feed_and_backspace(): function test_already_escaped_sequences_preserved (line 65) | def test_already_escaped_sequences_preserved(): function test_empty_string (line 74) | def test_empty_string(): function test_realistic_tool_call_arguments (line 79) | def test_realistic_tool_call_arguments(): FILE: tests/sdk/agent/test_security_policy_integration.py function test_security_policy_in_system_message (line 23) | def test_security_policy_in_system_message(): function test_none_security_policy_filename_disables_policy_without_null_public_value (line 68) | def test_none_security_policy_filename_disables_policy_without_null_publ... function test_custom_security_policy_in_system_message (line 87) | def test_custom_security_policy_in_system_message(): function test_security_policy_template_rendering (line 148) | def test_security_policy_template_rendering(): function test_llm_security_analyzer_template_kwargs (line 178) | def test_llm_security_analyzer_template_kwargs(): function test_llm_security_analyzer_sandbox_mode (line 203) | def test_llm_security_analyzer_sandbox_mode(): function test_no_security_analyzer_still_includes_risk_assessment (line 232) | def test_no_security_analyzer_still_includes_risk_assessment(): function test_non_llm_security_analyzer_still_includes_risk_assessment (line 253) | def test_non_llm_security_analyzer_still_includes_risk_assessment(): function _tool_response (line 281) | def _tool_response(name: str, args_json: str) -> ModelResponse: function test_security_risk_param_ignored_when_no_analyzer (line 307) | def test_security_risk_param_ignored_when_no_analyzer(): FILE: tests/sdk/agent/test_system_prompt.py function _make_llm (line 12) | def _make_llm() -> LLM: function test_system_prompt_is_accepted_and_stored (line 19) | def test_system_prompt_is_accepted_and_stored() -> None: function test_system_prompt_defaults_to_none (line 24) | def test_system_prompt_defaults_to_none() -> None: function test_static_system_message_returns_inline_prompt (line 32) | def test_static_system_message_returns_inline_prompt() -> None: function test_static_system_message_falls_back_to_template_when_none (line 37) | def test_static_system_message_falls_back_to_template_when_none() -> None: function test_system_prompt_and_custom_filename_are_mutually_exclusive (line 47) | def test_system_prompt_and_custom_filename_are_mutually_exclusive() -> N... function test_system_prompt_with_default_filename_is_ok (line 57) | def test_system_prompt_with_default_filename_is_ok() -> None: function test_system_prompt_survives_json_round_trip (line 72) | def test_system_prompt_survives_json_round_trip() -> None: function test_system_prompt_none_survives_json_round_trip (line 81) | def test_system_prompt_none_survives_json_round_trip() -> None: FILE: tests/sdk/agent/test_tool_call_compatibility.py class _TerminalAction (line 39) | class _TerminalAction(Action): class _TerminalObservation (line 43) | class _TerminalObservation(Observation): class _TerminalExecutor (line 47) | class _TerminalExecutor(ToolExecutor[_TerminalAction, _TerminalObservati... method __call__ (line 48) | def __call__( class _TerminalTool (line 65) | class _TerminalTool(ToolDefinition[_TerminalAction, _TerminalObservation]): method create (line 69) | def create(cls, conv_state: "ConversationState | None" = None) -> Sequ... class _FileEditorAction (line 80) | class _FileEditorAction(Action): class _FileEditorObservation (line 90) | class _FileEditorObservation(Observation): class _FileEditorExecutor (line 94) | class _FileEditorExecutor(ToolExecutor[_FileEditorAction, _FileEditorObs... method __call__ (line 95) | def __call__( class _FileEditorTool (line 112) | class _FileEditorTool(ToolDefinition[_FileEditorAction, _FileEditorObser... method create (line 116) | def create(cls, conv_state: "ConversationState | None" = None) -> Sequ... function _make_agent (line 131) | def _make_agent(*tool_specs: str) -> Agent: function _model_response (line 141) | def _model_response(tool_name: str, arguments: dict[str, object]) -> Mod... function _run_tool_call (line 170) | def _run_tool_call( function test_bash_alias_executes_terminal_tool (line 193) | def test_bash_alias_executes_terminal_tool(tmp_path): function test_str_replace_alias_infers_file_editor_command (line 211) | def test_str_replace_alias_infers_file_editor_command(tmp_path): function test_shell_tool_name_falls_back_to_terminal (line 237) | def test_shell_tool_name_falls_back_to_terminal(tmp_path): function test_shell_tool_name_requires_exact_command_name (line 255) | def test_shell_tool_name_requires_exact_command_name(tmp_path, tool_name): function test_grep_without_pattern_does_not_fall_back_to_terminal (line 274) | def test_grep_without_pattern_does_not_fall_back_to_terminal(tmp_path): function test_shell_tool_name_does_not_fall_back_without_terminal (line 293) | def test_shell_tool_name_does_not_fall_back_without_terminal(tmp_path): function test_grep_arguments_can_fall_back_to_terminal (line 316) | def test_grep_arguments_can_fall_back_to_terminal(tmp_path): function test_grep_terminal_command_prefers_ripgrep (line 342) | def test_grep_terminal_command_prefers_ripgrep(monkeypatch, tmp_path): function test_grep_terminal_command_falls_back_to_grep (line 359) | def test_grep_terminal_command_falls_back_to_grep(monkeypatch, tmp_path): function test_grep_terminal_command_falls_back_to_python_on_windows (line 376) | def test_grep_terminal_command_falls_back_to_python_on_windows(monkeypat... function test_security_risk_typo_normalized (line 390) | def test_security_risk_typo_normalized(tmp_path): function test_file_editor_command_inferred_from_old_str (line 409) | def test_file_editor_command_inferred_from_old_str(tmp_path): function test_file_editor_empty_args_emits_error (line 435) | def test_file_editor_empty_args_emits_error(tmp_path): function test_str_replace_alias_error_message_shows_file_editor (line 457) | def test_str_replace_alias_error_message_shows_file_editor(tmp_path): function test_grep_pattern_with_shell_metacharacters_is_escaped (line 478) | def test_grep_pattern_with_shell_metacharacters_is_escaped(tmp_path): function test_explicitly_registered_tool_not_hijacked_by_alias (line 497) | def test_explicitly_registered_tool_not_hijacked_by_alias(): FILE: tests/sdk/agent/test_tool_call_recovery.py class _ViewAction (line 42) | class _ViewAction(Action): class _ViewObs (line 48) | class _ViewObs(Observation): method to_llm_content (line 52) | def to_llm_content(self) -> Sequence[TextContent]: class _ViewExec (line 56) | class _ViewExec(ToolExecutor[_ViewAction, _ViewObs]): method __call__ (line 57) | def __call__(self, action: _ViewAction, conversation=None) -> _ViewObs: class _ViewTool (line 61) | class _ViewTool(ToolDefinition[_ViewAction, _ViewObs]): method create (line 65) | def create(cls, conv_state: "ConversationState | None" = None) -> Sequ... function _make_agent (line 82) | def _make_agent(*, with_tool: bool = True) -> Agent: function _model_response (line 93) | def _model_response( function test_newline_whitespace_in_arguments_parses_ok (line 119) | def test_newline_whitespace_in_arguments_parses_ok(): function test_control_chars_in_string_values_still_sanitized (line 168) | def test_control_chars_in_string_values_still_sanitized(): function test_reasoning_only_response_injects_nudge (line 215) | def test_reasoning_only_response_injects_nudge(): function test_content_response_does_not_inject_nudge (line 248) | def test_content_response_does_not_inject_nudge(): function test_completely_empty_response_injects_nudge (line 271) | def test_completely_empty_response_injects_nudge(): FILE: tests/sdk/agent/test_tool_execution_error_handling.py class RaisingAction (line 29) | class RaisingAction(Action): class RaisingObservation (line 35) | class RaisingObservation(Observation): class RaisingExecutor (line 41) | class RaisingExecutor(ToolExecutor[RaisingAction, RaisingObservation]): method __call__ (line 44) | def __call__(self, action: RaisingAction, conversation=None) -> Raisin... class RaisingTool (line 48) | class RaisingTool(ToolDefinition[RaisingAction, RaisingObservation]): method create (line 54) | def create(cls, conv_state: "ConversationState | None" = None) -> Sequ... function test_tool_execution_valueerror_returns_error_event (line 69) | def test_tool_execution_valueerror_returns_error_event(): function test_conversation_continues_after_tool_execution_error (line 147) | def test_conversation_continues_after_tool_execution_error(): FILE: tests/sdk/agent/test_tool_validation_error_message.py class ValidationTestAction (line 32) | class ValidationTestAction(Action): class ValidationTestObservation (line 40) | class ValidationTestObservation(Observation): class ValidationTestExecutor (line 46) | class ValidationTestExecutor( method __call__ (line 51) | def __call__( class ValidationTestTool (line 57) | class ValidationTestTool( method create (line 65) | def create(cls, conv_state: "ConversationState | None" = None) -> Sequ... function test_validation_error_shows_keys_not_values (line 79) | def test_validation_error_shows_keys_not_values(): function test_unparseable_json_error_message (line 150) | def test_unparseable_json_error_message(): function _mock_llm_response_factory (line 209) | def _mock_llm_response_factory(tool_args: str): function test_tool_call_without_security_risk_succeeds (line 243) | def test_tool_call_without_security_risk_succeeds(): function test_omitted_security_risk_still_requires_confirmation (line 281) | def test_omitted_security_risk_still_requires_confirmation(): FILE: tests/sdk/config/test_llm_config.py function test_llm_config_defaults (line 10) | def test_llm_config_defaults(): function test_llm_config_custom_values (line 45) | def test_llm_config_custom_values(): function test_llm_config_secret_str (line 111) | def test_llm_config_secret_str(): function test_llm_config_aws_credentials (line 123) | def test_llm_config_aws_credentials(): function test_llm_config_openrouter_defaults (line 141) | def test_llm_config_openrouter_defaults(): function test_llm_config_post_init_openrouter_does_not_set_env (line 148) | def test_llm_config_post_init_openrouter_does_not_set_env(): function test_llm_config_post_init_reasoning_effort_default (line 173) | def test_llm_config_post_init_reasoning_effort_default(): function test_llm_config_post_init_azure_api_version (line 189) | def test_llm_config_post_init_azure_api_version(): function test_llm_config_post_init_aws_does_not_set_env (line 205) | def test_llm_config_post_init_aws_does_not_set_env(): function test_llm_config_log_completions_folder_default (line 230) | def test_llm_config_log_completions_folder_default(): function test_llm_config_extra_fields_permitted (line 237) | def test_llm_config_extra_fields_permitted(): function test_llm_config_validation (line 242) | def test_llm_config_validation(): function test_llm_config_model_variants (line 297) | def test_llm_config_model_variants(): function test_llm_config_boolean_fields (line 312) | def test_llm_config_boolean_fields(): function test_llm_config_optional_fields (line 334) | def test_llm_config_optional_fields(): FILE: tests/sdk/context/condenser/test_llm_summarizing_condenser.py function message_event (line 28) | def message_event(content: str) -> MessageEvent: function mock_llm (line 36) | def mock_llm() -> LLM: function test_default_values (line 96) | def test_default_values(mock_llm: LLM) -> None: function test_should_condense (line 112) | def test_should_condense(mock_llm: LLM) -> None: function test_condense_returns_view_when_no_condensation_needed (line 132) | def test_condense_returns_view_when_no_condensation_needed(mock_llm: LLM... function test_condense_returns_condensation_when_needed (line 148) | def test_condense_returns_condensation_when_needed(mock_llm: LLM) -> None: function test_get_condensation_with_previous_summary (line 177) | def test_get_condensation_with_previous_summary(mock_llm: LLM) -> None: function test_invalid_config (line 229) | def test_invalid_config(mock_llm: LLM) -> None: function test_get_condensation_does_not_pass_extra_body (line 244) | def test_get_condensation_does_not_pass_extra_body(mock_llm: LLM) -> None: function test_condense_with_agent_llm (line 264) | def test_condense_with_agent_llm(mock_llm: LLM) -> None: function test_condense_with_token_limit_exceeded (line 290) | def test_condense_with_token_limit_exceeded(mock_llm: LLM) -> None: function test_condense_with_request_and_events_reasons (line 339) | def test_condense_with_request_and_events_reasons(mock_llm: LLM) -> None: function test_condense_with_request_and_tokens_reasons (line 385) | def test_condense_with_request_and_tokens_reasons(mock_llm: LLM) -> None: function test_condense_with_events_and_tokens_reasons (line 432) | def test_condense_with_events_and_tokens_reasons(mock_llm: LLM) -> None: function test_condense_with_all_three_reasons (line 477) | def test_condense_with_all_three_reasons(mock_llm: LLM) -> None: function test_most_aggressive_condensation_chosen (line 530) | def test_most_aggressive_condensation_chosen(mock_llm: LLM) -> None: function test_generate_condensation_raises_on_zero_events (line 569) | def test_generate_condensation_raises_on_zero_events(mock_llm: LLM) -> N... function test_condensation_requirement_returns_none (line 592) | def test_condensation_requirement_returns_none( function test_condensation_requirement_returns_soft (line 618) | def test_condensation_requirement_returns_soft( function test_condensation_requirement_returns_hard (line 645) | def test_condensation_requirement_returns_hard( function test_condense_with_hard_requirement_and_no_condensation_available (line 663) | def test_condense_with_hard_requirement_and_no_condensation_available( function test_condense_with_soft_requirement_and_no_condensation_available (line 692) | def test_condense_with_soft_requirement_and_no_condensation_available( function test_minimum_progress_default_value (line 720) | def test_minimum_progress_default_value(mock_llm: LLM) -> None: function test_minimum_progress_custom_value (line 726) | def test_minimum_progress_custom_value(mock_llm: LLM) -> None: function test_minimum_progress_validation (line 741) | def test_minimum_progress_validation(mock_llm: LLM, invalid_value: float... function test_minimum_progress_threshold_not_met (line 747) | def test_minimum_progress_threshold_not_met(mock_llm: LLM) -> None: function test_minimum_progress_threshold_met (line 777) | def test_minimum_progress_threshold_met(mock_llm: LLM) -> None: FILE: tests/sdk/context/condenser/test_no_op_condenser.py function message_event (line 10) | def message_event(content: str) -> MessageEvent: function test_noop_condenser (line 17) | def test_noop_condenser() -> None: function test_noop_condenser_with_llm (line 33) | def test_noop_condenser_with_llm() -> None: FILE: tests/sdk/context/condenser/test_rolling_condenser.py function message_event (line 17) | def message_event(content: str) -> MessageEvent: class MockRollingCondenser (line 24) | class MockRollingCondenser(RollingCondenser): method __init__ (line 27) | def __init__( method condensation_requirement (line 35) | def condensation_requirement( method get_condensation (line 40) | def get_condensation( function test_rolling_condenser_returns_view_when_no_condensation_needed (line 56) | def test_rolling_condenser_returns_view_when_no_condensation_needed() ->... function test_rolling_condenser_returns_condensation_when_needed (line 75) | def test_rolling_condenser_returns_condensation_when_needed() -> None: function test_rolling_condenser_returns_view_on_no_condensation_available_exception (line 97) | def test_rolling_condenser_returns_view_on_no_condensation_available_exc... function test_rolling_condenser_with_agent_llm (line 128) | def test_rolling_condenser_with_agent_llm() -> None: function test_no_condensation_available_exception_message (line 152) | def test_no_condensation_available_exception_message() -> None: function test_default_hard_context_reset_raises_error (line 160) | def test_default_hard_context_reset_raises_error() -> None: class MockRollingCondenserWithHardReset (line 184) | class MockRollingCondenserWithHardReset(RollingCondenser): method __init__ (line 187) | def __init__(self, hard_reset_condensation: Condensation): method condensation_requirement (line 190) | def condensation_requirement( method get_condensation (line 195) | def get_condensation( method hard_context_reset (line 202) | def hard_context_reset( function test_hard_context_reset_condensation_is_returned (line 208) | def test_hard_context_reset_condensation_is_returned() -> None: FILE: tests/sdk/context/condenser/test_utils.py function message_event (line 14) | def message_event(content: str) -> MessageEvent: function mock_llm (line 23) | def mock_llm() -> LLM: class TestGetTotalTokenCount (line 44) | class TestGetTotalTokenCount: method test_empty_events (line 47) | def test_empty_events(self, mock_llm: LLM): method test_single_event (line 53) | def test_single_event(self, mock_llm: LLM): method test_multiple_events (line 59) | def test_multiple_events(self, mock_llm: LLM): method test_events_converted_to_messages (line 69) | def test_events_converted_to_messages(self, mock_llm: LLM): class TestGetShortestPrefixAboveTokenCount (line 82) | class TestGetShortestPrefixAboveTokenCount: method test_empty_events (line 85) | def test_empty_events(self, mock_llm: LLM): method test_no_prefix_exceeds_token_count (line 91) | def test_no_prefix_exceeds_token_count(self, mock_llm: LLM): method test_single_event_exceeds (line 100) | def test_single_event_exceeds(self, mock_llm: LLM): method test_multiple_events_needed (line 109) | def test_multiple_events_needed(self, mock_llm: LLM): method test_exact_boundary (line 121) | def test_exact_boundary(self, mock_llm: LLM): method test_all_events_needed (line 131) | def test_all_events_needed(self, mock_llm: LLM): class TestGetSuffixLengthForTokenReduction (line 143) | class TestGetSuffixLengthForTokenReduction: method test_empty_events (line 146) | def test_empty_events(self, mock_llm: LLM): method test_zero_token_reduction (line 152) | def test_zero_token_reduction(self, mock_llm: LLM): method test_negative_token_reduction (line 161) | def test_negative_token_reduction(self, mock_llm: LLM): method test_small_reduction (line 170) | def test_small_reduction(self, mock_llm: LLM): method test_large_reduction (line 184) | def test_large_reduction(self, mock_llm: LLM): method test_exact_reduction (line 196) | def test_exact_reduction(self, mock_llm: LLM): method test_impossible_reduction (line 208) | def test_impossible_reduction(self, mock_llm: LLM): method test_consistency_with_prefix_function (line 218) | def test_consistency_with_prefix_function(self, mock_llm: LLM): FILE: tests/sdk/context/test_agent_context.py class TestAgentContext (line 15) | class TestAgentContext: method test_agent_context_creation_empty (line 18) | def test_agent_context_creation_empty(self): method test_agent_context_creation_with_suffix (line 25) | def test_agent_context_creation_with_suffix(self): method test_skill_validation_duplicate_names (line 34) | def test_skill_validation_duplicate_names(self): method test_get_system_message_suffix_no_repo_skills (line 52) | def test_get_system_message_suffix_no_repo_skills(self): method test_get_system_message_suffix_available_skills_auto_added (line 68) | def test_get_system_message_suffix_available_skills_auto_added(self): method test_agentskills_format_progressive_disclosure (line 102) | def test_agentskills_format_progressive_disclosure(self): method test_disable_model_invocation_hides_skill_but_preserves_triggers (line 157) | def test_disable_model_invocation_hides_skill_but_preserves_triggers(s... method test_get_system_message_suffix_with_repo_skills (line 212) | def test_get_system_message_suffix_with_repo_skills(self): method test_get_system_message_suffix_with_custom_suffix (line 260) | def test_get_system_message_suffix_with_custom_suffix(self): method test_get_user_message_suffix_empty_query (line 283) | def test_get_user_message_suffix_empty_query(self): method test_get_user_message_suffix_no_triggers (line 298) | def test_get_user_message_suffix_no_triggers(self): method test_get_user_message_suffix_with_single_trigger (line 315) | def test_get_user_message_suffix_with_single_trigger(self): method test_get_user_message_suffix_with_multiple_triggers (line 352) | def test_get_user_message_suffix_with_multiple_triggers(self): method test_get_user_message_suffix_skip_skill_names (line 414) | def test_get_user_message_suffix_skip_skill_names(self): method test_get_user_message_suffix_multiline_content (line 432) | def test_get_user_message_suffix_multiline_content(self): method test_mixed_skill_types (line 474) | def test_mixed_skill_types(self): method test_case_insensitive_trigger_matching (line 531) | def test_case_insensitive_trigger_matching(self): method test_special_characters_in_content (line 568) | def test_special_characters_in_content(self): method test_empty_skill_content (line 608) | def test_empty_skill_content(self): method test_get_system_message_suffix_custom_suffix_only (line 643) | def test_get_system_message_suffix_custom_suffix_only(self): method test_get_user_message_suffix_empty_query_with_suffix (line 672) | def test_get_user_message_suffix_empty_query_with_suffix(self): method test_get_secret_infos_no_secrets (line 695) | def test_get_secret_infos_no_secrets(self): method test_get_secret_infos_none_secrets (line 701) | def test_get_secret_infos_none_secrets(self): method test_get_secret_infos_with_secrets (line 707) | def test_get_secret_infos_with_secrets(self): method test_get_secret_infos_with_lookup_secrets (line 737) | def test_get_secret_infos_with_lookup_secrets(self): method test_get_secret_infos_with_mixed_secret_types (line 771) | def test_get_secret_infos_with_mixed_secret_types(self): method test_get_system_message_suffix_with_secrets_only (line 797) | def test_get_system_message_suffix_with_secrets_only(self): method test_get_system_message_suffix_with_secrets_and_repo_skills (line 831) | def test_get_system_message_suffix_with_secrets_and_repo_skills(self): method test_get_system_message_suffix_with_secrets_and_custom_suffix (line 855) | def test_get_system_message_suffix_with_secrets_and_custom_suffix(self): method test_get_system_message_suffix_with_all_components (line 875) | def test_get_system_message_suffix_with_all_components(self): method test_get_system_message_suffix_secrets_order (line 910) | def test_get_system_message_suffix_secrets_order(self): method test_agent_context_creation_with_datetime_string (line 938) | def test_agent_context_creation_with_datetime_string(self): method test_agent_context_creation_with_datetime_object (line 945) | def test_agent_context_creation_with_datetime_object(self): method test_get_formatted_datetime_with_string (line 953) | def test_get_formatted_datetime_with_string(self): method test_get_formatted_datetime_with_datetime_object (line 961) | def test_get_formatted_datetime_with_datetime_object(self): method test_get_formatted_datetime_with_none (line 970) | def test_get_formatted_datetime_with_none(self): method test_agent_context_default_datetime (line 976) | def test_agent_context_default_datetime(self): method test_get_system_message_suffix_with_datetime_only (line 990) | def test_get_system_message_suffix_with_datetime_only(self): method test_get_system_message_suffix_with_datetime_and_repo_skills (line 1002) | def test_get_system_message_suffix_with_datetime_and_repo_skills(self): method test_get_system_message_suffix_with_datetime_and_secrets (line 1026) | def test_get_system_message_suffix_with_datetime_and_secrets(self): method test_get_system_message_suffix_with_all_components_including_datetime (line 1046) | def test_get_system_message_suffix_with_all_components_including_datet... method test_get_system_message_suffix_datetime_with_datetime_object (line 1078) | def test_get_system_message_suffix_datetime_with_datetime_object(self): function test_agent_context_secrets_raw_strings_redacted_by_default (line 1091) | def test_agent_context_secrets_raw_strings_redacted_by_default(): function test_agent_context_secrets_static_secret_still_masked (line 1105) | def test_agent_context_secrets_static_secret_still_masked(): FILE: tests/sdk/context/test_agent_context_model_specific.py function _write_repo_with_vendor_files (line 22) | def _write_repo_with_vendor_files(root: Path, baseline_source: str) -> N... function test_context_gates_claude_vendor_file (line 47) | def test_context_gates_claude_vendor_file(tmp_path: Path, baseline_sourc... function test_context_gates_gemini_vendor_file (line 61) | def test_context_gates_gemini_vendor_file(tmp_path: Path, baseline_sourc... function test_context_excludes_both_for_other_models (line 73) | def test_context_excludes_both_for_other_models(tmp_path: Path, baseline... function test_context_uses_canonical_name_for_vendor_match (line 85) | def test_context_uses_canonical_name_for_vendor_match( function test_context_includes_all_when_model_unknown (line 102) | def test_context_includes_all_when_model_unknown(tmp_path: Path, baselin... FILE: tests/sdk/context/test_agent_context_serialization.py function test_agent_context_serialization_roundtrip (line 14) | def test_agent_context_serialization_roundtrip(): FILE: tests/sdk/context/test_prompt_absolute_path.py function test_render_template_with_relative_path (line 14) | def test_render_template_with_relative_path(): function test_render_template_with_absolute_path (line 36) | def test_render_template_with_absolute_path(): function test_agent_with_absolute_system_prompt_path (line 57) | def test_agent_with_absolute_system_prompt_path(): function test_agent_with_relative_system_prompt_path (line 90) | def test_agent_with_relative_system_prompt_path(): function test_render_template_with_nonexistent_absolute_path (line 109) | def test_render_template_with_nonexistent_absolute_path(): function test_render_template_with_nonexistent_relative_path (line 121) | def test_render_template_with_nonexistent_relative_path(): FILE: tests/sdk/context/test_prompt_model_spec.py function _make_agent (line 5) | def _make_agent(model: str, **llm_kwargs) -> Agent: function test_system_prompt_includes_openai_gpt_5_model_specific_section (line 10) | def test_system_prompt_includes_openai_gpt_5_model_specific_section() ->... function test_system_prompt_includes_openai_gpt_5_codex_model_specific_section (line 19) | def test_system_prompt_includes_openai_gpt_5_codex_model_specific_sectio... function test_system_prompt_uses_canonical_name_for_detection (line 28) | def test_system_prompt_uses_canonical_name_for_detection() -> None: function test_system_prompt_respects_model_variant_override (line 37) | def test_system_prompt_respects_model_variant_override() -> None: function test_system_prompt_without_known_family_has_no_model_specific_section (line 46) | def test_system_prompt_without_known_family_has_no_model_specific_sectio... FILE: tests/sdk/context/view/conftest.py function message_event (line 23) | def message_event(content: str) -> MessageEvent: function create_action_event (line 31) | def create_action_event( function create_observation_event (line 66) | def create_observation_event( FILE: tests/sdk/context/view/properties/conftest.py function create_action_event (line 18) | def create_action_event( function create_observation_event (line 52) | def create_observation_event( function create_message_event (line 73) | def create_message_event(event_id: str, content: str) -> MessageEvent: function message_event (line 82) | def message_event(content: str) -> MessageEvent: function create_action_event_with_none_action (line 90) | def create_action_event_with_none_action( FILE: tests/sdk/context/view/properties/test_batch_atomicity.py class TestBatchAtomicityPropertyBase (line 15) | class TestBatchAtomicityPropertyBase: method setup_method (line 18) | def setup_method(self) -> None: class TestBatchAtomicityPropertyEnforcement (line 23) | class TestBatchAtomicityPropertyEnforcement(TestBatchAtomicityPropertyBa... method test_partial_batch_forgotten (line 26) | def test_partial_batch_forgotten(self) -> None: method test_complete_batch_forgotten (line 56) | def test_complete_batch_forgotten(self) -> None: method test_no_forgetting_preserves_batch (line 75) | def test_no_forgetting_preserves_batch(self) -> None: method test_multiple_batches (line 95) | def test_multiple_batches(self) -> None: method test_first_action_of_batch_forgotten (line 137) | def test_first_action_of_batch_forgotten(self) -> None: method test_middle_action_of_batch_forgotten (line 160) | def test_middle_action_of_batch_forgotten(self) -> None: method test_different_batches_independent (line 181) | def test_different_batches_independent(self) -> None: method test_single_action_batch (line 216) | def test_single_action_batch(self) -> None: method test_single_action_forgotten (line 234) | def test_single_action_forgotten(self) -> None: method test_partial_batch_across_batches (line 252) | def test_partial_batch_across_batches(self) -> None: class TestBatchAtomicityPropertyManipulationIndices (line 281) | class TestBatchAtomicityPropertyManipulationIndices(TestBatchAtomicityPr... method test_same_batch_no_manipulation_index (line 284) | def test_same_batch_no_manipulation_index(self) -> None: method test_different_batches_allow_manipulation (line 301) | def test_different_batches_allow_manipulation(self) -> None: method test_single_event_complete_indices (line 317) | def test_single_event_complete_indices(self) -> None: method test_empty_events_complete_indices (line 326) | def test_empty_events_complete_indices(self) -> None: FILE: tests/sdk/context/view/properties/test_observation_uniqueness.py function test_enforce_drops_late_observation_after_agent_error (line 23) | def test_enforce_drops_late_observation_after_agent_error() -> None: function test_enforce_no_duplicates_returns_empty (line 50) | def test_enforce_no_duplicates_returns_empty() -> None: function test_manipulation_indices_returns_complete_for_well_formed_view (line 65) | def test_manipulation_indices_returns_complete_for_well_formed_view() ->... function test_manipulation_indices_warns_but_does_not_crash_on_duplicates (line 80) | def test_manipulation_indices_warns_but_does_not_crash_on_duplicates(cap... FILE: tests/sdk/context/view/properties/test_tool_call_matching.py class TestToolCallMatchingBase (line 26) | class TestToolCallMatchingBase: method setup_method (line 29) | def setup_method(self) -> None: class TestToolCallMatchingPropertyEnforcement (line 34) | class TestToolCallMatchingPropertyEnforcement(TestToolCallMatchingBase): method test_empty_list (line 37) | def test_empty_list(self) -> None: method test_no_tool_events (line 42) | def test_no_tool_events(self) -> None: method test_matched_pairs (line 53) | def test_matched_pairs(self) -> None: method test_unmatched_action (line 92) | def test_unmatched_action(self) -> None: method test_unmatched_observation (line 125) | def test_unmatched_observation(self) -> None: method test_mixed_scenario (line 157) | def test_mixed_scenario(self) -> None: method test_with_user_reject_observation (line 214) | def test_with_user_reject_observation(self) -> None: method test_with_agent_error_event (line 243) | def test_with_agent_error_event(self) -> None: method test_mixed_observation_types (line 271) | def test_mixed_observation_types(self) -> None: method test_action_with_none_action_matched_by_agent_error (line 325) | def test_action_with_none_action_matched_by_agent_error(self) -> None: class TestToolCallMatchingPropertyManipulationIndices (line 360) | class TestToolCallMatchingPropertyManipulationIndices(TestToolCallMatchi... method test_single_event_complete_indices (line 363) | def test_single_event_complete_indices(self) -> None: method test_matched_pair_no_index_between (line 372) | def test_matched_pair_no_index_between(self) -> None: method test_allow_index_between_pairs (line 390) | def test_allow_index_between_pairs(self) -> None: method test_empty_events (line 426) | def test_empty_events(self) -> None: FILE: tests/sdk/context/view/properties/test_tool_loop_atomicity.py class TestToolLoopAtomicityPropertyBase (line 28) | class TestToolLoopAtomicityPropertyBase: method setup_method (line 31) | def setup_method(self) -> None: class TestToolLoopAtomicityPropertyEnforcement (line 36) | class TestToolLoopAtomicityPropertyEnforcement(TestToolLoopAtomicityProp... method test_partial_tool_loop_forgotten (line 39) | def test_partial_tool_loop_forgotten(self) -> None: method test_complete_tool_loop_forgotten (line 68) | def test_complete_tool_loop_forgotten(self) -> None: method test_no_forgetting_preserves_tool_loop (line 84) | def test_no_forgetting_preserves_tool_loop(self) -> None: method test_tool_loop_between_non_tool_loop_events (line 102) | def test_tool_loop_between_non_tool_loop_events(self) -> None: method test_first_event_of_tool_loop_forgotten (line 133) | def test_first_event_of_tool_loop_forgotten(self) -> None: method test_middle_event_of_tool_loop_forgotten (line 157) | def test_middle_event_of_tool_loop_forgotten(self) -> None: method test_multiple_separate_tool_loops (line 181) | def test_multiple_separate_tool_loops(self) -> None: method test_single_action_observation_pair (line 214) | def test_single_action_observation_pair(self) -> None: method test_single_action_forgotten (line 230) | def test_single_action_forgotten(self) -> None: method test_actions_without_thinking_are_not_tool_loops (line 246) | def test_actions_without_thinking_are_not_tool_loops(self) -> None: class TestToolLoopAtomicityPropertyManipulationIndices (line 269) | class TestToolLoopAtomicityPropertyManipulationIndices( method test_no_manipulation_within_tool_loop (line 274) | def test_no_manipulation_within_tool_loop(self) -> None: method test_manipulation_allowed_between_tool_loops (line 289) | def test_manipulation_allowed_between_tool_loops(self) -> None: method test_manipulation_allowed_before_first_tool_loop (line 305) | def test_manipulation_allowed_before_first_tool_loop(self) -> None: method test_single_event_complete_indices (line 318) | def test_single_event_complete_indices(self) -> None: method test_empty_events_complete_indices (line 327) | def test_empty_events_complete_indices(self) -> None: method test_tool_loop_with_message_breaks_at_boundary (line 334) | def test_tool_loop_with_message_breaks_at_boundary(self) -> None: method test_parallel_actions_in_tool_loop (line 349) | def test_parallel_actions_in_tool_loop(self) -> None: method test_no_tool_loop_without_thinking_blocks (line 365) | def test_no_tool_loop_without_thinking_blocks(self) -> None: FILE: tests/sdk/context/view/test_manipulation_indices.py function test_complete_empty_list (line 5) | def test_complete_empty_list() -> None: function test_complete_single_message_event (line 11) | def test_complete_single_message_event() -> None: function test_complete_multiple_message_events (line 17) | def test_complete_multiple_message_events() -> None: FILE: tests/sdk/context/view/test_view.py function test_view_preserves_uncondensed_lists (line 15) | def test_view_preserves_uncondensed_lists() -> None: function test_view_forgets_events (line 25) | def test_view_forgets_events() -> None: function test_view_keeps_non_forgotten_events (line 45) | def test_view_keeps_non_forgotten_events() -> None: function test_view_inserts_summary (line 71) | def test_view_inserts_summary() -> None: function test_no_condensation_action_in_view (line 112) | def test_no_condensation_action_in_view() -> None: function test_unhandled_condensation_request_with_no_condensation (line 139) | def test_unhandled_condensation_request_with_no_condensation() -> None: function test_handled_condensation_request_with_condensation_action (line 160) | def test_handled_condensation_request_with_condensation_action() -> None: function test_multiple_condensation_requests_pattern (line 193) | def test_multiple_condensation_requests_pattern() -> None: function test_condensation_action_before_request (line 218) | def test_condensation_action_before_request() -> None: function test_no_condensation_events (line 244) | def test_no_condensation_events() -> None: function test_condensation_request_always_removed_from_view (line 263) | def test_condensation_request_always_removed_from_view() -> None: FILE: tests/sdk/context/view/test_view_append_event.py class TestAppendLLMConvertibleEvent (line 20) | class TestAppendLLMConvertibleEvent: method test_append_message_event_to_empty_view (line 21) | def test_append_message_event_to_empty_view(self) -> None: method test_append_multiple_message_events (line 29) | def test_append_multiple_message_events(self) -> None: method test_append_action_event (line 38) | def test_append_action_event(self) -> None: method test_append_observation_event (line 48) | def test_append_observation_event(self) -> None: method test_append_does_not_change_unhandled_flag (line 56) | def test_append_does_not_change_unhandled_flag(self) -> None: class TestAppendCondensation (line 66) | class TestAppendCondensation: method test_condensation_forgets_events (line 67) | def test_condensation_forgets_events(self) -> None: method test_condensation_forgets_all_events (line 82) | def test_condensation_forgets_all_events(self) -> None: method test_condensation_on_empty_view (line 97) | def test_condensation_on_empty_view(self) -> None: method test_condensation_with_no_forgotten_ids (line 107) | def test_condensation_with_no_forgotten_ids(self) -> None: method test_condensation_inserts_summary (line 122) | def test_condensation_inserts_summary(self) -> None: method test_condensation_inserts_summary_at_end (line 142) | def test_condensation_inserts_summary_at_end(self) -> None: method test_condensation_clears_unhandled_flag (line 162) | def test_condensation_clears_unhandled_flag(self) -> None: method test_condensation_clears_flag_even_without_prior_request (line 175) | def test_condensation_clears_flag_even_without_prior_request(self) -> ... method test_condensation_not_added_to_events (line 187) | def test_condensation_not_added_to_events(self) -> None: class TestAppendCondensationRequest (line 201) | class TestAppendCondensationRequest: method test_sets_unhandled_flag (line 202) | def test_sets_unhandled_flag(self) -> None: method test_not_added_to_events (line 208) | def test_not_added_to_events(self) -> None: method test_multiple_requests_keep_flag_true (line 217) | def test_multiple_requests_keep_flag_true(self) -> None: class TestAppendNonLLMConvertibleEvent (line 229) | class TestAppendNonLLMConvertibleEvent: method test_skipped_silently (line 230) | def test_skipped_silently(self) -> None: method test_does_not_affect_unhandled_flag (line 237) | def test_does_not_affect_unhandled_flag(self) -> None: method test_events_unchanged_after_skip (line 243) | def test_events_unchanged_after_skip(self) -> None: class TestAppendEventInteractions (line 257) | class TestAppendEventInteractions: method test_request_then_condensation_clears_flag (line 258) | def test_request_then_condensation_clears_flag(self) -> None: method test_condensation_then_request_sets_flag (line 271) | def test_condensation_then_request_sets_flag(self) -> None: method test_multiple_condensations_in_sequence (line 284) | def test_multiple_condensations_in_sequence(self) -> None: method test_interleaved_messages_and_condensations (line 308) | def test_interleaved_messages_and_condensations(self) -> None: method test_non_llm_events_interspersed (line 328) | def test_non_llm_events_interspersed(self) -> None: method test_full_lifecycle (line 342) | def test_full_lifecycle(self) -> None: FILE: tests/sdk/context/view/test_view_batch_atomicity.py function test_batch_atomicity_partial_batch_forgotten (line 26) | def test_batch_atomicity_partial_batch_forgotten() -> None: function test_batch_atomicity_complete_batch_forgotten (line 93) | def test_batch_atomicity_complete_batch_forgotten() -> None: function test_batch_atomicity_no_forgetting_preserves_batch (line 135) | def test_batch_atomicity_no_forgetting_preserves_batch() -> None: function test_batch_atomicity_multiple_batches (line 180) | def test_batch_atomicity_multiple_batches() -> None: function test_batch_atomicity_single_action_batch (line 243) | def test_batch_atomicity_single_action_batch() -> None: function test_batch_atomicity_no_thinking_blocks (line 273) | def test_batch_atomicity_no_thinking_blocks() -> None: FILE: tests/sdk/context/view/test_view_condensation_batch_atomicity.py function test_batch_atomicity_when_observation_forgotten (line 29) | def test_batch_atomicity_when_observation_forgotten() -> None: function test_batch_atomicity_when_multiple_observations_forgotten (line 93) | def test_batch_atomicity_when_multiple_observations_forgotten() -> None: function test_batch_atomicity_different_batches_independent (line 135) | def test_batch_atomicity_different_batches_independent() -> None: function test_single_action_batch_observation_forgotten (line 184) | def test_single_action_batch_observation_forgotten() -> None: FILE: tests/sdk/context/view/test_view_manipulation_indices.py function test_empty_list (line 19) | def test_empty_list() -> None: function test_single_message_event (line 25) | def test_single_message_event() -> None: function test_multiple_message_events (line 34) | def test_multiple_message_events() -> None: function test_single_action_observation_pair (line 47) | def test_single_action_observation_pair() -> None: function test_action_observation_with_message_events (line 59) | def test_action_observation_with_message_events() -> None: function test_batch_of_actions_simple (line 73) | def test_batch_of_actions_simple() -> None: function test_multiple_separate_batches (line 95) | def test_multiple_separate_batches() -> None: function test_batches_separated_by_messages (line 125) | def test_batches_separated_by_messages() -> None: function test_single_action_in_batch (line 148) | def test_single_action_in_batch() -> None: function test_complex_interleaved_scenario (line 160) | def test_complex_interleaved_scenario() -> None: function test_observations_extend_batch_range (line 225) | def test_observations_extend_batch_range() -> None: function test_batch_with_all_observations (line 244) | def test_batch_with_all_observations() -> None: function test_interleaved_batches_and_messages (line 263) | def test_interleaved_batches_and_messages() -> None: function test_three_action_batch (line 284) | def test_three_action_batch() -> None: function test_consecutive_atomic_units (line 301) | def test_consecutive_atomic_units() -> None: function test_forgetting_range_selection (line 324) | def test_forgetting_range_selection() -> None: FILE: tests/sdk/context/view/test_view_multi_summary.py function test_multiple_summaries_at_different_offsets (line 28) | def test_multiple_summaries_at_different_offsets() -> None: function test_multiple_summaries_from_sequential_condensations (line 80) | def test_multiple_summaries_from_sequential_condensations() -> None: function test_summaries_preserve_order_and_content (line 140) | def test_summaries_preserve_order_and_content() -> None: function test_forget_first_summary_keeps_second (line 199) | def test_forget_first_summary_keeps_second() -> None: function test_forget_middle_summary_keeps_others (line 255) | def test_forget_middle_summary_keeps_others() -> None: function test_forget_most_recent_summary (line 321) | def test_forget_most_recent_summary() -> None: function test_forget_summary_adjusts_later_summary_positions (line 369) | def test_forget_summary_adjusts_later_summary_positions() -> None: function test_forget_multiple_summaries_simultaneously (line 423) | def test_forget_multiple_summaries_simultaneously() -> None: function test_forget_all_summaries (line 486) | def test_forget_all_summaries() -> None: function test_sequential_condensations_each_forget_summary (line 536) | def test_sequential_condensations_each_forget_summary() -> None: function test_summary_events_have_stable_identifiers (line 613) | def test_summary_events_have_stable_identifiers() -> None: function test_condensation_tracks_its_summary_event (line 648) | def test_condensation_tracks_its_summary_event() -> None: function test_can_reference_summary_from_previous_condensation (line 691) | def test_can_reference_summary_from_previous_condensation() -> None: function test_summary_offset_is_absolute_in_final_view (line 742) | def test_summary_offset_is_absolute_in_final_view() -> None: function test_summary_offset_zero_inserts_at_beginning (line 786) | def test_summary_offset_zero_inserts_at_beginning() -> None: function test_summary_offset_at_end_of_events (line 806) | def test_summary_offset_at_end_of_events() -> None: function test_multiple_summaries_with_same_offset (line 827) | def test_multiple_summaries_with_same_offset() -> None: function test_forget_events_and_summary_together (line 871) | def test_forget_events_and_summary_together() -> None: function test_summary_offset_remains_valid_after_forgetting_events (line 919) | def test_summary_offset_remains_valid_after_forgetting_events() -> None: function test_interleaved_events_and_summaries (line 956) | def test_interleaved_events_and_summaries() -> None: function test_condensation_without_summary_no_summary_event_created (line 1021) | def test_condensation_without_summary_no_summary_event_created() -> None: function test_empty_view_with_only_summaries (line 1046) | def test_empty_view_with_only_summaries() -> None: function test_forget_nonexistent_summary_is_noop (line 1070) | def test_forget_nonexistent_summary_is_noop() -> None: function test_multiple_condensations_same_summary_offset (line 1104) | def test_multiple_condensations_same_summary_offset() -> None: FILE: tests/sdk/context/view/test_view_tool_loop_boundaries.py function test_single_batch_with_thinking (line 16) | def test_single_batch_with_thinking(): function test_tool_loop_multiple_batches (line 34) | def test_tool_loop_multiple_batches(): function test_tool_loop_ends_at_non_batch_event (line 62) | def test_tool_loop_ends_at_non_batch_event(): function test_multiple_separate_tool_loops (line 90) | def test_multiple_separate_tool_loops(): function test_parallel_tool_calls_in_tool_loop (line 119) | def test_parallel_tool_calls_in_tool_loop(): function test_empty_events (line 145) | def test_empty_events(): function test_only_user_messages (line 152) | def test_only_user_messages(): FILE: tests/sdk/conversation/conftest.py function create_mock_http_client (line 6) | def create_mock_http_client(conversation_id: str | None = None): FILE: tests/sdk/conversation/local/test_agent_status_transition.py class StatusTransitionMockAction (line 41) | class StatusTransitionMockAction(Action): class StatusTransitionMockObservation (line 47) | class StatusTransitionMockObservation(Observation): method to_llm_content (line 53) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class StatusCheckingExecutor (line 57) | class StatusCheckingExecutor( method __init__ (line 62) | def __init__(self, status_during_execution: list[ConversationExecution... method __call__ (line 67) | def __call__( class StatusTransitionTestTool (line 76) | class StatusTransitionTestTool( method create (line 84) | def create( function test_execution_status_transitions_to_running_from_idle (line 97) | def test_execution_status_transitions_to_running_from_idle(): function test_execution_status_is_running_during_execution_from_idle (line 136) | def test_execution_status_is_running_during_execution_from_idle(): function test_execution_status_transitions_to_running_from_paused (line 223) | def test_execution_status_transitions_to_running_from_paused(): function test_execution_status_transitions_from_waiting_for_confirmation (line 255) | def test_execution_status_transitions_from_waiting_for_confirmation(): function test_execution_status_finished_to_idle_to_running (line 306) | def test_execution_status_finished_to_idle_to_running(): function test_run_exits_immediately_when_already_finished (line 336) | def test_run_exits_immediately_when_already_finished(): function test_run_recovers_from_stuck (line 363) | def test_run_recovers_from_stuck(): function test_send_message_resets_stuck_to_idle (line 393) | def test_send_message_resets_stuck_to_idle(): function test_execution_status_error_on_max_iterations (line 419) | def test_execution_status_error_on_max_iterations(): function test_execution_status_finished_on_final_iteration (line 480) | def test_execution_status_finished_on_final_iteration(): FILE: tests/sdk/conversation/local/test_confirmation_mode.py class MockConfirmationModeAction (line 49) | class MockConfirmationModeAction(Action): class MockConfirmationModeObservation (line 55) | class MockConfirmationModeObservation(Observation): method to_llm_content (line 61) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class TestExecutor (line 65) | class TestExecutor( method __call__ (line 70) | def __call__( class ConfirmationTestTool (line 78) | class ConfirmationTestTool( method create (line 86) | def create(cls, conv_state=None, **params) -> Sequence["ConfirmationTe... function _make_tool (line 97) | def _make_tool(conv_state=None, **params) -> Sequence[ToolDefinition]: class TestConfirmationMode (line 102) | class TestConfirmationMode: method setup_method (line 105) | def setup_method(self): method _mock_message_only (line 143) | def _mock_message_only(self, text: str = "Hello, how can I help you?")... method _make_pending_action (line 157) | def _make_pending_action(self) -> None: method _mock_action_once (line 175) | def _mock_action_once( method _mock_finish_action (line 205) | def _mock_finish_action(self, message: str = "Task completed") -> Magi... method _mock_think_action (line 234) | def _mock_think_action(self, thought: str = "Let me think about this")... method _mock_multiple_actions_with_finish (line 263) | def _mock_multiple_actions_with_finish(self) -> MagicMock: method _create_test_action (line 304) | def _create_test_action(self, call_id="call_1", command="test_command"): method test_mock_observation (line 332) | def test_mock_observation(self): method test_confirmation_mode_basic_functionality (line 351) | def test_confirmation_mode_basic_functionality(self): method test_getting_unmatched_events (line 380) | def test_getting_unmatched_events(self): method test_message_only_in_confirmation_mode_does_not_wait (line 432) | def test_message_only_in_confirmation_mode_does_not_wait(self): method test_action_then_confirm_or_reject (line 460) | def test_action_then_confirm_or_reject(self, should_reject: bool): method test_single_finish_action_skips_confirmation_entirely (line 513) | def test_single_finish_action_skips_confirmation_entirely(self): method test_think_and_finish_action_skips_confirmation_entirely (line 558) | def test_think_and_finish_action_skips_confirmation_entirely(self): method test_pause_during_confirmation_preserves_waiting_status (line 606) | def test_pause_during_confirmation_preserves_waiting_status(self): method test_is_confirmation_mode_active_property (line 658) | def test_is_confirmation_mode_active_property(self): FILE: tests/sdk/conversation/local/test_conversation_core.py function create_test_agent (line 18) | def create_test_agent() -> Agent: function create_test_event (line 24) | def create_test_event(event_id: str, content: str = "Test content") -> M... function test_conversation_basic_creation (line 34) | def test_conversation_basic_creation(): function test_conversation_event_log_functionality (line 48) | def test_conversation_event_log_functionality(): function test_conversation_state_persistence (line 81) | def test_conversation_state_persistence(): function test_conversation_with_custom_id (line 112) | def test_conversation_with_custom_id(): function test_conversation_event_id_validation (line 129) | def test_conversation_event_id_validation(): function test_conversation_large_event_handling (line 154) | def test_conversation_large_event_handling(): function test_conversation_error_handling (line 222) | def test_conversation_error_handling(): function test_conversation_memory_vs_local_filestore (line 235) | def test_conversation_memory_vs_local_filestore(): FILE: tests/sdk/conversation/local/test_conversation_default_callback.py class ConversationDefaultCallbackDummyAgent (line 14) | class ConversationDefaultCallbackDummyAgent(AgentBase): method __init__ (line 15) | def __init__(self): method init_state (line 21) | def init_state( method step (line 29) | def step( function test_default_callback_appends_on_init (line 43) | def test_default_callback_appends_on_init(): function test_send_message_appends_once (line 59) | def test_send_message_appends_once(): FILE: tests/sdk/conversation/local/test_conversation_id.py class ConversationIdDummyAgent (line 17) | class ConversationIdDummyAgent(AgentBase): method __init__ (line 18) | def __init__(self): method init_state (line 24) | def init_state( method step (line 32) | def step( function test_conversation_has_unique_id (line 41) | def test_conversation_has_unique_id(): function test_conversation_ids_are_unique (line 51) | def test_conversation_ids_are_unique(): function test_conversation_id_persists (line 67) | def test_conversation_id_persists(): function test_conversation_pins_llm_prompt_cache_key_to_id (line 82) | def test_conversation_pins_llm_prompt_cache_key_to_id(): FILE: tests/sdk/conversation/local/test_conversation_path_types.py function create_test_agent (line 14) | def create_test_agent() -> Agent: function test_conversation_with_path_workspace (line 20) | def test_conversation_with_path_workspace(): function test_conversation_with_path_persistence_dir (line 40) | def test_conversation_with_path_persistence_dir(): function test_conversation_with_both_path_types (line 66) | def test_conversation_with_both_path_types(): function test_local_workspace_with_path (line 94) | def test_local_workspace_with_path(): function test_conversation_with_localworkspace_from_path (line 108) | def test_conversation_with_localworkspace_from_path(): FILE: tests/sdk/conversation/local/test_conversation_pause_functionality.py class PauseFunctionalityMockAction (line 49) | class PauseFunctionalityMockAction(Action): class PauseFunctionalityMockObservation (line 55) | class PauseFunctionalityMockObservation(Observation): method to_llm_content (line 61) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class BlockingExecutor (line 65) | class BlockingExecutor( method __init__ (line 68) | def __init__(self, step_entered: threading.Event): method __call__ (line 71) | def __call__( class TestExecutor (line 81) | class TestExecutor( method __call__ (line 86) | def __call__( class PauseFunctionalityTestTool (line 94) | class PauseFunctionalityTestTool( method create (line 102) | def create( function _make_tool (line 115) | def _make_tool(conv_state=None, **params) -> Sequence[ToolDefinition]: class BlockingTestTool (line 120) | class BlockingTestTool( method create (line 128) | def create( class TestPauseFunctionality (line 143) | class TestPauseFunctionality: method setup_method (line 146) | def setup_method(self): method test_pause_basic_functionality (line 161) | def test_pause_basic_functionality(self): method test_pause_during_normal_execution (line 185) | def test_pause_during_normal_execution(self, mock_completion): method test_resume_paused_agent (line 232) | def test_resume_paused_agent(self, mock_completion): method test_pause_with_confirmation_mode (line 277) | def test_pause_with_confirmation_mode(self, mock_completion): method test_multiple_pause_calls_create_one_event (line 343) | def test_multiple_pause_calls_create_one_event(self): method test_pause_while_running_continuous_actions (line 369) | def test_pause_while_running_continuous_actions(self, mock_completion): FILE: tests/sdk/conversation/local/test_conversation_send_message.py class SendMessageDummyAgent (line 20) | class SendMessageDummyAgent(AgentBase): method __init__ (line 21) | def __init__(self): method init_state (line 27) | def init_state( method step (line 35) | def step( function test_send_message_with_string_creates_correct_message (line 49) | def test_send_message_with_string_creates_correct_message(): function test_send_message_string_equivalent_to_message_object (line 73) | def test_send_message_string_equivalent_to_message_object(): function test_send_message_with_empty_string (line 110) | def test_send_message_with_empty_string(): function test_send_message_with_multiline_string (line 126) | def test_send_message_with_multiline_string(): function test_send_message_with_message_object (line 143) | def test_send_message_with_message_object(): function test_acp_send_message_defers_initialization_until_run (line 164) | def test_acp_send_message_defers_initialization_until_run(tmp_path): FILE: tests/sdk/conversation/local/test_conversation_visualize_param.py function create_test_event (line 17) | def create_test_event(content: str = "Test event content") -> MessageEvent: function mock_agent (line 26) | def mock_agent(): function test_conversation_with_default_visualizer (line 33) | def test_conversation_with_default_visualizer(mock_agent): function test_conversation_with_visualize_false (line 55) | def test_conversation_with_visualize_false(mock_agent): function test_conversation_default_visualize_is_true (line 76) | def test_conversation_default_visualize_is_true(mock_agent): function test_conversation_with_custom_callbacks_and_default_visualizer (line 86) | def test_conversation_with_custom_callbacks_and_default_visualizer(mock_... function test_conversation_with_custom_callbacks_and_visualize_false (line 116) | def test_conversation_with_custom_callbacks_and_visualize_false(mock_age... function test_conversation_callback_order (line 148) | def test_conversation_callback_order(mock_agent): function test_conversation_no_callbacks_with_default_visualizer (line 191) | def test_conversation_no_callbacks_with_default_visualizer(mock_agent): function test_conversation_no_callbacks_with_visualize_false (line 215) | def test_conversation_no_callbacks_with_visualize_false(mock_agent): function test_conversation_with_custom_visualizer_instance (line 239) | def test_conversation_with_custom_visualizer_instance(mock_agent): function test_conversation_with_custom_visualizer_and_callbacks (line 267) | def test_conversation_with_custom_visualizer_and_callbacks(mock_agent): function test_conversation_with_visualize_none (line 304) | def test_conversation_with_visualize_none(mock_agent): function test_conversation_with_visualizer_class (line 325) | def test_conversation_with_visualizer_class(mock_agent): FILE: tests/sdk/conversation/local/test_execute_tool.py class ExecuteToolTestAction (line 27) | class ExecuteToolTestAction(Action): class ExecuteToolTestObservation (line 33) | class ExecuteToolTestObservation(Observation): class ExecuteToolTestExecutor (line 40) | class ExecuteToolTestExecutor( method __init__ (line 45) | def __init__(self, prefix: str = "executed"): method __call__ (line 49) | def __call__( class ExecuteToolTestTool (line 61) | class ExecuteToolTestTool( method create (line 67) | def create(cls, conv_state=None, **params): function _tool_registry_snapshot (line 80) | def _tool_registry_snapshot(): class ExecuteToolDummyAgent (line 93) | class ExecuteToolDummyAgent(AgentBase): method __init__ (line 96) | def __init__(self, tools=None): method init_state (line 102) | def init_state( method step (line 113) | def step( function test_execute_tool_basic (line 127) | def test_execute_tool_basic(): function test_execute_tool_initializes_agent (line 144) | def test_execute_tool_initializes_agent(): function test_execute_tool_before_send_message (line 160) | def test_execute_tool_before_send_message(): function test_execute_tool_after_send_message (line 177) | def test_execute_tool_after_send_message(): function test_execute_tool_not_found (line 193) | def test_execute_tool_not_found(): function test_execute_tool_multiple_calls (line 207) | def test_execute_tool_multiple_calls(): function test_execute_tool_with_conversation_context (line 220) | def test_execute_tool_with_conversation_context(): FILE: tests/sdk/conversation/local/test_fork.py function _agent (line 17) | def _agent() -> Agent: function _msg (line 24) | def _msg(event_id: str, text: str = "hi") -> MessageEvent: function test_fork_creates_new_id (line 32) | def test_fork_creates_new_id(): function test_fork_with_explicit_id (line 42) | def test_fork_with_explicit_id(): function test_fork_copies_events (line 52) | def test_fork_copies_events(): function test_fork_source_unmodified (line 67) | def test_fork_source_unmodified(): function test_fork_execution_status_is_idle (line 81) | def test_fork_execution_status_is_idle(): function test_fork_resets_metrics_by_default (line 90) | def test_fork_resets_metrics_by_default(): function test_fork_preserves_metrics_when_requested (line 100) | def test_fork_preserves_metrics_when_requested(): function test_fork_copies_agent_state (line 117) | def test_fork_copies_agent_state(): function test_fork_accepts_replacement_agent (line 131) | def test_fork_accepts_replacement_agent(): function test_fork_with_tags (line 151) | def test_fork_with_tags(): function test_fork_with_title_sets_tag (line 160) | def test_fork_with_title_sets_tag(): function test_fork_shares_workspace (line 169) | def test_fork_shares_workspace(): function test_fork_event_deep_copy_isolation (line 178) | def test_fork_event_deep_copy_isolation(): function test_fork_persistence_path_no_doubling (line 197) | def test_fork_persistence_path_no_doubling(): function test_fork_persisted_events_survive_reload (line 219) | def test_fork_persisted_events_survive_reload(): function test_fork_default_does_not_clobber_source_cache_key (line 255) | def test_fork_default_does_not_clobber_source_cache_key(): function test_fork_with_aliased_agent_does_not_clobber_source_cache_key (line 268) | def test_fork_with_aliased_agent_does_not_clobber_source_cache_key(): FILE: tests/sdk/conversation/local/test_rerun_actions.py function _make_action_event (line 29) | def _make_action_event( class RerunTestAction (line 55) | class RerunTestAction(Action): class RerunTestObservation (line 61) | class RerunTestObservation(Observation): class RerunTestExecutor (line 68) | class RerunTestExecutor(ToolExecutor[RerunTestAction, RerunTestObservati... method __call__ (line 71) | def __call__( class RerunTestTool (line 86) | class RerunTestTool(ToolDefinition[RerunTestAction, RerunTestObservation]): method create (line 90) | def create(cls, conv_state=None, **params): function _reset_execution_counts (line 102) | def _reset_execution_counts(): function _tool_registry_isolation (line 110) | def _tool_registry_isolation(monkeypatch: pytest.MonkeyPatch): class RerunDummyAgent (line 128) | class RerunDummyAgent(AgentBase): method __init__ (line 131) | def __init__(self, tools=None): method init_state (line 137) | def init_state( method step (line 146) | def step( function test_rerun_actions_empty_conversation (line 160) | def test_rerun_actions_empty_conversation(): function test_rerun_actions_basic (line 170) | def test_rerun_actions_basic(): function test_rerun_actions_preserves_original_observations (line 196) | def test_rerun_actions_preserves_original_observations(): function test_rerun_actions_skips_none_actions (line 220) | def test_rerun_actions_skips_none_actions(): function test_rerun_actions_missing_tool_raises (line 253) | def test_rerun_actions_missing_tool_raises(): function test_rerun_can_be_called_manually (line 272) | def test_rerun_can_be_called_manually(): class FileWriteAction (line 302) | class FileWriteAction(Action): class FileWriteObservation (line 309) | class FileWriteObservation(Observation): class FileWriteExecutor (line 316) | class FileWriteExecutor(ToolExecutor[FileWriteAction, FileWriteObservati... method __call__ (line 319) | def __call__( class FileWriteTool (line 334) | class FileWriteTool(ToolDefinition[FileWriteAction, FileWriteObservation]): method create (line 338) | def create(cls, conv_state=None, **params): class FileCreateAction (line 349) | class FileCreateAction(Action): class FileCreateObservation (line 356) | class FileCreateObservation(Observation): class FileCreateExecutor (line 363) | class FileCreateExecutor(ToolExecutor[FileCreateAction, FileCreateObserv... method __call__ (line 366) | def __call__( class FileCreateTool (line 388) | class FileCreateTool(ToolDefinition[FileCreateAction, FileCreateObservat... method create (line 392) | def create(cls, conv_state=None, **params): class FailingAction (line 403) | class FailingAction(Action): class FailingObservation (line 409) | class FailingObservation(Observation): class FailingExecutor (line 415) | class FailingExecutor(ToolExecutor[FailingAction, FailingObservation]): method __call__ (line 418) | def __call__( class FailingTool (line 426) | class FailingTool(ToolDefinition[FailingAction, FailingObservation]): method create (line 430) | def create(cls, conv_state=None, **params): function test_rerun_reproduces_file_state (line 441) | def test_rerun_reproduces_file_state(tmp_path: Path, monkeypatch: pytest... function test_rerun_non_idempotent_with_log (line 477) | def test_rerun_non_idempotent_with_log(tmp_path: Path, monkeypatch: pyte... function test_rerun_early_exit_on_failure (line 532) | def test_rerun_early_exit_on_failure(tmp_path: Path, monkeypatch: pytest... function test_rerun_multiple_files (line 594) | def test_rerun_multiple_files(tmp_path: Path, monkeypatch: pytest.Monkey... FILE: tests/sdk/conversation/local/test_run_exception_includes_conversation_id.py class FailingAgent (line 15) | class FailingAgent(AgentBase): method step (line 16) | def step( function test_run_raises_conversation_run_error_with_id (line 26) | def test_run_raises_conversation_run_error_with_id(): function test_run_error_includes_persistence_dir_and_issue_url (line 45) | def test_run_error_includes_persistence_dir_and_issue_url(): function test_run_error_without_persistence_dir (line 73) | def test_run_error_without_persistence_dir(): FILE: tests/sdk/conversation/local/test_span_double_ending.py function create_test_agent (line 15) | def create_test_agent() -> Agent: function test_no_double_span_ending_warning (line 21) | def test_no_double_span_ending_warning(caplog): function test_span_ending_with_successful_run (line 65) | def test_span_ending_with_successful_run(caplog): function test_no_span_operations_when_observability_disabled (line 108) | def test_no_span_operations_when_observability_disabled(caplog): FILE: tests/sdk/conversation/local/test_state_serialization.py class _DifferentAgentForVerifyTest (line 30) | class _DifferentAgentForVerifyTest(AgentBase): method __init__ (line 39) | def __init__(self): method init_state (line 47) | def init_state(self, state, on_event): method step (line 50) | def step( function test_conversation_state_basic_serialization (line 59) | def test_conversation_state_basic_serialization(): function test_conversation_state_persistence_save_load (line 108) | def test_conversation_state_persistence_save_load(): function test_conversation_state_incremental_save (line 175) | def test_conversation_state_incremental_save(): function test_conversation_state_event_file_scanning (line 232) | def test_conversation_state_event_file_scanning(): function test_conversation_state_corrupted_event_handling (line 295) | def test_conversation_state_corrupted_event_handling(): function test_conversation_state_empty_filestore (line 353) | def test_conversation_state_empty_filestore(): function test_conversation_state_missing_base_state (line 379) | def test_conversation_state_missing_base_state(): function test_conversation_state_exclude_from_base_state (line 413) | def test_conversation_state_exclude_from_base_state(): function test_conversation_state_thread_safety (line 444) | def test_conversation_state_thread_safety(): function test_agent_pydantic_validation_on_creation (line 470) | def test_agent_pydantic_validation_on_creation(): function test_agent_verify_validates_tools_match (line 482) | def test_agent_verify_validates_tools_match(): function test_agent_verify_allows_different_llm (line 511) | def test_agent_verify_allows_different_llm(): function test_agent_verify_different_class_raises_error (line 534) | def test_agent_verify_different_class_raises_error(): function test_conversation_state_flags_persistence (line 544) | def test_conversation_state_flags_persistence(): function test_conversation_with_agent_different_llm_config (line 588) | def test_conversation_with_agent_different_llm_config(): function test_resume_uses_runtime_workspace_and_max_iterations (line 646) | def test_resume_uses_runtime_workspace_and_max_iterations(): function test_resume_preserves_persisted_execution_status_and_stuck_detection (line 679) | def test_resume_preserves_persisted_execution_status_and_stuck_detection(): function test_resume_preserves_blocked_actions_and_messages (line 710) | def test_resume_preserves_blocked_actions_and_messages(): function test_conversation_state_stats_preserved_on_resume (line 740) | def test_conversation_state_stats_preserved_on_resume(): function test_resume_with_conversation_id_mismatch_raises_error (line 817) | def test_resume_with_conversation_id_mismatch_raises_error(): function test_conversation_state_secrets_serialization_deserialization (line 844) | def test_conversation_state_secrets_serialization_deserialization(): function test_conversation_state_secrets_with_cipher (line 925) | def test_conversation_state_secrets_with_cipher(): function test_conversation_state_save_with_cipher_load_without (line 1015) | def test_conversation_state_save_with_cipher_load_without(): function test_conversation_state_save_without_cipher_load_with (line 1073) | def test_conversation_state_save_without_cipher_load_with(): function test_conversation_state_cipher_mismatch (line 1125) | def test_conversation_state_cipher_mismatch(): function test_agent_verify_fails_when_explicit_tools_differ (line 1183) | def test_agent_verify_fails_when_explicit_tools_differ(): function test_agent_verify_fails_when_builtin_tools_differ (line 1218) | def test_agent_verify_fails_when_builtin_tools_differ(): function test_agent_verify_fails_when_builtin_tool_removed (line 1252) | def test_agent_verify_fails_when_builtin_tool_removed(): function test_v1_11_5_cli_default_conversation_resumes_when_runtime_adds_delegate (line 1280) | def test_v1_11_5_cli_default_conversation_resumes_when_runtime_adds_dele... function test_context_manager_batches_saves (line 1332) | def test_context_manager_batches_saves() -> None: function test_v1_17_0_conversation_with_mcp_config_restores (line 1372) | def test_v1_17_0_conversation_with_mcp_config_restores(tmp_path: Path) -... FILE: tests/sdk/conversation/remote/test_api_key_functionality.py function create_test_agent (line 20) | def create_test_agent() -> Agent: function test_conversation_factory_passes_api_key_to_remote (line 26) | def test_conversation_factory_passes_api_key_to_remote(): function test_remote_conversation_no_api_key_no_headers (line 55) | def test_remote_conversation_no_api_key_no_headers(): function test_websocket_client_includes_api_key_in_url (line 90) | def test_websocket_client_includes_api_key_in_url(): function test_websocket_client_no_api_key (line 110) | def test_websocket_client_no_api_key(): function test_remote_conversation_passes_api_key_to_websocket_client (line 129) | def test_remote_conversation_passes_api_key_to_websocket_client(): FILE: tests/sdk/conversation/remote/test_remote_conversation.py class TestRemoteConversation (line 22) | class TestRemoteConversation: method setup_method (line 25) | def setup_method(self): method setup_mock_client (line 35) | def setup_mock_client(self, conversation_id: str | None = None): method create_mock_conversation_response (line 94) | def create_mock_conversation_response(self, conversation_id: str | Non... method create_mock_events_response (line 108) | def create_mock_events_response(self, events: list | None = None): method test_remote_conversation_initialization_new_conversation (line 125) | def test_remote_conversation_initialization_new_conversation(self, moc... method test_acp_remote_conversation_uses_unified_endpoint (line 178) | def test_acp_remote_conversation_uses_unified_endpoint(self, mock_ws_c... method test_remote_conversation_initialization_existing_conversation (line 234) | def test_remote_conversation_initialization_existing_conversation( method test_remote_conversation_initialization_nonexistent_conversation_creates_new (line 293) | def test_remote_conversation_initialization_nonexistent_conversation_c... method test_remote_conversation_existing_different_agent_kind_raises_clear_error (line 378) | def test_remote_conversation_existing_different_agent_kind_raises_clea... method test_remote_conversation_send_message_string (line 425) | def test_remote_conversation_send_message_string(self, mock_ws_client): method test_remote_conversation_send_message_object (line 453) | def test_remote_conversation_send_message_object(self, mock_ws_client): method test_remote_conversation_send_message_invalid_role (line 486) | def test_remote_conversation_send_message_invalid_role(self, mock_ws_c... method test_remote_conversation_generate_title_reconciles_locally (line 519) | def test_remote_conversation_generate_title_reconciles_locally( method test_remote_conversation_run (line 603) | def test_remote_conversation_run(self, mock_ws_client): method test_remote_conversation_run_already_running (line 628) | def test_remote_conversation_run_already_running(self, mock_ws_client): method test_remote_conversation_run_non_blocking (line 667) | def test_remote_conversation_run_non_blocking(self, mock_ws_client): method test_remote_conversation_run_blocking_polls_until_finished (line 704) | def test_remote_conversation_run_blocking_polls_until_finished( method test_remote_conversation_run_rest_fallback_refreshes_final_state (line 760) | def test_remote_conversation_run_rest_fallback_refreshes_final_state( method test_remote_conversation_run_error_status_raises (line 842) | def test_remote_conversation_run_error_status_raises(self, mock_ws_cli... method test_remote_conversation_run_stuck_status_raises (line 873) | def test_remote_conversation_run_stuck_status_raises(self, mock_ws_cli... method test_remote_conversation_run_404_raises (line 904) | def test_remote_conversation_run_404_raises(self, mock_ws_client): method test_remote_conversation_run_timeout (line 930) | def test_remote_conversation_run_timeout(self, mock_ws_client): method test_remote_conversation_set_confirmation_policy (line 969) | def test_remote_conversation_set_confirmation_policy(self, mock_ws_cli... method test_remote_conversation_reject_pending_actions (line 998) | def test_remote_conversation_reject_pending_actions(self, mock_ws_clie... method test_remote_conversation_pause (line 1026) | def test_remote_conversation_pause(self, mock_ws_client): method test_remote_conversation_update_secrets (line 1051) | def test_remote_conversation_update_secrets(self, mock_ws_client): method test_remote_conversation_update_secrets_callable (line 1091) | def test_remote_conversation_update_secrets_callable(self, mock_ws_cli... method test_remote_conversation_close (line 1126) | def test_remote_conversation_close(self, mock_ws_client): method test_remote_conversation_stuck_detector_not_implemented (line 1155) | def test_remote_conversation_stuck_detector_not_implemented(self, mock... method test_remote_conversation_with_callbacks (line 1182) | def test_remote_conversation_with_callbacks(self, mock_ws_client): method test_remote_conversation_with_visualize (line 1219) | def test_remote_conversation_with_visualize(self, mock_ws_client): method test_remote_conversation_host_url_normalization (line 1253) | def test_remote_conversation_host_url_normalization(self, mock_ws_clie... method test_remote_conversation_execute_tool_not_implemented (line 1282) | def test_remote_conversation_execute_tool_not_implemented(self, mock_w... method test_remote_conversation_calls_register_conversation (line 1314) | def test_remote_conversation_calls_register_conversation(self, mock_ws... FILE: tests/sdk/conversation/remote/test_remote_events_list.py function mock_client (line 16) | def mock_client(): function conversation_id (line 22) | def conversation_id(): function create_mock_event (line 27) | def create_mock_event(event_id: str) -> Event: function create_mock_api_response (line 39) | def create_mock_api_response(events: list[Event], next_page_id: str | No... function test_remote_events_list_single_page (line 50) | def test_remote_events_list_single_page(mock_client, conversation_id): function test_remote_events_list_pagination (line 69) | def test_remote_events_list_pagination(mock_client, conversation_id): function test_remote_events_list_indexing_and_slicing (line 87) | def test_remote_events_list_indexing_and_slicing(mock_client, conversati... function test_remote_events_list_add_event_deduplication (line 113) | def test_remote_events_list_add_event_deduplication(mock_client, convers... function test_remote_events_list_callback_integration (line 136) | def test_remote_events_list_callback_integration(mock_client, conversati... function test_remote_events_list_api_error (line 152) | def test_remote_events_list_api_error(mock_client, conversation_id): function test_remote_events_list_empty (line 168) | def test_remote_events_list_empty(mock_client, conversation_id): function test_remote_events_list_maintains_timestamp_order (line 182) | def test_remote_events_list_maintains_timestamp_order(mock_client, conve... function test_remote_events_list_timestamp_order_with_existing_events (line 225) | def test_remote_events_list_timestamp_order_with_existing_events( function test_remote_events_list_identical_timestamps_stable_order (line 266) | def test_remote_events_list_identical_timestamps_stable_order( FILE: tests/sdk/conversation/remote/test_remote_fork.py function _agent (line 15) | def _agent() -> Agent: function _setup_workspace_with_mock_client (line 22) | def _setup_workspace_with_mock_client( function test_remote_fork_sends_post_request (line 68) | def test_remote_fork_sends_post_request(mock_ws_cls: Mock) -> None: function test_remote_fork_uses_server_returned_tags (line 91) | def test_remote_fork_uses_server_returned_tags(mock_ws_cls: Mock) -> None: function test_remote_fork_raises_on_agent_param (line 126) | def test_remote_fork_raises_on_agent_param(mock_ws_cls: Mock) -> None: function test_remote_fork_passes_body_fields (line 138) | def test_remote_fork_passes_body_fields(mock_ws_cls: Mock) -> None: FILE: tests/sdk/conversation/remote/test_remote_request_logging.py class TestIsSecretKey (line 14) | class TestIsSecretKey: method test_detects_secret_keys (line 38) | def test_detects_secret_keys(self, key): method test_ignores_non_secret_keys (line 54) | def test_ignores_non_secret_keys(self, key): class TestSanitizeDict (line 58) | class TestSanitizeDict: method test_redacts_secret_keys (line 61) | def test_redacts_secret_keys(self): method test_redacts_all_values_in_environment_keys (line 66) | def test_redacts_all_values_in_environment_keys(self): method test_preserves_structure_in_lists (line 75) | def test_preserves_structure_in_lists(self): method test_handles_nested_structures (line 80) | def test_handles_nested_structures(self): class TestHttpErrorLogContent (line 96) | class TestHttpErrorLogContent: method test_sanitizes_json_response (line 99) | def test_sanitizes_json_response(self): method test_handles_non_json_response (line 107) | def test_handles_non_json_response(self): function test_send_request_redacts_structured_error_content (line 115) | def test_send_request_redacts_structured_error_content(caplog): function test_send_request_omits_non_json_error_body (line 154) | def test_send_request_omits_non_json_error_body(caplog): FILE: tests/sdk/conversation/remote/test_remote_state.py function mock_client (line 19) | def mock_client(): function conversation_id (line 25) | def conversation_id(): function mock_agent (line 31) | def mock_agent(): function create_mock_conversation_info (line 37) | def create_mock_conversation_info(conversation_id: str, mock_agent: Agen... function create_mock_api_response (line 50) | def create_mock_api_response(data): function setup_mock_responses (line 58) | def setup_mock_responses(mock_client, conversation_info): function test_remote_state_initialization (line 69) | def test_remote_state_initialization(mock_client, conversation_id): function test_remote_state_execution_status (line 95) | def test_remote_state_execution_status( function test_remote_state_execution_status_setter_not_implemented (line 109) | def test_remote_state_execution_status_setter_not_implemented( function test_remote_state_confirmation_policy (line 127) | def test_remote_state_confirmation_policy(mock_client, conversation_id, ... function test_remote_state_hook_config (line 140) | def test_remote_state_hook_config(mock_client, conversation_id, mock_age... function test_remote_state_activated_knowledge_skills (line 157) | def test_remote_state_activated_knowledge_skills( function test_remote_state_agent_property (line 172) | def test_remote_state_agent_property(mock_client, conversation_id, mock_... function test_remote_state_missing_fields (line 199) | def test_remote_state_missing_fields( function test_remote_state_model_dump (line 213) | def test_remote_state_model_dump(mock_client, conversation_id, mock_agent): function test_remote_state_model_dump_json (line 224) | def test_remote_state_model_dump_json(mock_client, conversation_id, mock... function test_remote_state_context_manager (line 236) | def test_remote_state_context_manager(mock_client, conversation_id): function test_remote_state_api_error_handling (line 249) | def test_remote_state_api_error_handling(mock_client, conversation_id): function test_remote_state_refresh_from_server_uses_configured_base_path (line 272) | def test_remote_state_refresh_from_server_uses_configured_base_path( FILE: tests/sdk/conversation/remote/test_run_exception_includes_conversation_id_remote.py function create_test_agent (line 15) | def create_test_agent() -> Agent: function test_remote_run_raises_conversation_run_error_with_id (line 20) | def test_remote_run_raises_conversation_run_error_with_id(): FILE: tests/sdk/conversation/remote/test_websocket_client.py function mock_event (line 15) | def mock_event(): function test_websocket_client_lifecycle (line 27) | def test_websocket_client_lifecycle(): function test_websocket_client_error_resilience (line 59) | def test_websocket_client_error_resilience(mock_event): function test_websocket_client_stop_timeout (line 84) | def test_websocket_client_stop_timeout(): function test_websocket_client_callback_invocation (line 110) | def test_websocket_client_callback_invocation(mock_event): FILE: tests/sdk/conversation/remote/test_websocket_subscription_ready.py class TestWebSocketReadySignaling (line 21) | class TestWebSocketReadySignaling: method test_wait_until_ready_returns_false_on_timeout (line 22) | def test_wait_until_ready_returns_false_on_timeout(self): method test_wait_until_ready_unblocks_when_ready_signaled (line 31) | def test_wait_until_ready_unblocks_when_ready_signaled(self): method test_wait_until_ready_unblocks_when_stopped (line 58) | def test_wait_until_ready_unblocks_when_stopped(self): method test_wait_until_ready_is_idempotent_after_ready (line 84) | def test_wait_until_ready_is_idempotent_after_ready(self): class TestRemoteEventsListReconciliation (line 97) | class TestRemoteEventsListReconciliation: method test_reconcile_merges_events_without_duplicates (line 98) | def test_reconcile_merges_events_without_duplicates(self): method test_reconcile_handles_empty_server_response (line 139) | def test_reconcile_handles_empty_server_response(self): method test_reconcile_is_idempotent (line 158) | def test_reconcile_is_idempotent(self): FILE: tests/sdk/conversation/test_agent_final_response.py function test_get_agent_final_response_with_finish_action (line 9) | def test_get_agent_final_response_with_finish_action(): function test_get_agent_final_response_with_message_event (line 32) | def test_get_agent_final_response_with_message_event(): function test_get_agent_final_response_with_multiple_events (line 48) | def test_get_agent_final_response_with_multiple_events(): function test_get_agent_final_response_finish_action_takes_precedence (line 77) | def test_get_agent_final_response_finish_action_takes_precedence(): function test_get_agent_final_response_empty_events (line 109) | def test_get_agent_final_response_empty_events(): function test_get_agent_final_response_no_agent_events (line 117) | def test_get_agent_final_response_no_agent_events(): function test_get_agent_final_response_with_none_action (line 131) | def test_get_agent_final_response_with_none_action(): function test_get_agent_final_response_with_multiple_content_parts (line 154) | def test_get_agent_final_response_with_multiple_content_parts(): function test_get_agent_final_response_ignores_non_agent_finish (line 175) | def test_get_agent_final_response_ignores_non_agent_finish(): function test_get_agent_final_response_with_non_finish_action (line 207) | def test_get_agent_final_response_with_non_finish_action(): FILE: tests/sdk/conversation/test_agent_state_reassignment.py class AgentStateWriteVisitor (line 17) | class AgentStateWriteVisitor(ast.NodeVisitor): method __init__ (line 20) | def __init__(self, filepath: str): method visit_Subscript (line 24) | def visit_Subscript(self, node: ast.Subscript) -> None: method visit_Assign (line 31) | def visit_Assign(self, node: ast.Assign) -> None: method visit_AugAssign (line 46) | def visit_AugAssign(self, node: ast.AugAssign) -> None: method visit_Call (line 59) | def visit_Call(self, node: ast.Call) -> None: method visit_Delete (line 83) | def visit_Delete(self, node: ast.Delete) -> None: method _is_agent_state_subscript (line 97) | def _is_agent_state_subscript(self, node: ast.Subscript) -> bool: method _is_agent_state_attr (line 101) | def _is_agent_state_attr(self, node: ast.AST) -> bool: function get_sdk_python_files (line 112) | def get_sdk_python_files() -> list[Path]: function test_agent_state_writes_use_reassignment_pattern (line 128) | def test_agent_state_writes_use_reassignment_pattern(): function test_agent_state_reassignment_triggers_autosave (line 166) | def test_agent_state_reassignment_triggers_autosave(): function test_agent_state_inplace_mutation_does_not_trigger_autosave (line 218) | def test_agent_state_inplace_mutation_does_not_trigger_autosave(): FILE: tests/sdk/conversation/test_ask_agent.py class MockAction (line 39) | class MockAction(Action): class MockObservation (line 43) | class MockObservation(Observation): method to_llm_content (line 47) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: function create_test_agent (line 51) | def create_test_agent() -> Agent: function create_mock_llm_response (line 56) | def create_mock_llm_response(content: str) -> LLMResponse: function find_msg (line 82) | def find_msg(messages: list[Message], role: str, text_substring: str | N... function agent (line 100) | def agent() -> Agent: function test_local_conversation_ask_agent (line 110) | def test_local_conversation_ask_agent(mock_completion, tmp_path, agent): function test_local_conversation_ask_agent_copies_llm_config (line 157) | def test_local_conversation_ask_agent_copies_llm_config(mock_completion,... function test_remote_conversation_ask_agent (line 191) | def test_remote_conversation_ask_agent(mock_ws_client, agent): function test_ask_agent_with_existing_events_and_tool_calls (line 244) | def test_ask_agent_with_existing_events_and_tool_calls( function test_local_conversation_ask_agent_raises_context_window_error (line 354) | def test_local_conversation_ask_agent_raises_context_window_error( function test_local_conversation_ask_agent_raises_failed_to_generate_summary (line 380) | def test_local_conversation_ask_agent_raises_failed_to_generate_summary( function test_local_conversation_ask_agent_raises_failed_to_generate_summary_non_text (line 404) | def test_local_conversation_ask_agent_raises_failed_to_generate_summary_... function test_remote_conversation_ask_agent_raises_http_status_error (line 430) | def test_remote_conversation_ask_agent_raises_http_status_error(mock_ws_... function test_remote_conversation_ask_agent_raises_request_error (line 483) | def test_remote_conversation_ask_agent_raises_request_error(mock_ws_clie... function test_ask_agent_template_dir_path_construction (line 530) | def test_ask_agent_template_dir_path_construction(mock_completion, tmp_p... FILE: tests/sdk/conversation/test_atexit_cleanup.py function _make_conversation (line 15) | def _make_conversation(workspace: str) -> LocalConversation: function test_close_unregisters_atexit_handler (line 20) | def test_close_unregisters_atexit_handler(): function test_close_is_idempotent_with_atexit (line 37) | def test_close_is_idempotent_with_atexit(): FILE: tests/sdk/conversation/test_base_span_management.py class MockConversation (line 14) | class MockConversation(BaseConversation): method __init__ (line 17) | def __init__(self): method close (line 21) | def close(self) -> None: method conversation_stats (line 25) | def conversation_stats(self) -> ConversationStats: method generate_title (line 28) | def generate_title(self, llm: LLM | None = None, max_length: int = 50)... method id (line 32) | def id(self) -> UUID: method pause (line 35) | def pause(self) -> None: method reject_pending_actions (line 38) | def reject_pending_actions(self, reason: str = "User rejected the acti... method run (line 41) | def run(self) -> None: method send_message (line 44) | def send_message(self, message: Any, sender: str | None = None) -> None: method set_confirmation_policy (line 47) | def set_confirmation_policy(self, policy: Any) -> None: method set_security_analyzer (line 50) | def set_security_analyzer(self, analyzer: Any) -> None: method state (line 54) | def state(self) -> Any: method update_secrets (line 57) | def update_secrets(self, secrets: Any) -> None: method ask_agent (line 60) | def ask_agent(self, question: str) -> str: method condense (line 63) | def condense(self) -> None: method execute_tool (line 67) | def execute_tool(self, tool_name: str, action: Action) -> Observation: method fork (line 71) | def fork(self, **kwargs: Any) -> "MockConversation": function test_base_conversation_span_management (line 76) | def test_base_conversation_span_management(): function test_base_conversation_span_management_disabled (line 119) | def test_base_conversation_span_management_disabled(): function test_base_conversation_no_span_warnings (line 148) | def test_base_conversation_no_span_warnings(caplog): FILE: tests/sdk/conversation/test_condense.py class CondenseTestMockAction (line 39) | class CondenseTestMockAction(Action): class CondenseTestMockObservation (line 43) | class CondenseTestMockObservation(Observation): method to_llm_content (line 47) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: function create_test_agent (line 51) | def create_test_agent() -> Agent: function create_test_agent_with_condenser (line 56) | def create_test_agent_with_condenser() -> Agent: function create_mock_llm_response (line 67) | def create_mock_llm_response(content: str) -> LLMResponse: function agent (line 99) | def agent() -> Agent: function agent_with_condenser (line 104) | def agent_with_condenser() -> Agent: function test_local_conversation_condense_without_condenser (line 113) | def test_local_conversation_condense_without_condenser(tmp_path, agent): function test_local_conversation_condense_with_condenser (line 142) | def test_local_conversation_condense_with_condenser( function test_local_conversation_condense_copies_llm_config (line 186) | def test_local_conversation_condense_copies_llm_config(tmp_path): function test_local_conversation_condense_with_existing_events_and_tool_calls (line 222) | def test_local_conversation_condense_with_existing_events_and_tool_calls( function test_local_conversation_condense_force_condenser_bypasses_window (line 286) | def test_local_conversation_condense_force_condenser_bypasses_window(tmp... function test_remote_conversation_condense (line 318) | def test_remote_conversation_condense(mock_ws_client, agent): function test_remote_conversation_condense_with_agent_with_condenser (line 373) | def test_remote_conversation_condense_with_agent_with_condenser( function test_local_conversation_condense_raises_context_window_error (line 427) | def test_local_conversation_condense_raises_context_window_error(tmp_pat... function test_local_conversation_condense_handles_empty_response (line 453) | def test_local_conversation_condense_handles_empty_response(tmp_path, ag... function test_remote_conversation_condense_raises_http_status_error (line 480) | def test_remote_conversation_condense_raises_http_status_error(mock_ws_c... function test_remote_conversation_condense_raises_request_error (line 533) | def test_remote_conversation_condense_raises_request_error(mock_ws_clien... function test_local_conversation_condense_llm_registry_isolation (line 579) | def test_local_conversation_condense_llm_registry_isolation(tmp_path, ag... FILE: tests/sdk/conversation/test_conversation_execution_status_enum.py function test_agent_execution_state_enum_basic (line 10) | def test_agent_execution_state_enum_basic(): function test_enum_values (line 45) | def test_enum_values(): function test_enum_serialization (line 58) | def test_enum_serialization(): FILE: tests/sdk/conversation/test_conversation_factory.py function agent (line 17) | def agent(): function remote_workspace (line 24) | def remote_workspace(): function test_conversation_factory_creates_local_by_default (line 59) | def test_conversation_factory_creates_local_by_default(agent): function test_conversation_factory_creates_remote_with_workspace (line 67) | def test_conversation_factory_creates_remote_with_workspace( function test_conversation_factory_forwards_local_parameters (line 76) | def test_conversation_factory_forwards_local_parameters(agent): function test_conversation_factory_forwards_remote_parameters (line 90) | def test_conversation_factory_forwards_remote_parameters( function test_conversation_factory_string_workspace_creates_local (line 105) | def test_conversation_factory_string_workspace_creates_local(agent): function test_conversation_factory_type_inference (line 113) | def test_conversation_factory_type_inference(mock_ws_client, agent, remo... FILE: tests/sdk/conversation/test_conversation_secrets_constructor.py function create_test_agent (line 20) | def create_test_agent() -> Agent: function test_local_conversation_constructor_with_secrets (line 26) | def test_local_conversation_constructor_with_secrets(): function test_local_conversation_constructor_with_callable_secrets (line 66) | def test_local_conversation_constructor_with_callable_secrets(): function test_local_conversation_constructor_without_secrets (line 105) | def test_local_conversation_constructor_without_secrets(): function test_local_conversation_constructor_with_empty_secrets (line 129) | def test_local_conversation_constructor_with_empty_secrets(): function test_remote_conversation_constructor_with_secrets (line 154) | def test_remote_conversation_constructor_with_secrets(api_key): function test_remote_conversation_constructor_with_callable_secrets (line 197) | def test_remote_conversation_constructor_with_callable_secrets(): function test_remote_conversation_constructor_without_secrets (line 244) | def test_remote_conversation_constructor_without_secrets(): function test_conversation_factory_routing_with_secrets (line 286) | def test_conversation_factory_routing_with_secrets(): function test_secrets_parameter_type_validation (line 322) | def test_secrets_parameter_type_validation(): FILE: tests/sdk/conversation/test_conversation_stats.py function mock_file_store (line 20) | def mock_file_store(): function conversation_stats (line 26) | def conversation_stats(mock_file_store): function mock_llm_registry (line 32) | def mock_llm_registry(): function connected_registry_and_stats (line 39) | def connected_registry_and_stats(mock_llm_registry, conversation_stats): function test_get_combined_metrics (line 46) | def test_get_combined_metrics(conversation_stats): function test_get_metrics_for_usage (line 88) | def test_get_metrics_for_usage(conversation_stats): function test_register_llm_with_new_usage (line 109) | def test_register_llm_with_new_usage(conversation_stats): function test_register_llm_with_restored_metrics (line 134) | def test_register_llm_with_restored_metrics(conversation_stats): function test_llm_registry_notifications (line 168) | def test_llm_registry_notifications(connected_registry_and_stats): function test_multiple_llm_usages (line 226) | def test_multiple_llm_usages(connected_registry_and_stats): function test_register_llm_with_multiple_restored_usage_ids (line 299) | def test_register_llm_with_multiple_restored_usage_ids(conversation_stats): FILE: tests/sdk/conversation/test_directories.py function mock_agent (line 20) | def mock_agent(): function test_conversation_state_working_dir (line 27) | def test_conversation_state_working_dir(mock_agent): function test_conversation_state_persistence_dir (line 43) | def test_conversation_state_persistence_dir(mock_agent): function test_conversation_state_both_directories (line 63) | def test_conversation_state_both_directories(mock_agent): function test_conversation_factory_with_directories (line 85) | def test_conversation_factory_with_directories(mock_agent): function test_conversation_factory_default_directories (line 104) | def test_conversation_factory_default_directories(mock_agent): function test_conversation_factory_working_dir_only (line 120) | def test_conversation_factory_working_dir_only(mock_agent): function test_conversation_factory_persistence_dir_only (line 132) | def test_conversation_factory_persistence_dir_only(mock_agent): function test_no_persistence_dir_logs_warning (line 146) | def test_no_persistence_dir_logs_warning(mock_agent, caplog): FILE: tests/sdk/conversation/test_event_store.py function create_test_event (line 14) | def create_test_event(event_id: str, content: str = "Test content") -> M... function test_event_log_empty_initialization (line 24) | def test_event_log_empty_initialization(): function test_event_log_id_validation_duplicate_id (line 40) | def test_event_log_id_validation_duplicate_id(): function test_event_log_id_validation_existing_id_different_index (line 59) | def test_event_log_id_validation_existing_id_different_index(): function test_event_log_negative_indexing (line 83) | def test_event_log_negative_indexing(): function test_event_log_get_index_and_get_id (line 107) | def test_event_log_get_index_and_get_id(): function test_event_log_missing_event_file (line 147) | def test_event_log_missing_event_file(): function test_event_log_corrupted_json_in_file (line 164) | def test_event_log_corrupted_json_in_file(): function test_event_log_clear_functionality (line 183) | def test_event_log_clear_functionality(): function test_event_log_index_gaps_detection (line 208) | def test_event_log_index_gaps_detection(): function test_event_log_file_store_exceptions (line 244) | def test_event_log_file_store_exceptions(): function test_event_log_iteration_with_missing_files (line 256) | def test_event_log_iteration_with_missing_files(): function test_event_log_iteration_backfills_missing_mappings (line 281) | def test_event_log_iteration_backfills_missing_mappings(): function test_event_log_custom_directory (line 310) | def test_event_log_custom_directory(): function test_event_log_large_index_formatting (line 329) | def test_event_log_large_index_formatting(): function test_event_log_concurrent_append_thread_safety (line 349) | def test_event_log_concurrent_append_thread_safety(): function test_event_log_concurrent_writes_serialized (line 386) | def test_event_log_concurrent_writes_serialized(): function test_get_single_item_recovers_from_stale_index (line 407) | def test_get_single_item_recovers_from_stale_index(): function test_get_single_item_stale_index_out_of_range (line 427) | def test_get_single_item_stale_index_out_of_range(): FILE: tests/sdk/conversation/test_fifo_lock.py function test_fifo_lock_basic_functionality (line 14) | def test_fifo_lock_basic_functionality(): function test_fifo_lock_context_manager (line 41) | def test_fifo_lock_context_manager(): function test_fifo_lock_non_blocking (line 58) | def test_fifo_lock_non_blocking(): function test_fifo_lock_timeout (line 81) | def test_fifo_lock_timeout(): function test_fifo_lock_fairness (line 104) | def test_fifo_lock_fairness(): function test_fifo_lock_error_handling (line 147) | def test_fifo_lock_error_handling(): function test_fifo_lock_stress_test (line 175) | def test_fifo_lock_stress_test(): function run_fairness_test_multiple (line 210) | def run_fairness_test_multiple(num_runs: int = 100) -> list[bool]: FILE: tests/sdk/conversation/test_generate_title.py function create_test_agent (line 17) | def create_test_agent() -> Agent: function create_user_message_event (line 23) | def create_user_message_event(content: str) -> MessageEvent: function create_mock_llm_response (line 31) | def create_mock_llm_response(content: str) -> LLMResponse: function test_generate_title_without_llm_uses_agent_llm (line 70) | def test_generate_title_without_llm_uses_agent_llm(mock_completion): function test_generate_title_no_user_messages (line 90) | def test_generate_title_no_user_messages(): function test_generate_title_llm_error_fallback (line 105) | def test_generate_title_llm_error_fallback(mock_completion): function test_generate_title_truncation_respects_max_length (line 128) | def test_generate_title_truncation_respects_max_length(mock_completion): function test_generate_title_with_llm_truncates_long_response (line 148) | def test_generate_title_with_llm_truncates_long_response(mock_completion): function test_generate_title_with_custom_llm (line 175) | def test_generate_title_with_custom_llm(mock_completion): function test_generate_title_empty_llm_response_fallback (line 201) | def test_generate_title_empty_llm_response_fallback(mock_completion): FILE: tests/sdk/conversation/test_get_unmatched_actions.py class MockTestAction (line 27) | class MockTestAction(Action): class MockTestObservation (line 33) | class MockTestObservation(Observation): method visualize (line 39) | def visualize(self): function _create_action_event (line 45) | def _create_action_event( function test_action_without_observation_is_unmatched (line 74) | def test_action_without_observation_is_unmatched(): function test_action_with_observation_event_is_matched (line 85) | def test_action_with_observation_event_is_matched(): function test_action_with_user_reject_observation_is_matched (line 102) | def test_action_with_user_reject_observation_is_matched(): function test_action_with_agent_error_event_is_matched (line 118) | def test_action_with_agent_error_event_is_matched(): function test_multiple_actions_with_mixed_responses (line 146) | def test_multiple_actions_with_mixed_responses(): function test_agent_error_event_matching_by_tool_call_id (line 187) | def test_agent_error_event_matching_by_tool_call_id(): function test_agent_error_event_different_tool_call_id_does_not_match (line 208) | def test_agent_error_event_different_tool_call_id_does_not_match(): function test_crash_recovery_scenario_prevents_duplicate_execution (line 227) | def test_crash_recovery_scenario_prevents_duplicate_execution(): function test_non_executable_action_is_not_considered_unmatched (line 263) | def test_non_executable_action_is_not_considered_unmatched(): FILE: tests/sdk/conversation/test_local_conversation_plugins.py function mock_llm (line 17) | def mock_llm(): function basic_agent (line 26) | def basic_agent(mock_llm): function create_test_plugin (line 34) | def create_test_plugin( class TestLocalConversationPlugins (line 70) | class TestLocalConversationPlugins: method test_create_conversation_with_plugins (line 77) | def test_create_conversation_with_plugins(self, tmp_path: Path, basic_... method test_conversation_with_multiple_plugins (line 109) | def test_conversation_with_multiple_plugins(self, tmp_path: Path, basi... method test_plugin_hooks_combined_with_explicit_hooks (line 148) | def test_plugin_hooks_combined_with_explicit_hooks( method test_plugins_not_loaded_until_needed (line 191) | def test_plugins_not_loaded_until_needed(self, tmp_path: Path, basic_a... method test_plugin_mcp_config_is_initialized (line 222) | def test_plugin_mcp_config_is_initialized( class TestConversationFactoryPlugins (line 280) | class TestConversationFactoryPlugins: method test_factory_passes_plugins_to_local_conversation (line 286) | def test_factory_passes_plugins_to_local_conversation( method test_factory_with_string_workspace_and_plugins (line 315) | def test_factory_with_string_workspace_and_plugins( method test_factory_with_no_plugins (line 341) | def test_factory_with_no_plugins(self, tmp_path: Path, basic_agent): class TestPluginMcpSecretsExpansion (line 357) | class TestPluginMcpSecretsExpansion: method test_plugin_mcp_secrets_without_defaults (line 366) | def test_plugin_mcp_secrets_without_defaults( method test_plugin_mcp_secrets_with_defaults (line 427) | def test_plugin_mcp_secrets_with_defaults( method test_plugin_mcp_secrets_fallback_to_default_when_no_secret (line 500) | def test_plugin_mcp_secrets_fallback_to_default_when_no_secret( FILE: tests/sdk/conversation/test_mcp_secrets_serialization_leak.py function agent_with_secret_in_mcp_config (line 27) | def agent_with_secret_in_mcp_config(): class TestMcpSecretsDoNotLeakToPersistence (line 50) | class TestMcpSecretsDoNotLeakToPersistence: method test_secrets_not_in_base_state_json (line 53) | def test_secrets_not_in_base_state_json( method test_mcp_config_excluded_or_redacted_in_persistence (line 85) | def test_mcp_config_excluded_or_redacted_in_persistence( class TestMcpSecretsDoNotLeakToWebSocket (line 120) | class TestMcpSecretsDoNotLeakToWebSocket: method test_secrets_not_in_state_update_event (line 123) | def test_secrets_not_in_state_update_event( method test_agent_field_update_does_not_leak_secrets (line 151) | def test_agent_field_update_does_not_leak_secrets( class TestMcpSecretsDoNotLeakToAPI (line 192) | class TestMcpSecretsDoNotLeakToAPI: method test_secrets_not_in_state_model_dump (line 195) | def test_secrets_not_in_state_model_dump( method test_agent_model_dump_excludes_mcp_secrets (line 221) | def test_agent_model_dump_excludes_mcp_secrets( class TestMcpConfigPreservation (line 238) | class TestMcpConfigPreservation: method test_mcp_config_still_accessible_in_memory (line 241) | def test_mcp_config_still_accessible_in_memory( method test_non_secret_mcp_config_values_persist_with_cipher (line 257) | def test_non_secret_mcp_config_values_persist_with_cipher(self, tmp_pa... FILE: tests/sdk/conversation/test_remote_conversation_state_updates.py function create_test_agent (line 16) | def create_test_agent() -> Agent: function test_update_state_from_event_with_full_state (line 22) | def test_update_state_from_event_with_full_state(): function test_update_state_from_event_with_individual_field (line 60) | def test_update_state_from_event_with_individual_field(): function test_update_state_initializes_cache_if_none (line 98) | def test_update_state_initializes_cache_if_none(): function test_update_state_from_multiple_events (line 130) | def test_update_state_from_multiple_events(): function test_update_state_full_state_overwrites_fields (line 173) | def test_update_state_full_state_overwrites_fields(): function test_update_state_thread_safe (line 215) | def test_update_state_thread_safe(): function test_update_state_preserves_data_types (line 260) | def test_update_state_preserves_data_types(): function test_state_update_callback_integration (line 300) | def test_state_update_callback_integration(): function test_conversation_stats_reads_from_stats_field (line 334) | def test_conversation_stats_reads_from_stats_field(): function test_stats_update_via_state_event (line 384) | def test_stats_update_via_state_event(): FILE: tests/sdk/conversation/test_repo_root_project_skills.py function test_system_prompt_includes_repo_root_agents_md_when_workdir_is_subdir (line 14) | def test_system_prompt_includes_repo_root_agents_md_when_workdir_is_subdir( FILE: tests/sdk/conversation/test_resource_lock_manager.py function test_basic_lock_and_release (line 13) | def test_basic_lock_and_release(): function test_no_keys_is_noop (line 19) | def test_no_keys_is_noop(): function test_serializes_same_resource (line 25) | def test_serializes_same_resource(): function test_parallel_different_resources (line 63) | def test_parallel_different_resources(): function test_sorted_order_prevents_deadlock (line 84) | def test_sorted_order_prevents_deadlock(): function test_timeout_raises_custom_exception (line 103) | def test_timeout_raises_custom_exception(): function test_timeout_is_subclass_of_timeout_error (line 126) | def test_timeout_is_subclass_of_timeout_error(): function test_duplicate_keys_deduplicated (line 131) | def test_duplicate_keys_deduplicated(): function test_default_timeouts (line 138) | def test_default_timeouts(): function test_release_on_exception (line 148) | def test_release_on_exception(): function test_partial_release_on_timeout (line 160) | def test_partial_release_on_timeout(): function test_cleanup_removes_unused_locks (line 196) | def test_cleanup_removes_unused_locks(): function test_cleanup_preserves_contended_locks (line 206) | def test_cleanup_preserves_contended_locks(): FILE: tests/sdk/conversation/test_secret_source.py function lookup_secret (line 13) | def lookup_secret(): function test_lookup_secret_serialization_default (line 26) | def test_lookup_secret_serialization_default(lookup_secret): function test_lookup_secret_serialization_expose_secrets (line 44) | def test_lookup_secret_serialization_expose_secrets(lookup_secret): function test_lookup_secret_serialization_encrypt (line 64) | def test_lookup_secret_serialization_encrypt(lookup_secret): function test_lookup_secret_deserialization_redacted_headers (line 72) | def test_lookup_secret_deserialization_redacted_headers(): function test_static_secret_optional_value (line 106) | def test_static_secret_optional_value(): function test_static_secret_deserialization_redacted (line 129) | def test_static_secret_deserialization_redacted(): function test_lookup_secret_redacts_token_and_cookie_headers (line 145) | def test_lookup_secret_redacts_token_and_cookie_headers(): function test_lookup_secret_validate_with_cipher_preserves_plaintext_headers (line 174) | def test_lookup_secret_validate_with_cipher_preserves_plaintext_headers(): function test_lookup_secret_validate_with_cipher_decrypts_encrypted_headers (line 208) | def test_lookup_secret_validate_with_cipher_decrypts_encrypted_headers(): function test_lookup_secret_validate_with_cipher_drops_redacted_headers (line 230) | def test_lookup_secret_validate_with_cipher_drops_redacted_headers(): function test_lookup_secret_author_header_not_redacted (line 253) | def test_lookup_secret_author_header_not_redacted(): function test_lookup_secret_relative_url_uses_current_server (line 280) | def test_lookup_secret_relative_url_uses_current_server(monkeypatch): function test_lookup_secret_get_value_resolves_relative_url (line 288) | def test_lookup_secret_get_value_resolves_relative_url(monkeypatch): FILE: tests/sdk/conversation/test_secrets_manager.py function test_update_secrets_with_static_values (line 9) | def test_update_secrets_with_static_values(): function test_update_secrets_overwrites_existing (line 24) | def test_update_secrets_overwrites_existing(): function test_find_secrets_in_text_case_insensitive (line 46) | def test_find_secrets_in_text_case_insensitive(): function test_find_secrets_in_text_partial_matches (line 70) | def test_find_secrets_in_text_partial_matches(): function test_get_secrets_as_env_vars_static_values (line 86) | def test_get_secrets_as_env_vars_static_values(): function test_get_secrets_as_env_vars_callable_values (line 108) | def test_get_secrets_as_env_vars_callable_values(): function test_get_secrets_as_env_vars_handles_callable_exceptions (line 129) | def test_get_secrets_as_env_vars_handles_callable_exceptions(): function test_get_secret_value_static (line 157) | def test_get_secret_value_static(): function test_get_secret_value_callable (line 175) | def test_get_secret_value_callable(): function test_get_secret_value_handles_exceptions (line 194) | def test_get_secret_value_handles_exceptions(): function test_get_secret_value_empty_registry (line 218) | def test_get_secret_value_empty_registry(): function test_get_secret_value_as_callback (line 224) | def test_get_secret_value_as_callback(): function test_get_secret_value_tracks_for_masking (line 242) | def test_get_secret_value_tracks_for_masking(): function test_get_secret_value_missing_not_tracked (line 282) | def test_get_secret_value_missing_not_tracked(): FILE: tests/sdk/conversation/test_state_change_callback.py function state (line 19) | def state(): function test_set_on_state_change_callback (line 39) | def test_set_on_state_change_callback(state): function test_callback_called_multiple_times (line 61) | def test_callback_called_multiple_times(state): function test_callback_can_be_cleared (line 83) | def test_callback_can_be_cleared(state): function test_callback_exception_does_not_break_state_change (line 102) | def test_callback_exception_does_not_break_state_change(state): function test_callback_not_called_without_lock (line 118) | def test_callback_not_called_without_lock(state): function test_callback_with_different_field_types (line 135) | def test_callback_with_different_field_types(state): function test_callback_receives_correct_new_value (line 157) | def test_callback_receives_correct_new_value(state): FILE: tests/sdk/conversation/test_stats_update_event_snapshot.py function state (line 18) | def state(): function test_stats_update_event_uses_snapshot_not_full_metrics (line 38) | def test_stats_update_event_uses_snapshot_not_full_metrics(state): function test_stats_model_dump_preserves_full_history (line 103) | def test_stats_model_dump_preserves_full_history(): function test_stats_model_dump_with_snapshot_context_excludes_history (line 151) | def test_stats_model_dump_with_snapshot_context_excludes_history(): FILE: tests/sdk/conversation/test_switch_model.py function _make_llm (line 14) | def _make_llm(model: str, usage_id: str) -> LLM: function profile_store (line 19) | def profile_store(tmp_path, monkeypatch): function _make_conversation (line 35) | def _make_conversation() -> LocalConversation: function test_switch_profile (line 45) | def test_switch_profile(profile_store): function test_switch_profile_updates_state (line 54) | def test_switch_profile_updates_state(profile_store): function test_switch_between_profiles (line 61) | def test_switch_between_profiles(profile_store): function test_switch_reuses_registry_entry (line 75) | def test_switch_reuses_registry_entry(profile_store): function test_switch_nonexistent_raises (line 89) | def test_switch_nonexistent_raises(profile_store): function test_switch_profile_preserves_prompt_cache_key (line 98) | def test_switch_profile_preserves_prompt_cache_key(profile_store): function test_switch_then_send_message (line 115) | def test_switch_then_send_message(profile_store): function empty_profile_store (line 125) | def empty_profile_store(tmp_path, monkeypatch): function test_switch_llm_swaps_when_store_empty (line 136) | def test_switch_llm_swaps_when_store_empty(empty_profile_store): function test_switch_llm_then_send_message (line 155) | def test_switch_llm_then_send_message(empty_profile_store): function test_switch_between_two_llms (line 166) | def test_switch_between_two_llms(empty_profile_store): function test_switch_llm_does_not_consult_store (line 179) | def test_switch_llm_does_not_consult_store(empty_profile_store, monkeypa... function test_switch_profile_decrypts_with_cipher (line 198) | def test_switch_profile_decrypts_with_cipher(tmp_path, monkeypatch): function test_switch_profile_delegates_to_switch_llm (line 236) | def test_switch_profile_delegates_to_switch_llm(profile_store, monkeypat... FILE: tests/sdk/conversation/test_tags.py function test_validate_tags_valid (line 13) | def test_validate_tags_valid(): function test_validate_tags_none_returns_empty (line 19) | def test_validate_tags_none_returns_empty(): function test_validate_tags_empty_dict (line 23) | def test_validate_tags_empty_dict(): function test_validate_tags_invalid_key_uppercase (line 27) | def test_validate_tags_invalid_key_uppercase(): function test_validate_tags_invalid_key_with_hyphen (line 32) | def test_validate_tags_invalid_key_with_hyphen(): function test_validate_tags_invalid_key_with_underscore (line 37) | def test_validate_tags_invalid_key_with_underscore(): function test_validate_tags_invalid_key_with_spaces (line 42) | def test_validate_tags_invalid_key_with_spaces(): function test_validate_tags_value_max_length (line 47) | def test_validate_tags_value_max_length(): function test_validate_tags_value_exceeds_max_length (line 53) | def test_validate_tags_value_exceeds_max_length(): function test_validate_tags_numeric_key (line 59) | def test_validate_tags_numeric_key(): function test_validate_tags_alphanumeric_key (line 64) | def test_validate_tags_alphanumeric_key(): function test_tags_in_pydantic_model (line 69) | def test_tags_in_pydantic_model(): FILE: tests/sdk/conversation/test_visualizer.py class _UnknownEventForVisualizerTest (line 44) | class _UnknownEventForVisualizerTest(Event): class _Cp1252Stdout (line 56) | class _Cp1252Stdout: method __init__ (line 61) | def __init__(self) -> None: method fileno (line 64) | def fileno(self) -> int: method flush (line 67) | def flush(self) -> None: method isatty (line 70) | def isatty(self) -> bool: method write (line 73) | def write(self, text: str) -> int: method getvalue (line 77) | def getvalue(self) -> str: class VisualizerMockAction (line 81) | class VisualizerMockAction(Action): class VisualizerCustomAction (line 88) | class VisualizerCustomAction(Action): method visualize (line 94) | def visualize(self) -> Text: class VisualizerMockObservation (line 104) | class VisualizerMockObservation(Observation): class VisualizerMockExecutor (line 110) | class VisualizerMockExecutor(ToolExecutor): method __call__ (line 113) | def __call__( class VisualizerMockTool (line 121) | class VisualizerMockTool( method create (line 127) | def create(cls, *args, **kwargs) -> Sequence[Self]: function create_tool_call (line 138) | def create_tool_call( function test_action_base_visualize (line 150) | def test_action_base_visualize(): function test_custom_action_visualize (line 166) | def test_custom_action_visualize(): function test_system_prompt_event_visualize (line 184) | def test_system_prompt_event_visualize(): function test_action_event_visualize (line 203) | def test_action_event_visualize(): function test_observation_event_visualize (line 229) | def test_observation_event_visualize(): function test_message_event_visualize (line 250) | def test_message_event_visualize(): function test_agent_error_event_visualize (line 273) | def test_agent_error_event_visualize(): function test_pause_event_visualize (line 289) | def test_pause_event_visualize(): function test_conversation_visualizer_initialization (line 300) | def test_conversation_visualizer_initialization(): function test_default_visualizer_handles_unicode_on_legacy_windows_stdout (line 308) | def test_default_visualizer_handles_unicode_on_legacy_windows_stdout(mon... function test_visualizer_event_panel_creation (line 327) | def test_visualizer_event_panel_creation(): function test_visualizer_action_event_with_none_action_panel (line 349) | def test_visualizer_action_event_with_none_action_panel(): function test_visualizer_user_reject_observation_panel (line 384) | def test_visualizer_user_reject_observation_panel(): function test_visualizer_condensation_request_panel (line 411) | def test_visualizer_condensation_request_panel(): function test_metrics_formatting (line 435) | def test_metrics_formatting(): function test_metrics_subtitle_caps_cache_rate_when_cache_exceeds_prompt (line 477) | def test_metrics_subtitle_caps_cache_rate_when_cache_exceeds_prompt(): function test_metrics_abbreviation_formatting (line 509) | def test_metrics_abbreviation_formatting(): function test_event_base_fallback_visualize (line 554) | def test_event_base_fallback_visualize(): function test_conversation_error_event_visualize (line 564) | def test_conversation_error_event_visualize(): function test_visualizer_conversation_state_update_event_skipped (line 581) | def test_visualizer_conversation_state_update_event_skipped(): function test_default_visualizer_create_sub_visualizer_returns_none (line 591) | def test_default_visualizer_create_sub_visualizer_returns_none(): FILE: tests/sdk/critic/api/test_template_render.py function renderer (line 392) | def renderer(qwen3_tokenizer_config_path): function test_chat_template_regression (line 400) | def test_chat_template_regression( function generate_ground_truth (line 428) | def generate_ground_truth(tokenizer_name: str = "Qwen/Qwen3-4B-Instruct-... FILE: tests/sdk/critic/test_critic.py class DummyAction (line 21) | class DummyAction(Action): function test_critic_result_success_threshold (line 27) | def test_critic_result_success_threshold(): function test_critic_result_validation (line 42) | def test_critic_result_validation(): function test_pass_critic_always_succeeds (line 56) | def test_pass_critic_always_succeeds(): function test_empty_patch_critic_with_empty_patch (line 90) | def test_empty_patch_critic_with_empty_patch(): function test_empty_patch_critic_with_non_empty_patch (line 112) | def test_empty_patch_critic_with_non_empty_patch(): function test_agent_finished_critic_with_empty_patch (line 133) | def test_agent_finished_critic_with_empty_patch(): function test_agent_finished_critic_without_finish_action (line 163) | def test_agent_finished_critic_without_finish_action(): function test_agent_finished_critic_success (line 199) | def test_agent_finished_critic_success(): function test_agent_finished_critic_last_action_not_finish (line 247) | def test_agent_finished_critic_last_action_not_finish(): function test_critic_base_is_abstract (line 291) | def test_critic_base_is_abstract(): FILE: tests/sdk/critic/test_critic_client.py function test_critic_client_uses_current_default_route (line 16) | def test_critic_client_uses_current_default_route(): function test_critic_client_with_str_api_key (line 26) | def test_critic_client_with_str_api_key(): function test_critic_client_with_secret_str_api_key (line 34) | def test_critic_client_with_secret_str_api_key(): function test_critic_client_empty_string_api_key (line 43) | def test_critic_client_empty_string_api_key(): function test_critic_client_whitespace_only_api_key (line 50) | def test_critic_client_whitespace_only_api_key(): function test_critic_client_empty_secret_str_api_key (line 57) | def test_critic_client_empty_secret_str_api_key(): function test_critic_client_normalizes_redacted_api_key_placeholder (line 64) | def test_critic_client_normalizes_redacted_api_key_placeholder(): function test_critic_client_rejects_none_api_key_for_inference (line 71) | def test_critic_client_rejects_none_api_key_for_inference(): function test_critic_client_whitespace_secret_str_api_key (line 79) | def test_critic_client_whitespace_secret_str_api_key(): function test_critic_client_api_key_not_exposed_in_repr (line 86) | def test_critic_client_api_key_not_exposed_in_repr(): function test_critic_client_api_key_preserved_after_validation (line 98) | def test_critic_client_api_key_preserved_after_validation(): function test_critic_client_api_key_exposed_with_context (line 114) | def test_critic_client_api_key_exposed_with_context(): function test_critic_client_api_key_encrypted_with_cipher (line 123) | def test_critic_client_api_key_encrypted_with_cipher(): function test_agent_dump_exposes_nested_critic_api_key_with_context (line 137) | def test_agent_dump_exposes_nested_critic_api_key_with_context(): function test_agent_dump_encrypts_nested_critic_api_key_with_cipher (line 154) | def test_agent_dump_encrypts_nested_critic_api_key_with_cipher(): FILE: tests/sdk/critic/test_critic_display.py function test_format_critic_result_with_json_message (line 6) | def test_format_critic_result_with_json_message(): function test_format_critic_result_with_plain_message (line 37) | def test_format_critic_result_with_plain_message(): function test_format_critic_result_without_message (line 51) | def test_format_critic_result_without_message(): function test_visualize_consistency (line 65) | def test_visualize_consistency(): function test_format_critic_result_sorting (line 89) | def test_format_critic_result_sorting(): function test_color_highlighting (line 113) | def test_color_highlighting(): function test_star_rating (line 148) | def test_star_rating(): function test_star_style (line 181) | def test_star_style(): function test_visualize_with_categorized_features (line 196) | def test_visualize_with_categorized_features(): FILE: tests/sdk/event/test_action_event_summary.py function tool_call (line 11) | def tool_call(): function test_action_event_summary_visualization (line 17) | def test_action_event_summary_visualization(tool_call): function test_action_event_no_summary_visualization (line 36) | def test_action_event_no_summary_visualization(tool_call): FILE: tests/sdk/event/test_dynamic_context_message_sequence.py function test_events_to_messages_system_prompt_blocks (line 19) | def test_events_to_messages_system_prompt_blocks(dynamic_context, expect... FILE: tests/sdk/event/test_event_immutability.py class EventsImmutabilityMockAction (line 34) | class EventsImmutabilityMockAction(Action): class EventsImmutabilityMockObservation (line 40) | class EventsImmutabilityMockObservation(Observation): method to_llm_content (line 46) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class EventsImmutabilityMockExecutor (line 50) | class EventsImmutabilityMockExecutor(ToolExecutor): method __call__ (line 53) | def __call__( class EventsImmutabilityMockTool (line 61) | class EventsImmutabilityMockTool( method create (line 67) | def create(cls, *args, **kwargs) -> Sequence[Self]: class _TestEventForImmutability (line 78) | class _TestEventForImmutability(Event): function test_event_base_is_frozen (line 90) | def test_event_base_is_frozen(): function test_system_prompt_event_is_frozen (line 108) | def test_system_prompt_event_is_frozen(): function test_action_event_is_frozen (line 128) | def test_action_event_is_frozen(): function test_observation_event_is_frozen (line 158) | def test_observation_event_is_frozen(): function test_message_event_is_frozen (line 183) | def test_message_event_is_frozen(): function test_user_reject_observation_is_frozen (line 205) | def test_user_reject_observation_is_frozen(): function test_user_reject_observation_rejection_source (line 231) | def test_user_reject_observation_rejection_source(): function test_agent_error_event_is_frozen (line 253) | def test_agent_error_event_is_frozen(): function test_pause_event_is_frozen (line 267) | def test_pause_event_is_frozen(): function test_condensation_is_frozen (line 279) | def test_condensation_is_frozen(): function test_condensation_request_is_frozen (line 298) | def test_condensation_request_is_frozen(): function test_event_model_copy_creates_new_instance (line 310) | def test_event_model_copy_creates_new_instance(): function test_event_immutability_prevents_mutation_bugs (line 325) | def test_event_immutability_prevents_mutation_bugs(): FILE: tests/sdk/event/test_event_serialization.py class EventSerializationMockEvent (line 26) | class EventSerializationMockEvent(Event): class EventsSerializationMockAction (line 30) | class EventsSerializationMockAction(Action): method execute (line 33) | def execute(self) -> "EventsSerializationMockObservation": class EventsSerializationMockObservation (line 39) | class EventsSerializationMockObservation(Observation): function test_event_base_serialization (line 45) | def test_event_base_serialization() -> None: function test_system_prompt_event_serialization (line 54) | def test_system_prompt_event_serialization() -> None: function test_action_event_serialization (line 65) | def test_action_event_serialization() -> None: function test_observation_event_serialization (line 98) | def test_observation_event_serialization() -> None: function test_message_event_serialization (line 123) | def test_message_event_serialization() -> None: function test_agent_error_event_serialization (line 138) | def test_agent_error_event_serialization() -> None: function test_condensation_serialization (line 149) | def test_condensation_serialization() -> None: function test_condensation_deserializes_from_list_format (line 163) | def test_condensation_deserializes_from_list_format() -> None: function test_condensation_request_serialization (line 180) | def test_condensation_request_serialization() -> None: function test_extra_fields_forbidden (line 189) | def test_extra_fields_forbidden(): function test_event_deserialize (line 207) | def test_event_deserialize(): FILE: tests/sdk/event/test_events_to_messages.py class EventsToMessagesMockAction (line 26) | class EventsToMessagesMockAction(Action): class EventsToMessagesMockObservation (line 32) | class EventsToMessagesMockObservation(Observation): method to_llm_content (line 38) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: function create_tool_call (line 42) | def create_tool_call( function create_action_event (line 54) | def create_action_event( class TestEventsToMessages (line 76) | class TestEventsToMessages: method test_empty_events_list (line 79) | def test_empty_events_list(self): method test_single_message_event (line 85) | def test_single_message_event(self): method test_single_action_event (line 103) | def test_single_action_event(self): method test_parallel_function_calling_same_response_id (line 126) | def test_parallel_function_calling_same_response_id(self): method test_multiple_separate_action_events (line 199) | def test_multiple_separate_action_events(self): method test_mixed_event_types (line 231) | def test_mixed_event_types(self): method test_agent_error_event (line 289) | def test_agent_error_event(self): method test_complex_parallel_and_sequential_mix (line 304) | def test_complex_parallel_and_sequential_mix(self): method test_assertion_error_for_non_empty_thought_in_parallel_calls (line 392) | def test_assertion_error_for_non_empty_thought_in_parallel_calls(self): method test_action_event_with_none_action_round_trip_and_observation_match (line 421) | def test_action_event_with_none_action_round_trip_and_observation_matc... FILE: tests/sdk/event/test_llm_completion_log_event.py function test_llm_completion_log_event_creation (line 8) | def test_llm_completion_log_event_creation() -> None: function test_llm_completion_log_event_serialization (line 22) | def test_llm_completion_log_event_serialization() -> None: function test_llm_completion_log_event_as_base_event (line 48) | def test_llm_completion_log_event_as_base_event() -> None: function test_llm_completion_log_event_str (line 64) | def test_llm_completion_log_event_str() -> None: FILE: tests/sdk/event/test_non_executable_action_event.py function test_action_event_with_none_action_to_llm_message_round_trip (line 8) | def test_action_event_with_none_action_to_llm_message_round_trip() -> None: FILE: tests/sdk/event/test_streaming.py function test_streaming_delta_event_fields (line 18) | def test_streaming_delta_event_fields(kwargs, expected_content, expected... function test_streaming_delta_event_model_dump_includes_kind (line 25) | def test_streaming_delta_event_model_dump_includes_kind(): function test_streaming_delta_event_json_round_trip (line 33) | def test_streaming_delta_event_json_round_trip(): FILE: tests/sdk/event/test_system_prompt_event_visualize.py class SimpleAction (line 17) | class SimpleAction(Action): class SimpleObservation (line 23) | class SimpleObservation(Observation): class SimpleExecutor (line 29) | class SimpleExecutor(ToolExecutor): method __call__ (line 32) | def __call__( class SimpleTool (line 38) | class SimpleTool(ToolDefinition[SimpleAction, SimpleObservation]): method create (line 42) | def create(cls, *args, **kwargs) -> Sequence[Self]: function test_visualize_no_data_mutation (line 53) | def test_visualize_no_data_mutation(): class LongParametersAction (line 76) | class LongParametersAction(Action): class LongParametersExecutor (line 91) | class LongParametersExecutor(ToolExecutor): method __call__ (line 94) | def __call__( class LongParametersTool (line 102) | class LongParametersTool(ToolDefinition[LongParametersAction, SimpleObse... method create (line 106) | def create(cls, *args, **kwargs) -> Sequence[Self]: function test_visualize_parameter_truncation (line 117) | def test_visualize_parameter_truncation(): function test_visualize_string_truncation_logic (line 144) | def test_visualize_string_truncation_logic(): FILE: tests/sdk/extensions/installation/test_installation_info.py class MockExtension (line 9) | class MockExtension: function test_installation_info_from_extension (line 15) | def test_installation_info_from_extension(): FILE: tests/sdk/extensions/installation/test_installation_manager.py class MockExtension (line 14) | class MockExtension(BaseModel): class MockExtensionInstallationInterface (line 20) | class MockExtensionInstallationInterface(InstallationInterface): method load_from_dir (line 22) | def load_from_dir(extension_dir: Path) -> MockExtension: function _write_mock_extension (line 28) | def _write_mock_extension( function mock_extension (line 43) | def mock_extension() -> MockExtension: function mock_extension_dir (line 51) | def mock_extension_dir(mock_extension: MockExtension, tmp_path: Path) ->... function installation_dir (line 64) | def installation_dir(tmp_path: Path) -> Path: function manager (line 72) | def manager(installation_dir: Path) -> InstallationManager[MockExtension]: function test_install_from_local_path (line 85) | def test_install_from_local_path( function test_install_already_exist_raises_error (line 106) | def test_install_already_exist_raises_error( function test_install_with_force_overwrites (line 119) | def test_install_with_force_overwrites( function test_install_invalid_extension_name_raises_error (line 137) | def test_install_invalid_extension_name_raises_error( function test_install_force_preserves_enabled_state (line 148) | def test_install_force_preserves_enabled_state( function test_uninstall_existing_extension (line 166) | def test_uninstall_existing_extension( function test_uninstall_nonexistent_extension (line 183) | def test_uninstall_nonexistent_extension( function test_uninstall_untracked_extension_does_not_delete (line 191) | def test_uninstall_untracked_extension_does_not_delete( function test_uninstall_tracked_but_directory_missing (line 209) | def test_uninstall_tracked_but_directory_missing( function test_uninstall_invalid_name_raises_error (line 225) | def test_uninstall_invalid_name_raises_error( function test_list_nonexistent_installation_dir (line 238) | def test_list_nonexistent_installation_dir(tmp_path: Path): function test_list_empty_directory (line 247) | def test_list_empty_directory( function test_list_installed_extensions (line 255) | def test_list_installed_extensions( function test_list_discovers_untracked_extensions (line 269) | def test_list_discovers_untracked_extensions( function test_list_cleans_up_missing_extensions (line 286) | def test_list_cleans_up_missing_extensions( function test_load_nonexistent_installation_dir (line 308) | def test_load_nonexistent_installation_dir(tmp_path: Path): function test_load_empty_directory (line 317) | def test_load_empty_directory( function test_load_installed_extensions (line 325) | def test_load_installed_extensions( function test_disable_extension_filters_load (line 338) | def test_disable_extension_filters_load( function test_enable_extension_restores_load (line 355) | def test_enable_extension_restores_load( function test_enable_nonexistent_extension_returns_false (line 370) | def test_enable_nonexistent_extension_returns_false( function test_disable_nonexistent_extension_returns_false (line 377) | def test_disable_nonexistent_extension_returns_false( function test_get_existing_extension (line 389) | def test_get_existing_extension( function test_get_nonexistent_extension (line 402) | def test_get_nonexistent_extension( function test_get_extension_with_missing_directory (line 410) | def test_get_extension_with_missing_directory( function test_update_existing_extension_local (line 429) | def test_update_existing_extension_local( function test_update_nonexistent_extension (line 452) | def test_update_nonexistent_extension( FILE: tests/sdk/extensions/installation/test_installation_metadata.py class MockExtension (line 14) | class MockExtension(BaseModel): class MockExtensionInstallationInterface (line 20) | class MockExtensionInstallationInterface(InstallationInterface): method load_from_dir (line 22) | def load_from_dir(extension_dir: Path) -> MockExtension: function _write_mock_extension (line 28) | def _write_mock_extension( function test_migrate_legacy_plugins_key (line 47) | def test_migrate_legacy_plugins_key(): function test_migrate_legacy_skills_key (line 63) | def test_migrate_legacy_skills_key(): function test_migrate_merges_both_legacy_keys (line 80) | def test_migrate_merges_both_legacy_keys(): function test_migrate_legacy_key_logs_warning (line 103) | def test_migrate_legacy_key_logs_warning(caplog: pytest.LogCaptureFixture): function test_migrate_merges_legacy_into_extensions (line 129) | def test_migrate_merges_legacy_into_extensions(): function test_migrate_extensions_wins_on_conflict (line 152) | def test_migrate_extensions_wins_on_conflict(): function test_migrate_conflicting_legacy_keys (line 174) | def test_migrate_conflicting_legacy_keys(): function test_load_from_dir_nonexistent (line 202) | def test_load_from_dir_nonexistent(tmp_path: Path): function test_load_from_dir_and_save_to_dir (line 208) | def test_load_from_dir_and_save_to_dir(tmp_path: Path): function test_load_from_dir_invalid_json (line 229) | def test_load_from_dir_invalid_json(tmp_path: Path): function test_open_saves_on_clean_exit (line 246) | def test_open_saves_on_clean_exit(tmp_path: Path): function test_open_does_not_save_on_exception (line 264) | def test_open_does_not_save_on_exception(tmp_path: Path): function test_validate_tracked_prunes_invalid_names (line 291) | def test_validate_tracked_prunes_invalid_names(tmp_path: Path): function test_discover_untracked_skips_mismatched_manifest_name (line 324) | def test_discover_untracked_skips_mismatched_manifest_name(tmp_path: Path): FILE: tests/sdk/extensions/installation/test_installation_utils.py function test_validate_extension_name (line 16) | def test_validate_extension_name(input: str, valid: bool): function test_validate_rejects_path_traversal (line 36) | def test_validate_rejects_path_traversal(invalid: str): FILE: tests/sdk/extensions/test_fetch.py function test_parse_github_shorthand (line 23) | def test_parse_github_shorthand(): function test_parse_github_shorthand_with_whitespace (line 29) | def test_parse_github_shorthand_with_whitespace(): function test_parse_github_shorthand_invalid_format (line 35) | def test_parse_github_shorthand_invalid_format(): function test_parse_https_git_url (line 43) | def test_parse_https_git_url(): function test_parse_https_github_url_without_git_suffix (line 49) | def test_parse_https_github_url_without_git_suffix(): function test_parse_https_github_url_with_trailing_slash (line 55) | def test_parse_https_github_url_with_trailing_slash(): function test_parse_https_gitlab_url (line 61) | def test_parse_https_gitlab_url(): function test_parse_https_bitbucket_url (line 67) | def test_parse_https_bitbucket_url(): function test_parse_ssh_git_url (line 73) | def test_parse_ssh_git_url(): function test_parse_git_protocol_url (line 79) | def test_parse_git_protocol_url(): function test_parse_absolute_local_path (line 85) | def test_parse_absolute_local_path(): function test_parse_home_relative_path (line 91) | def test_parse_home_relative_path(): function test_parse_dot_relative_path (line 97) | def test_parse_dot_relative_path(): function test_parse_invalid_source (line 103) | def test_parse_invalid_source(): function test_parse_self_hosted_git_urls (line 108) | def test_parse_self_hosted_git_urls(): function test_parse_http_url (line 118) | def test_parse_http_url(): function test_parse_ssh_with_custom_user (line 124) | def test_parse_ssh_with_custom_user(): function test_parse_relative_path_with_slash (line 131) | def test_parse_relative_path_with_slash(): function test_parse_nested_relative_path (line 137) | def test_parse_nested_relative_path(): function test_source_type_values (line 146) | def test_source_type_values(): function test_cache_path_deterministic (line 155) | def test_cache_path_deterministic(tmp_path: Path): function test_cache_path_different_sources (line 162) | def test_cache_path_different_sources(tmp_path: Path): function test_cache_path_includes_readable_name (line 168) | def test_cache_path_includes_readable_name(tmp_path: Path): function test_fetch_local_path (line 177) | def test_fetch_local_path(tmp_path: Path): function test_fetch_local_path_nonexistent (line 185) | def test_fetch_local_path_nonexistent(tmp_path: Path): function test_fetch_github_shorthand_clones (line 193) | def test_fetch_github_shorthand_clones(tmp_path: Path): function test_fetch_with_ref (line 214) | def test_fetch_with_ref(tmp_path: Path): function test_fetch_updates_existing_cache (line 235) | def test_fetch_updates_existing_cache(tmp_path: Path): function test_fetch_no_update_uses_cache (line 255) | def test_fetch_no_update_uses_cache(tmp_path: Path): function test_fetch_no_update_with_ref_checks_out (line 274) | def test_fetch_no_update_with_ref_checks_out(tmp_path: Path): function test_fetch_git_error_raises_extension_fetch_error (line 292) | def test_fetch_git_error_raises_extension_fetch_error(tmp_path: Path): function test_fetch_generic_error_raises_extension_fetch_error (line 308) | def test_fetch_generic_error_raises_extension_fetch_error(tmp_path: Path): function test_fetch_with_resolution_local_returns_none_ref (line 323) | def test_fetch_with_resolution_local_returns_none_ref(tmp_path: Path): function test_fetch_with_resolution_remote_returns_sha (line 332) | def test_fetch_with_resolution_remote_returns_sha(tmp_path: Path): function test_fetch_with_resolution_falls_back_on_sha_error (line 352) | def test_fetch_with_resolution_falls_back_on_sha_error(tmp_path: Path): function test_fetch_with_resolution_falls_back_to_head (line 373) | def test_fetch_with_resolution_falls_back_to_head(tmp_path: Path): function test_fetch_local_with_repo_path_raises_error (line 396) | def test_fetch_local_with_repo_path_raises_error(tmp_path: Path): function test_fetch_github_with_repo_path (line 412) | def test_fetch_github_with_repo_path(tmp_path: Path): function test_fetch_github_with_nonexistent_repo_path (line 435) | def test_fetch_github_with_nonexistent_repo_path(tmp_path: Path): function test_fetch_with_repo_path_and_ref (line 453) | def test_fetch_with_repo_path_and_ref(tmp_path: Path): function test_fetch_no_repo_path_returns_root (line 478) | def test_fetch_no_repo_path_returns_root(tmp_path: Path): FILE: tests/sdk/git/test_cached_repo.py function test_clone_calls_git_helper (line 21) | def test_clone_calls_git_helper(tmp_path: Path): function test_clone_with_ref (line 32) | def test_clone_with_ref(tmp_path: Path): function test_clone_removes_existing_directory (line 43) | def test_clone_removes_existing_directory(tmp_path: Path): function test_update_fetches_and_resets (line 57) | def test_update_fetches_and_resets(tmp_path: Path): function test_update_with_ref_checks_out (line 68) | def test_update_with_ref_checks_out(tmp_path: Path): function test_update_detached_head_recovers_to_default_branch (line 78) | def test_update_detached_head_recovers_to_default_branch(tmp_path: Path): function test_update_detached_head_no_default_branch_logs_warning (line 92) | def test_update_detached_head_no_default_branch_logs_warning(tmp_path: P... function test_update_continues_on_fetch_error (line 105) | def test_update_continues_on_fetch_error(tmp_path: Path): function test_update_continues_on_checkout_error (line 117) | def test_update_continues_on_checkout_error(tmp_path: Path): function test_checkout_branch_resets_to_origin (line 129) | def test_checkout_branch_resets_to_origin(tmp_path: Path): function test_checkout_tag_skips_reset (line 140) | def test_checkout_tag_skips_reset(tmp_path: Path): function test_checkout_commit_skips_reset (line 150) | def test_checkout_commit_skips_reset(tmp_path: Path): function test_checkout_branch_handles_reset_error (line 160) | def test_checkout_branch_handles_reset_error(tmp_path: Path): function test_git_clone_called_process_error (line 176) | def test_git_clone_called_process_error(tmp_path: Path): function test_git_clone_timeout (line 184) | def test_git_clone_timeout(tmp_path: Path): function test_git_fetch_with_ref_no_remote (line 194) | def test_git_fetch_with_ref_no_remote(tmp_path: Path): function test_git_fetch_called_process_error (line 213) | def test_git_fetch_called_process_error(tmp_path: Path): function test_git_fetch_timeout (line 222) | def test_git_fetch_timeout(tmp_path: Path): function test_git_checkout_called_process_error (line 233) | def test_git_checkout_called_process_error(tmp_path: Path): function test_git_checkout_timeout (line 243) | def test_git_checkout_timeout(tmp_path: Path): function test_git_reset_hard_called_process_error (line 254) | def test_git_reset_hard_called_process_error(tmp_path: Path): function test_git_reset_hard_timeout (line 264) | def test_git_reset_hard_timeout(tmp_path: Path): function test_git_get_current_branch_error (line 275) | def test_git_get_current_branch_error(tmp_path: Path): function test_git_get_current_branch_timeout (line 284) | def test_git_get_current_branch_timeout(tmp_path: Path): function test_get_default_branch_returns_main (line 298) | def test_get_default_branch_returns_main(tmp_path: Path): function test_get_default_branch_returns_master (line 317) | def test_get_default_branch_returns_master(tmp_path: Path): function test_get_default_branch_returns_none_when_not_set (line 334) | def test_get_default_branch_returns_none_when_not_set(tmp_path: Path): function test_get_default_branch_returns_none_on_unexpected_format (line 351) | def test_get_default_branch_returns_none_on_unexpected_format( function test_lock_file_created_during_clone (line 373) | def test_lock_file_created_during_clone(tmp_path: Path): function test_lock_timeout_returns_none (line 397) | def test_lock_timeout_returns_none(tmp_path: Path): function test_lock_released_after_operation (line 426) | def test_lock_released_after_operation(tmp_path: Path): function test_lock_released_on_error (line 448) | def test_lock_released_on_error(tmp_path: Path): FILE: tests/sdk/git/test_git_changes.py function run_bash_command (line 15) | def run_bash_command(command: str, cwd: str) -> subprocess.CompletedProc... function setup_git_repo (line 27) | def setup_git_repo(repo_dir: str) -> None: function test_get_changes_in_repo_empty_repository (line 34) | def test_get_changes_in_repo_empty_repository(): function test_get_changes_in_repo_new_files (line 43) | def test_get_changes_in_repo_new_files(): function test_get_changes_in_repo_modified_files (line 66) | def test_get_changes_in_repo_modified_files(): function test_get_changes_in_repo_deleted_files (line 98) | def test_get_changes_in_repo_deleted_files(): function test_get_changes_in_repo_mixed_changes (line 121) | def test_get_changes_in_repo_mixed_changes(): function test_get_changes_in_repo_nested_directories (line 153) | def test_get_changes_in_repo_nested_directories(): function test_get_changes_in_repo_staged_and_unstaged (line 182) | def test_get_changes_in_repo_staged_and_unstaged(): function test_get_changes_in_repo_non_git_directory (line 213) | def test_get_changes_in_repo_non_git_directory(): function test_get_changes_in_repo_nonexistent_directory (line 225) | def test_get_changes_in_repo_nonexistent_directory(): function test_get_git_changes_function (line 234) | def test_get_git_changes_function(): function test_get_git_changes_with_path_argument (line 258) | def test_get_git_changes_with_path_argument(): function test_git_change_model_properties (line 273) | def test_git_change_model_properties(): function test_git_change_path_serializes_to_posix_and_deserializes (line 301) | def test_git_change_path_serializes_to_posix_and_deserializes(): function test_git_changes_with_gitignore (line 315) | def test_git_changes_with_gitignore(): function test_get_git_changes_skips_vanished_nested_repo (line 343) | def test_get_git_changes_skips_vanished_nested_repo(): function test_git_changes_with_binary_files (line 392) | def test_git_changes_with_binary_files(): function test_get_changes_in_repo_ref_head_shows_only_uncommitted (line 417) | def test_get_changes_in_repo_ref_head_shows_only_uncommitted(): function test_get_changes_in_repo_invalid_ref_raises (line 447) | def test_get_changes_in_repo_invalid_ref_raises(): function test_get_changes_in_repo_ref_head_on_empty_repo_returns_untracked_as_added (line 459) | def test_get_changes_in_repo_ref_head_on_empty_repo_returns_untracked_as... function test_get_changes_in_repo_ref_head_on_orphan_branch_returns_untracked_as_added (line 481) | def test_get_changes_in_repo_ref_head_on_orphan_branch_returns_untracked... function test_get_changes_in_repo_invalid_non_head_ref_still_raises_after_fix (line 513) | def test_get_changes_in_repo_invalid_non_head_ref_still_raises_after_fix(): function test_get_git_changes_propagates_ref (line 531) | def test_get_git_changes_propagates_ref(): FILE: tests/sdk/git/test_git_diff.py function run_bash_command (line 14) | def run_bash_command(command: str, cwd: str) -> subprocess.CompletedProc... function setup_git_repo (line 26) | def setup_git_repo(repo_dir: str) -> None: function run_in_directory (line 33) | def run_in_directory(temp_dir: str, func, *args, **kwargs): function test_get_git_diff_new_file (line 43) | def test_get_git_diff_new_file(): function test_get_git_diff_modified_file (line 60) | def test_get_git_diff_modified_file(): function test_get_git_diff_deleted_file (line 85) | def test_get_git_diff_deleted_file(): function test_get_git_diff_nested_path (line 108) | def test_get_git_diff_nested_path(): function test_get_git_diff_no_repository (line 139) | def test_get_git_diff_no_repository(): function test_get_git_diff_nonexistent_file (line 152) | def test_get_git_diff_nonexistent_file(): function test_get_closest_git_repo (line 163) | def test_get_closest_git_repo(): function test_git_diff_model_properties (line 185) | def test_git_diff_model_properties(): function test_git_diff_with_empty_file (line 220) | def test_git_diff_with_empty_file(): function test_git_diff_with_special_characters (line 243) | def test_git_diff_with_special_characters(): function test_git_diff_large_file_error (line 273) | def test_git_diff_large_file_error(): function test_get_git_diff_ref_head_compares_against_latest_commit (line 289) | def test_get_git_diff_ref_head_compares_against_latest_commit(): function test_get_git_diff_invalid_ref_raises (line 318) | def test_get_git_diff_invalid_ref_raises(): FILE: tests/sdk/hooks/test_config.py class TestHookMatcher (line 13) | class TestHookMatcher: method test_wildcard_matches_all (line 16) | def test_wildcard_matches_all(self): method test_exact_match (line 23) | def test_exact_match(self): method test_regex_match_with_delimiters (line 29) | def test_regex_match_with_delimiters(self): method test_regex_match_auto_detect (line 36) | def test_regex_match_auto_detect(self): method test_empty_matcher_matches_all (line 51) | def test_empty_matcher_matches_all(self): class TestHookConfig (line 58) | class TestHookConfig: method test_load_from_dict (line 61) | def test_load_from_dict(self): method test_load_from_json_file (line 79) | def test_load_from_json_file(self): method test_load_missing_file_returns_empty (line 94) | def test_load_missing_file_returns_empty(self): method test_load_discovers_config_in_working_dir (line 99) | def test_load_discovers_config_in_working_dir(self): method test_get_hooks_filters_by_tool_name (line 122) | def test_get_hooks_filters_by_tool_name(self): method test_typed_field_instantiation (line 150) | def test_typed_field_instantiation(self): method test_json_round_trip (line 171) | def test_json_round_trip(self): method test_is_empty (line 192) | def test_is_empty(self): method test_legacy_format_is_still_supported (line 202) | def test_legacy_format_is_still_supported(self): method test_duplicate_keys_raises_error (line 215) | def test_duplicate_keys_raises_error(self): method test_unknown_event_type_raises_error (line 227) | def test_unknown_event_type_raises_error(self): class TestAsyncHooks (line 237) | class TestAsyncHooks: method test_async_field_defaults_false (line 240) | def test_async_field_defaults_false(self): method test_async_field_set_true (line 245) | def test_async_field_set_true(self): method test_async_field_parsed_from_json_alias (line 250) | def test_async_field_parsed_from_json_alias(self): method test_async_field_serialization_by_alias (line 264) | def test_async_field_serialization_by_alias(self): method test_async_field_serialization_without_alias (line 271) | def test_async_field_serialization_without_alias(self): method test_async_hook_in_config_round_trip (line 277) | def test_async_hook_in_config_round_trip(self): method test_multiple_async_hooks_across_events (line 298) | def test_multiple_async_hooks_across_events(self): function test_issue_2749 (line 317) | def test_issue_2749(): function test_issue_2749_validation (line 352) | def test_issue_2749_validation(hook_type: HookType, match: str): FILE: tests/sdk/hooks/test_executor.py class TestHookExecutor (line 15) | class TestHookExecutor: method executor (line 19) | def executor(self, tmp_path): method sample_event (line 24) | def sample_event(self): method test_execute_simple_command (line 33) | def test_execute_simple_command(self, executor, sample_event): method test_execute_receives_json_stdin (line 42) | def test_execute_receives_json_stdin(self, executor, sample_event, tmp... method test_execute_blocking_exit_code (line 54) | def test_execute_blocking_exit_code(self, executor, sample_event): method test_execute_json_output_decision (line 64) | def test_execute_json_output_decision(self, executor, sample_event): method test_execute_environment_variables (line 78) | def test_execute_environment_variables(self, executor, sample_event, t... method test_execute_timeout (line 94) | def test_execute_timeout(self, executor, sample_event): method test_execute_all_stops_on_block (line 104) | def test_execute_all_stops_on_block(self, executor, sample_event): method test_execute_captures_stderr (line 118) | def test_execute_captures_stderr(self, executor, sample_event): class TestAsyncHookExecution (line 131) | class TestAsyncHookExecution: method executor (line 135) | def executor(self, tmp_path): method sample_event (line 140) | def sample_event(self): method test_execute_async_hook_returns_immediately (line 149) | def test_execute_async_hook_returns_immediately(self, executor, sample... method test_execute_async_hook_result_fields (line 165) | def test_execute_async_hook_result_fields(self, executor, sample_event): method test_execute_async_hook_process_tracked (line 177) | def test_execute_async_hook_process_tracked(self, executor, sample_eve... method test_execute_async_hook_receives_stdin (line 205) | def test_execute_async_hook_receives_stdin(self, executor, sample_even... method test_execute_async_hook_uses_windows_process_group (line 235) | def test_execute_async_hook_uses_windows_process_group( method test_sync_hook_not_marked_async (line 262) | def test_sync_hook_not_marked_async(self, executor, sample_event): method test_execute_all_with_mixed_sync_async_hooks (line 271) | def test_execute_all_with_mixed_sync_async_hooks( class TestAsyncProcessManager (line 303) | class TestAsyncProcessManager: method test_add_process_and_cleanup_all (line 306) | def test_add_process_and_cleanup_all(self, tmp_path): method test_cleanup_expired_terminates_old_processes (line 336) | def test_cleanup_expired_terminates_old_processes(self, tmp_path): method test_async_process_manager_windows_kill_uses_bounded_wait (line 367) | def test_async_process_manager_windows_kill_uses_bounded_wait(self, mo... method test_cleanup_expired_keeps_active_processes (line 398) | def test_cleanup_expired_keeps_active_processes(self, tmp_path): FILE: tests/sdk/hooks/test_integration.py function _json_command (line 17) | def _json_command(payload: dict[str, object], exit_code: int = 0) -> str: function _stderr_exit_command (line 23) | def _stderr_exit_command(message: str, exit_code: int) -> str: function _write_stdin_to_file_command (line 29) | def _write_stdin_to_file_command(path) -> str: class TestBlockedActionsState (line 37) | class TestBlockedActionsState: method test_blocked_actions_field_exists (line 40) | def test_blocked_actions_field_exists(self): method test_blocked_actions_default_empty (line 45) | def test_blocked_actions_default_empty(self): class TestBlockedStatePersistence (line 72) | class TestBlockedStatePersistence: method _create_persistent_state (line 75) | def _create_persistent_state(self, tmp_path, conversation_id): method test_blocked_entries_persist_across_resume (line 93) | def test_blocked_entries_persist_across_resume(self, tmp_path): method test_blocked_entries_removal_persists (line 106) | def test_blocked_entries_removal_persists(self, tmp_path): class TestUserPromptSubmitBlocking (line 123) | class TestUserPromptSubmitBlocking: method mock_conversation_state (line 127) | def mock_conversation_state(self, tmp_path): method test_is_message_blocked_without_state (line 148) | def test_is_message_blocked_without_state(self, tmp_path): method test_blocking_user_prompt_hook_adds_to_state (line 155) | def test_blocking_user_prompt_hook_adds_to_state( method test_non_blocking_user_prompt_hook_does_not_block (line 191) | def test_non_blocking_user_prompt_hook_does_not_block( class TestHookEventProcessorBlocking (line 224) | class TestHookEventProcessorBlocking: method blocking_config (line 228) | def blocking_config(self, tmp_path): method mock_conversation_state (line 246) | def mock_conversation_state(self, tmp_path): method test_set_conversation_state (line 267) | def test_set_conversation_state(self, tmp_path, mock_conversation_state): method test_blocking_hook_adds_to_state (line 279) | def test_blocking_hook_adds_to_state( method test_is_action_blocked_uses_state (line 313) | def test_is_action_blocked_uses_state( method test_is_action_blocked_without_state (line 330) | def test_is_action_blocked_without_state(self, tmp_path): class TestPostToolUseActionLookup (line 342) | class TestPostToolUseActionLookup: method logging_config (line 346) | def logging_config(self, tmp_path): method mock_conversation_state (line 365) | def mock_conversation_state(self, tmp_path): method test_post_tool_use_finds_action_from_events (line 387) | def test_post_tool_use_finds_action_from_events( method test_post_tool_use_without_state_does_not_crash (line 445) | def test_post_tool_use_without_state_does_not_crash(self, tmp_path, lo... class TestCreateHookCallback (line 473) | class TestCreateHookCallback: method test_create_hook_callback_returns_processor_and_callback (line 476) | def test_create_hook_callback_returns_processor_and_callback(self, tmp... class TestLocalConversationHookCallbackWiring (line 491) | class TestLocalConversationHookCallbackWiring: method test_modified_events_with_additional_context_persisted (line 494) | def test_modified_events_with_additional_context_persisted(self, tmp_p... class TestAdditionalContextInjection (line 543) | class TestAdditionalContextInjection: method mock_conversation_state (line 547) | def mock_conversation_state(self, tmp_path): method test_additional_context_appears_in_extended_content (line 568) | def test_additional_context_appears_in_extended_content( method test_additional_context_appears_in_llm_message (line 617) | def test_additional_context_appears_in_llm_message( method test_additional_context_preserves_existing_extended_content (line 667) | def test_additional_context_preserves_existing_extended_content( class TestStopHookIntegration (line 718) | class TestStopHookIntegration: method mock_conversation_state (line 722) | def mock_conversation_state(self, tmp_path): method test_run_stop_with_allowing_hook (line 743) | def test_run_stop_with_allowing_hook(self, tmp_path, mock_conversation... method test_run_stop_with_denying_hook (line 760) | def test_run_stop_with_denying_hook(self, tmp_path, mock_conversation_... method test_run_stop_with_additional_context_as_feedback (line 780) | def test_run_stop_with_additional_context_as_feedback( method test_stop_hook_error_is_logged_and_allows_stop (line 802) | def test_stop_hook_error_is_logged_and_allows_stop( class TestStopHookConversationIntegration (line 823) | class TestStopHookConversationIntegration: method test_stop_hook_denial_injects_feedback_and_continues (line 826) | def test_stop_hook_denial_injects_feedback_and_continues(self, tmp_path): class TestHookExecutionEventEmission (line 916) | class TestHookExecutionEventEmission: method mock_conversation_state (line 920) | def mock_conversation_state(self, tmp_path): method test_hook_execution_event_emitted_for_user_prompt_submit (line 941) | def test_hook_execution_event_emitted_for_user_prompt_submit( method test_hook_execution_event_not_emitted_when_disabled (line 992) | def test_hook_execution_event_not_emitted_when_disabled( method test_hook_execution_event_captures_blocking (line 1035) | def test_hook_execution_event_captures_blocking( method test_hook_execution_event_emitted_for_session_start (line 1079) | def test_hook_execution_event_emitted_for_session_start( method test_hook_execution_event_emitted_for_stop (line 1117) | def test_hook_execution_event_emitted_for_stop( FILE: tests/sdk/hooks/test_manager.py class TestHookManager (line 10) | class TestHookManager: method tmp_working_dir (line 14) | def tmp_working_dir(self, tmp_path): method config_with_blocking_hook (line 19) | def config_with_blocking_hook(self, tmp_path): method test_run_pre_tool_use_blocks_when_hook_denies (line 40) | def test_run_pre_tool_use_blocks_when_hook_denies( method test_run_post_tool_use (line 59) | def test_run_post_tool_use(self, tmp_working_dir, tmp_path): method test_run_user_prompt_submit (line 85) | def test_run_user_prompt_submit(self, tmp_working_dir): method test_run_session_start (line 110) | def test_run_session_start(self, tmp_working_dir, tmp_path): method test_run_stop_blocked_means_continue (line 126) | def test_run_stop_blocked_means_continue(self, tmp_working_dir, tmp_pa... method test_get_blocking_reason (line 143) | def test_get_blocking_reason(self, tmp_working_dir): class TestAsyncHookManager (line 166) | class TestAsyncHookManager: method tmp_working_dir (line 170) | def tmp_working_dir(self, tmp_path): method test_async_pre_tool_use_logs_warning (line 174) | def test_async_pre_tool_use_logs_warning(self, tmp_working_dir, caplog): method test_async_pre_tool_use_still_runs (line 191) | def test_async_pre_tool_use_still_runs(self, tmp_working_dir, tmp_path): method test_cleanup_async_processes_on_session_end (line 214) | def test_cleanup_async_processes_on_session_end(self, tmp_working_dir,... method test_cleanup_async_processes_method (line 233) | def test_cleanup_async_processes_method(self, tmp_working_dir, tmp_path): method test_mixed_sync_async_hooks_in_post_tool_use (line 250) | def test_mixed_sync_async_hooks_in_post_tool_use(self, tmp_working_dir... method test_session_end_runs_hooks_before_cleanup (line 302) | def test_session_end_runs_hooks_before_cleanup(self, tmp_working_dir, ... FILE: tests/sdk/io/test_filestore_cache.py function test_cache_basic_functionality (line 19) | def test_cache_basic_functionality(): function test_cache_hit_performance (line 34) | def test_cache_hit_performance(): function test_cache_lru_eviction (line 75) | def test_cache_lru_eviction(): function test_cache_memory_limit (line 94) | def test_cache_memory_limit(): function test_cache_invalidation_on_write (line 113) | def test_cache_invalidation_on_write(): function test_cache_invalidation_on_delete (line 130) | def test_cache_invalidation_on_delete(): function test_cache_directory_deletion (line 149) | def test_cache_directory_deletion(): function test_large_number_of_events_no_oom (line 176) | def test_large_number_of_events_no_oom(): function test_cache_correctness_under_concurrent_operations (line 206) | def test_cache_correctness_under_concurrent_operations(): function test_cache_performance_repeated_reads (line 240) | def test_cache_performance_repeated_reads(): function test_cache_zero_size (line 273) | def test_cache_zero_size(): function test_very_large_file_cache (line 285) | def test_very_large_file_cache(): function test_cache_with_evict_correct (line 305) | def test_cache_with_evict_correct(): FILE: tests/sdk/io/test_local_filestore_security.py function test_path_traversal_attacks_blocked (line 11) | def test_path_traversal_attacks_blocked(): function test_legitimate_paths_allowed (line 39) | def test_legitimate_paths_allowed(): function test_edge_cases (line 61) | def test_edge_cases(): function test_root_normalization (line 80) | def test_root_normalization(): function test_file_operations_with_security (line 106) | def test_file_operations_with_security(): FILE: tests/sdk/llm/auth/test_credentials.py function test_oauth_credentials_model (line 14) | def test_oauth_credentials_model(): function test_oauth_credentials_is_expired (line 30) | def test_oauth_credentials_is_expired(): function test_get_credentials_dir_default (line 51) | def test_get_credentials_dir_default(monkeypatch): function test_get_credentials_dir_xdg (line 58) | def test_get_credentials_dir_xdg(monkeypatch, tmp_path): function test_credential_store_save_and_get (line 66) | def test_credential_store_save_and_get(tmp_path): function test_credential_store_get_nonexistent (line 95) | def test_credential_store_get_nonexistent(tmp_path): function test_credential_store_get_invalid_json (line 101) | def test_credential_store_get_invalid_json(tmp_path): function test_credential_store_delete (line 115) | def test_credential_store_delete(tmp_path): function test_credential_store_update_tokens (line 134) | def test_credential_store_update_tokens(tmp_path): function test_credential_store_update_tokens_keeps_refresh_if_not_provided (line 163) | def test_credential_store_update_tokens_keeps_refresh_if_not_provided(tm... function test_credential_store_update_tokens_nonexistent (line 187) | def test_credential_store_update_tokens_nonexistent(tmp_path): FILE: tests/sdk/llm/auth/test_openai.py function test_generate_pkce (line 36) | def test_generate_pkce(): function test_pkce_codes_are_unique (line 47) | def test_pkce_codes_are_unique(): function test_build_authorize_url (line 55) | def test_build_authorize_url(): function test_openai_codex_models (line 73) | def test_openai_codex_models(): function test_openai_subscription_auth_vendor (line 82) | def test_openai_subscription_auth_vendor(): function test_openai_subscription_auth_get_credentials (line 88) | def test_openai_subscription_auth_get_credentials(tmp_path): function test_openai_subscription_auth_has_valid_credentials (line 111) | def test_openai_subscription_auth_has_valid_credentials(tmp_path): function test_openai_subscription_auth_logout (line 140) | def test_openai_subscription_auth_logout(tmp_path): function test_openai_subscription_auth_create_llm_invalid_model (line 163) | def test_openai_subscription_auth_create_llm_invalid_model(tmp_path): function test_openai_subscription_auth_create_llm_no_credentials (line 181) | def test_openai_subscription_auth_create_llm_no_credentials(tmp_path): function test_openai_subscription_auth_create_llm_success (line 190) | def test_openai_subscription_auth_create_llm_success(tmp_path): class _FakeAsyncClient (line 213) | class _FakeAsyncClient: method __init__ (line 214) | def __init__(self, responses): method __aenter__ (line 218) | async def __aenter__(self): method __aexit__ (line 221) | async def __aexit__(self, exc_type, exc, tb): method post (line 224) | async def post(self, url, **kwargs): function _response (line 232) | def _response(status_code=200, payload=None): function test_request_device_code_success (line 241) | async def test_request_device_code_success(): function test_poll_device_code_retries_pending_then_succeeds (line 276) | async def test_poll_device_code_retries_pending_then_succeeds(): function test_openai_subscription_auth_login_device_code (line 329) | async def test_openai_subscription_auth_login_device_code(tmp_path): function test_openai_subscription_auth_refresh_if_needed_no_creds (line 378) | async def test_openai_subscription_auth_refresh_if_needed_no_creds(tmp_p... function test_openai_subscription_auth_refresh_if_needed_valid_creds (line 388) | async def test_openai_subscription_auth_refresh_if_needed_valid_creds(tm... function test_openai_subscription_auth_refresh_if_needed_expired_creds (line 408) | async def test_openai_subscription_auth_refresh_if_needed_expired_creds(... class TestConsentBannerSystem (line 445) | class TestConsentBannerSystem: method test_consent_banner_content (line 448) | def test_consent_banner_content(self): method test_consent_marker_path (line 454) | def test_consent_marker_path(self, tmp_path): method test_has_acknowledged_consent_false_initially (line 463) | def test_has_acknowledged_consent_false_initially(self, tmp_path): method test_mark_consent_acknowledged (line 470) | def test_mark_consent_acknowledged(self, tmp_path): method test_display_consent_user_accepts (line 479) | def test_display_consent_user_accepts(self, tmp_path, capsys): method test_display_consent_user_declines (line 497) | def test_display_consent_user_declines(self, tmp_path, capsys): method test_display_consent_non_interactive_first_time_raises (line 510) | def test_display_consent_non_interactive_first_time_raises(self, tmp_p... method test_display_consent_non_interactive_after_acknowledgment (line 522) | def test_display_consent_non_interactive_after_acknowledgment(self, tm... method test_display_consent_keyboard_interrupt (line 534) | def test_display_consent_keyboard_interrupt(self, tmp_path): method test_display_consent_eof_error (line 547) | def test_display_consent_eof_error(self, tmp_path): function test_no_authlib_jose_import (line 566) | def test_no_authlib_jose_import(): function test_joserfc_keyset_import (line 589) | def test_joserfc_keyset_import(): function rsa_signing_key (line 622) | def rsa_signing_key(): function mock_jwks_cache (line 628) | def mock_jwks_cache(rsa_signing_key): function _sign_jwt (line 639) | def _sign_jwt(key: RSAKey, claims: dict) -> str: function test_extract_chatgpt_account_id_success (line 645) | def test_extract_chatgpt_account_id_success(rsa_signing_key, mock_jwks_c... function test_extract_chatgpt_account_id_missing_claim (line 660) | def test_extract_chatgpt_account_id_missing_claim(rsa_signing_key, mock_... function test_extract_chatgpt_account_id_wrong_key (line 666) | def test_extract_chatgpt_account_id_wrong_key(rsa_signing_key): function test_extract_chatgpt_account_id_jwks_fetch_failure (line 690) | def test_extract_chatgpt_account_id_jwks_fetch_failure(): FILE: tests/sdk/llm/test_api_connection_error_retry.py function create_mock_response (line 12) | def create_mock_response(content: str = "Test response", response_id: st... function default_config (line 32) | def default_config(): function test_completion_retries_api_connection_error (line 44) | def test_completion_retries_api_connection_error( function test_completion_max_retries_api_connection_error (line 81) | def test_completion_max_retries_api_connection_error( function test_completion_no_retry_on_success (line 133) | def test_completion_no_retry_on_success(mock_litellm_completion, default... function test_completion_no_retry_on_non_retryable_error (line 158) | def test_completion_no_retry_on_non_retryable_error( function test_retry_configuration_validation (line 186) | def test_retry_configuration_validation(): function test_retry_listener_callback (line 214) | def test_retry_listener_callback(mock_litellm_completion, default_config): FILE: tests/sdk/llm/test_api_key_validation.py function test_empty_api_key_string_converted_to_none (line 10) | def test_empty_api_key_string_converted_to_none(): function test_whitespace_api_key_converted_to_none (line 20) | def test_whitespace_api_key_converted_to_none(): function test_valid_api_key_preserved (line 30) | def test_valid_api_key_preserved(): function test_none_api_key_preserved (line 38) | def test_none_api_key_preserved(): function test_empty_string_direct_input (line 48) | def test_empty_string_direct_input(): function test_whitespace_string_direct_input (line 57) | def test_whitespace_string_direct_input(): function test_bedrock_model_with_none_api_key (line 67) | def test_bedrock_model_with_none_api_key(): function test_bedrock_model_with_api_key_not_forwarded_to_litellm (line 79) | def test_bedrock_model_with_api_key_not_forwarded_to_litellm(): function test_non_bedrock_model_with_valid_key (line 95) | def test_non_bedrock_model_with_valid_key(): function test_aws_credentials_handling (line 105) | def test_aws_credentials_handling(): function test_plain_string_api_key (line 125) | def test_plain_string_api_key(): function test_plain_string_aws_credentials (line 133) | def test_plain_string_aws_credentials(): function test_aws_session_token_handling (line 153) | def test_aws_session_token_handling(): function test_aws_profile_name_handling (line 168) | def test_aws_profile_name_handling(): function test_aws_role_based_auth_fields (line 180) | def test_aws_role_based_auth_fields(): function test_aws_bedrock_runtime_endpoint (line 194) | def test_aws_bedrock_runtime_endpoint(): function test_aws_bedrock_params_forwarded_to_litellm (line 206) | def test_aws_bedrock_params_forwarded_to_litellm(): function test_aws_env_vars_not_leaked_on_init (line 251) | def test_aws_env_vars_not_leaked_on_init(monkeypatch): function test_aws_kwargs_returns_all_params (line 283) | def test_aws_kwargs_returns_all_params(): FILE: tests/sdk/llm/test_chat_options.py class DummyLLM (line 9) | class DummyLLM: method _openrouter_headers (line 25) | def _openrouter_headers(self) -> dict[str, str]: method effective_max_output_tokens (line 34) | def effective_max_output_tokens(self) -> int: function test_opus_4_5_uses_reasoning_effort_and_strips_temp_top_p (line 38) | def test_opus_4_5_uses_reasoning_effort_and_strips_temp_top_p(): function test_gpt5_uses_reasoning_effort_and_strips_temp_top_p (line 61) | def test_gpt5_uses_reasoning_effort_and_strips_temp_top_p(): function test_kimi_k2_thinking_does_not_send_reasoning_effort (line 78) | def test_kimi_k2_thinking_does_not_send_reasoning_effort(): function test_gemini_2_5_pro_without_reasoning_effort_preserves_temp_and_top_p (line 90) | def test_gemini_2_5_pro_without_reasoning_effort_preserves_temp_and_top_... function test_non_reasoning_model_preserves_temp_and_top_p (line 99) | def test_non_reasoning_model_preserves_temp_and_top_p(): function test_azure_renames_max_completion_tokens_to_max_tokens (line 108) | def test_azure_renames_max_completion_tokens_to_max_tokens(): function test_tools_removed_when_has_tools_false (line 116) | def test_tools_removed_when_has_tools_false(): function test_extra_body_is_forwarded (line 125) | def test_extra_body_is_forwarded(): function test_claude_sonnet_4_6_strips_temp_and_top_p (line 132) | def test_claude_sonnet_4_6_strips_temp_and_top_p(): function test_extended_thinking_budget_clamped_below_max_tokens (line 150) | def test_extended_thinking_budget_clamped_below_max_tokens(): function test_chat_options_forwards_prompt_cache_key_when_set (line 198) | def test_chat_options_forwards_prompt_cache_key_when_set(): function test_chat_options_omits_prompt_cache_key_when_unset (line 208) | def test_chat_options_omits_prompt_cache_key_when_unset(): function test_chat_options_injects_openrouter_headers_via_extra_headers (line 215) | def test_chat_options_injects_openrouter_headers_via_extra_headers(): function test_chat_options_user_extra_headers_win_over_openrouter_defaults (line 227) | def test_chat_options_user_extra_headers_win_over_openrouter_defaults(): function test_chat_options_omits_openrouter_headers_when_unset (line 241) | def test_chat_options_omits_openrouter_headers_when_unset(): FILE: tests/sdk/llm/test_exception.py function test_llm_malformed_action_error_default (line 1) | def test_llm_malformed_action_error_default(): function test_llm_malformed_action_error_custom (line 10) | def test_llm_malformed_action_error_custom(): function test_llm_no_action_error_default (line 20) | def test_llm_no_action_error_default(): function test_llm_no_action_error_custom (line 29) | def test_llm_no_action_error_custom(): function test_llm_response_error_default (line 39) | def test_llm_response_error_default(): function test_llm_response_error_custom (line 48) | def test_llm_response_error_custom(): function test_llm_context_window_exceed_error_default (line 58) | def test_llm_context_window_exceed_error_default(): function test_llm_context_window_exceed_error_custom (line 69) | def test_llm_context_window_exceed_error_custom(): function test_llm_malformed_conversation_history_error_default (line 79) | def test_llm_malformed_conversation_history_error_default(): function test_llm_malformed_conversation_history_error_custom (line 92) | def test_llm_malformed_conversation_history_error_custom(): function test_function_call_not_exists_error (line 102) | def test_function_call_not_exists_error(): function test_user_cancelled_error_default (line 112) | def test_user_cancelled_error_default(): function test_user_cancelled_error_custom (line 120) | def test_user_cancelled_error_custom(): function test_operation_cancelled_error_default (line 129) | def test_operation_cancelled_error_default(): function test_operation_cancelled_error_custom (line 137) | def test_operation_cancelled_error_custom(): FILE: tests/sdk/llm/test_exception_classifier.py function test_is_context_window_exceeded_direct_type (line 18) | def test_is_context_window_exceeded_direct_type(): function test_is_context_window_exceeded_via_text (line 25) | def test_is_context_window_exceeded_via_text(): function test_is_context_window_exceeded_minimax_api_connection_error (line 42) | def test_is_context_window_exceeded_minimax_api_connection_error(): function test_looks_like_malformed_conversation_history_error_positive (line 55) | def test_looks_like_malformed_conversation_history_error_positive(): function test_is_context_window_exceeded_negative (line 75) | def test_is_context_window_exceeded_negative(): function test_looks_like_auth_error_positive (line 82) | def test_looks_like_auth_error_positive(): function test_looks_like_auth_error_negative (line 89) | def test_looks_like_auth_error_negative(): FILE: tests/sdk/llm/test_exception_mapping.py function test_map_auth_error_from_bad_request (line 20) | def test_map_auth_error_from_bad_request(): function test_map_auth_error_from_openai_error (line 26) | def test_map_auth_error_from_openai_error(): function test_map_typed_authentication_error_without_pattern_match (line 35) | def test_map_typed_authentication_error_without_pattern_match(): function test_map_typed_permission_denied_error (line 43) | def test_map_typed_permission_denied_error(): function test_map_malformed_tool_history_bad_request (line 53) | def test_map_malformed_tool_history_bad_request(): function test_map_generic_bad_request (line 69) | def test_map_generic_bad_request(): function test_passthrough_unknown_exception (line 75) | def test_passthrough_unknown_exception(): FILE: tests/sdk/llm/test_llm.py function default_llm (line 24) | def default_llm(): function test_llm_init_with_default_config (line 35) | def test_llm_init_with_default_config(default_llm): function test_base_url_for_openhands_provider (line 47) | def test_base_url_for_openhands_provider(mock_get): function test_base_url_for_openhands_provider_with_explicit_none (line 62) | def test_base_url_for_openhands_provider_with_explicit_none(mock_get): function test_kimi_k2_5_uses_provider_defaults (line 83) | def test_kimi_k2_5_uses_provider_defaults(mock_get): function test_base_url_for_openhands_provider_with_custom_url (line 109) | def test_base_url_for_openhands_provider_with_custom_url(mock_get): function test_token_usage_add (line 126) | def test_token_usage_add(): function test_metrics_merge_accumulated_token_usage (line 161) | def test_metrics_merge_accumulated_token_usage(): function test_metrics_diff (line 200) | def test_metrics_diff(): function test_llm_completion_with_mock (line 235) | def test_llm_completion_with_mock(mock_completion): function test_llm_retry_on_rate_limit (line 260) | def test_llm_retry_on_rate_limit(mock_completion): function test_llm_cost_calculation (line 292) | def test_llm_cost_calculation(default_llm): function test_llm_token_counting (line 306) | def test_llm_token_counting(default_llm): function test_llm_forwards_extra_headers_to_litellm (line 323) | def test_llm_forwards_extra_headers_to_litellm(mock_completion): function test_llm_responses_forwards_extra_headers_to_litellm (line 349) | def test_llm_responses_forwards_extra_headers_to_litellm(mock_responses): function test_completion_merges_llm_extra_headers_with_extended_thinking_default (line 398) | def test_completion_merges_llm_extra_headers_with_extended_thinking_defa... function test_completion_call_time_extra_headers_override_config_and_defaults (line 429) | def test_completion_call_time_extra_headers_override_config_and_defaults( function test_responses_call_time_extra_headers_override_config (line 464) | def test_responses_call_time_extra_headers_override_config(mock_responses): function test_llm_vision_support (line 510) | def test_llm_vision_support(default_llm): function test_llm_function_calling_support (line 519) | def test_llm_function_calling_support(default_llm): function test_llm_function_calling_enabled_by_default (line 528) | def test_llm_function_calling_enabled_by_default(): function test_llm_function_calling_can_be_disabled (line 545) | def test_llm_function_calling_can_be_disabled(): function test_llm_force_string_serializer_auto_detect (line 567) | def test_llm_force_string_serializer_auto_detect(): function test_llm_force_string_serializer_override (line 601) | def test_llm_force_string_serializer_override(): function test_llm_caching_support (line 642) | def test_llm_caching_support(default_llm): function test_llm_string_representation (line 651) | def test_llm_string_representation(default_llm): function test_llm_local_detection_based_on_model_name (line 666) | def test_llm_local_detection_based_on_model_name(default_llm): function test_llm_local_detection_based_on_base_url (line 683) | def test_llm_local_detection_based_on_base_url(): function test_llm_openhands_provider_rewrite (line 704) | def test_llm_openhands_provider_rewrite(default_llm): function test_metrics_copy (line 726) | def test_metrics_copy(): function test_metrics_log (line 752) | def test_metrics_log(): function test_llm_config_validation (line 764) | def test_llm_config_validation(): function test_llm_no_response_error (line 787) | def test_llm_no_response_error(mock_completion): function test_response_latency_tracking (line 818) | def test_response_latency_tracking(default_llm): function test_token_usage_context_window (line 838) | def test_token_usage_context_window(): function test_telemetry_cost_calculation_header_exception (line 869) | def test_telemetry_cost_calculation_header_exception(): function test_enable_encrypted_reasoning_respects_flag_and_defaults_true (line 897) | def test_enable_encrypted_reasoning_respects_flag_and_defaults_true(): function test_unmapped_model_with_logging_enabled (line 939) | def test_unmapped_model_with_logging_enabled(mock_transport): function test_llm_raises_error_on_small_context_window (line 989) | def test_llm_raises_error_on_small_context_window(mock_get_model_info): function test_llm_respects_allow_short_context_windows_env_var (line 1009) | def test_llm_respects_allow_short_context_windows_env_var(mock_get_model... function test_llm_model_copy_preserves_configuration (line 1032) | def test_llm_model_copy_preserves_configuration(): function test_llm_reset_metrics (line 1058) | def test_llm_reset_metrics(): function test_issue_2459_restore_metrics_syncs_telemetry (line 1080) | def test_issue_2459_restore_metrics_syncs_telemetry(): function llm (line 1106) | def llm(): function test_cost_recorded_in_restored_metrics (line 1115) | def test_cost_recorded_in_restored_metrics(llm): function test_stale_metrics_not_updated (line 1127) | def test_stale_metrics_not_updated(llm): function test_restore_metrics_telemetry_none (line 1141) | def test_restore_metrics_telemetry_none(): function test_conversation_stats_restore_then_track (line 1158) | def test_conversation_stats_restore_then_track(): function test_telemetry_callback_preserved_across_revalidation (line 1183) | def test_telemetry_callback_preserved_across_revalidation(): function test_max_output_tokens_capped_when_using_max_tokens_fallback (line 1214) | def test_max_output_tokens_capped_when_using_max_tokens_fallback(mock_ge... function test_max_output_tokens_uses_actual_value_when_available (line 1248) | def test_max_output_tokens_uses_actual_value_when_available(mock_get_mod... function test_max_output_tokens_small_max_tokens_not_capped (line 1269) | def test_max_output_tokens_small_max_tokens_not_capped(mock_get_model_in... function test_explicit_max_output_tokens_not_overridden (line 1292) | def test_explicit_max_output_tokens_not_overridden(): function test_max_output_tokens_capped_when_equal_to_context_window (line 1307) | def test_max_output_tokens_capped_when_equal_to_context_window( function test_max_output_tokens_capped_when_equal_to_max_tokens (line 1333) | def test_max_output_tokens_capped_when_equal_to_max_tokens( function test_max_output_tokens_not_capped_when_below_context_window (line 1358) | def test_max_output_tokens_not_capped_when_below_context_window( FILE: tests/sdk/llm/test_llm_completion.py function create_mock_response (line 33) | def create_mock_response(content: str = "Test response", response_id: st... class _ArgsBasic (line 53) | class _ArgsBasic(Action): class _MockTool (line 59) | class _MockTool(ToolDefinition[_ArgsBasic, None]): method create (line 65) | def create(cls, conv_state=None, **params) -> Sequence["_MockTool"]: function default_config (line 70) | def default_config(): function test_litellm_modify_params_context_serializes_threads (line 81) | def test_litellm_modify_params_context_serializes_threads(): function test_llm_completion_basic (line 137) | def test_llm_completion_basic(mock_completion): function test_llm_streaming_not_supported (line 170) | def test_llm_streaming_not_supported(default_config): function test_llm_completion_streaming_with_callback (line 183) | def test_llm_completion_streaming_with_callback(mock_stream_builder, moc... function test_llm_completion_streaming_with_tools (line 274) | def test_llm_completion_streaming_with_tools(mock_stream_builder, mock_c... function test_llm_completion_with_tools (line 386) | def test_llm_completion_with_tools(mock_completion): function test_llm_completion_error_handling (line 431) | def test_llm_completion_error_handling(mock_completion): function test_llm_token_counting_basic (line 453) | def test_llm_token_counting_basic(default_config): function test_llm_model_info_initialization (line 469) | def test_llm_model_info_initialization(default_config): function test_llm_feature_detection (line 480) | def test_llm_feature_detection(default_config): function test_llm_cost_tracking (line 490) | def test_llm_cost_tracking(default_config): function test_llm_latency_tracking (line 503) | def test_llm_latency_tracking(default_config): function test_llm_token_usage_tracking (line 516) | def test_llm_token_usage_tracking(default_config): function test_llm_completion_with_custom_params (line 541) | def test_llm_completion_with_custom_params(mock_completion, default_conf... function test_llm_completion_non_function_call_mode (line 578) | def test_llm_completion_non_function_call_mode(mock_completion): function test_llm_completion_function_call_vs_non_function_call_mode (line 657) | def test_llm_completion_function_call_vs_non_function_call_mode(mock_com... function test_llm_streaming_preserves_cache_read_tokens (line 720) | def test_llm_streaming_preserves_cache_read_tokens(mock_completion): FILE: tests/sdk/llm/test_llm_fallback.py function _get_mock_response (line 20) | def _get_mock_response(content: str = "ok", model: str = "gpt-4o") -> Mo... function _get_llm (line 37) | def _get_llm(model: str = "gpt-4o", **kw) -> LLM: function _patch_resolve (line 52) | def _patch_resolve(primary: LLM, fallback_instances: list[LLM]): function test_primary_succeeds_fallback_not_tried (line 59) | def test_primary_succeeds_fallback_not_tried(mock_comp): function test_fallback_succeeds_after_primary_transient_failure (line 76) | def test_fallback_succeeds_after_primary_transient_failure(mock_comp): function test_all_fallbacks_fail_raises_primary_error (line 100) | def test_all_fallbacks_fail_raises_primary_error(mock_comp): function test_non_transient_error_skips_fallback (line 118) | def test_non_transient_error_skips_fallback(mock_comp): function test_no_fallbacks_configured_normal_error (line 136) | def test_no_fallbacks_configured_normal_error(mock_comp): function test_metrics_merged_from_fallback (line 149) | def test_metrics_merged_from_fallback(mock_comp): function test_second_fallback_succeeds (line 187) | def test_second_fallback_succeeds(mock_comp): function test_responses_fallback_succeeds (line 215) | def test_responses_fallback_succeeds(mock_resp): function test_responses_non_transient_skips_fallback (line 264) | def test_responses_non_transient_skips_fallback(mock_resp): function test_fallback_profiles_resolved_via_store (line 279) | def test_fallback_profiles_resolved_via_store(mock_comp, tmp_path): FILE: tests/sdk/llm/test_llm_fncall_converter.py function test_stop_words_defined (line 52) | def test_stop_words_defined(): function test_convert_fncall_to_non_fncall_basic (line 59) | def test_convert_fncall_to_non_fncall_basic(): function test_convert_non_fncall_to_fncall_basic (line 99) | def test_convert_non_fncall_to_fncall_basic(): function test_convert_fncall_to_non_fncall_with_in_context_learning (line 133) | def test_convert_fncall_to_non_fncall_with_in_context_learning(): function test_convert_fncall_to_non_fncall_without_in_context_learning (line 160) | def test_convert_fncall_to_non_fncall_without_in_context_learning(): function test_convert_with_multiple_tool_calls (line 173) | def test_convert_with_multiple_tool_calls(): function test_convert_with_tool_response (line 208) | def test_convert_with_tool_response(): function test_convert_roundtrip (line 255) | def test_convert_roundtrip(): function test_convert_with_invalid_function_call (line 296) | def test_convert_with_invalid_function_call(): function test_convert_with_malformed_parameters (line 326) | def test_convert_with_malformed_parameters(): function test_convert_empty_messages (line 355) | def test_convert_empty_messages(): function test_convert_with_no_tools (line 368) | def test_convert_with_no_tools(): function test_convert_preserves_user_messages (line 384) | def test_convert_preserves_user_messages(): function test_convert_with_system_message (line 404) | def test_convert_with_system_message(): function test_convert_with_finish_tool (line 438) | def test_convert_with_finish_tool(): function test_convert_tools_to_description_array_items (line 472) | def test_convert_tools_to_description_array_items(): function test_convert_tool_call_to_string_parameterized (line 666) | def test_convert_tool_call_to_string_parameterized(tool_call, expected): function test_convert_fncall_messages_with_cache_control (line 672) | def test_convert_fncall_messages_with_cache_control(): function test_convert_fncall_messages_without_cache_control (line 701) | def test_convert_fncall_messages_without_cache_control(): function test_convert_fncall_messages_with_image_url (line 728) | def test_convert_fncall_messages_with_image_url(): function test_convert_tools_to_description_nested_array (line 776) | def test_convert_tools_to_description_nested_array(): function test_convert_tools_to_description_union_options (line 826) | def test_convert_tools_to_description_union_options(): function test_convert_tools_to_description_object_details (line 867) | def test_convert_tools_to_description_object_details(): function test_system_message_suffix_template_excludes_security_risk_by_default (line 925) | def test_system_message_suffix_template_excludes_security_risk_by_defaul... function test_security_params_included_when_flag_is_true (line 932) | def test_security_params_included_when_flag_is_true(): function test_security_params_excluded_when_flag_is_false (line 950) | def test_security_params_excluded_when_flag_is_false(): FILE: tests/sdk/llm/test_llm_image_resizing.py function _make_png_data_url (line 12) | def _make_png_data_url(width: int, height: int) -> str: function _data_url_dimensions (line 20) | def _data_url_dimensions(url: str) -> tuple[int, int]: function _image_urls_from_chat_message (line 27) | def _image_urls_from_chat_message(chat_message: dict) -> list[str]: function _format_for_provider (line 35) | def _format_for_provider( function test_maybe_resize_messages_for_provider_does_not_mutate_inputs (line 45) | def test_maybe_resize_messages_for_provider_does_not_mutate_inputs(): function test_anthropic_many_image_requests_resize_base64_images (line 69) | def test_anthropic_many_image_requests_resize_base64_images(): function test_proxy_anthropic_many_image_requests_use_model_info_provider (line 94) | def test_proxy_anthropic_many_image_requests_use_model_info_provider(): function test_anthropic_exactly_twenty_images_use_standard_limit (line 121) | def test_anthropic_exactly_twenty_images_use_standard_limit(): function test_anthropic_single_image_requests_do_not_resize (line 143) | def test_anthropic_single_image_requests_do_not_resize(): function test_anthropic_single_image_requests_resize_above_standard_limit (line 165) | def test_anthropic_single_image_requests_resize_above_standard_limit(): function test_anthropic_many_image_requests_leave_url_images_unchanged (line 186) | def test_anthropic_many_image_requests_leave_url_images_unchanged(): function test_non_anthropic_many_image_requests_do_not_resize (line 206) | def test_non_anthropic_many_image_requests_do_not_resize(): FILE: tests/sdk/llm/test_llm_json_storage.py function test_llm_store_and_load_json (line 12) | def test_llm_store_and_load_json(): FILE: tests/sdk/llm/test_llm_litellm_extra_body.py function test_completion_forwards_extra_body_for_proxy_models (line 9) | def test_completion_forwards_extra_body_for_proxy_models(): function test_responses_forwards_extra_body_for_all_models (line 49) | def test_responses_forwards_extra_body_for_all_models(): FILE: tests/sdk/llm/test_llm_log_completions_integration.py function test_llm_log_completions_integration_no_warnings (line 21) | def test_llm_log_completions_integration_no_warnings(): function test_llm_log_completions_with_tool_calls (line 93) | def test_llm_log_completions_with_tool_calls(): FILE: tests/sdk/llm/test_llm_metrics.py function test_cost_creation_valid (line 9) | def test_cost_creation_valid(): function test_cost_creation_zero (line 17) | def test_cost_creation_zero(): function test_cost_creation_negative_fails (line 23) | def test_cost_creation_negative_fails(): function test_cost_pydantic_features (line 34) | def test_cost_pydantic_features(): function test_response_latency_creation_valid (line 50) | def test_response_latency_creation_valid(): function test_response_latency_creation_zero (line 58) | def test_response_latency_creation_zero(): function test_response_latency_creation_negative_fails (line 64) | def test_response_latency_creation_negative_fails(): function test_response_latency_pydantic_features (line 75) | def test_response_latency_pydantic_features(): function test_token_usage_creation_valid (line 90) | def test_token_usage_creation_valid(): function test_token_usage_creation_zeros (line 112) | def test_token_usage_creation_zeros(): function test_token_usage_negative_prompt_tokens_fails (line 130) | def test_token_usage_negative_prompt_tokens_fails(): function test_token_usage_negative_completion_tokens_fails (line 151) | def test_token_usage_negative_completion_tokens_fails(): function test_token_usage_negative_cache_tokens_fails (line 172) | def test_token_usage_negative_cache_tokens_fails(): function test_token_usage_addition (line 199) | def test_token_usage_addition(): function test_token_usage_pydantic_features (line 235) | def test_token_usage_pydantic_features(): function test_metrics_creation_empty (line 270) | def test_metrics_creation_empty(): function test_metrics_creation_with_model_name (line 281) | def test_metrics_creation_with_model_name(): function test_metrics_add_cost (line 290) | def test_metrics_add_cost(): function test_metrics_add_cost_with_model_name (line 301) | def test_metrics_add_cost_with_model_name(): function test_metrics_add_multiple_costs (line 312) | def test_metrics_add_multiple_costs(): function test_metrics_add_response_latency (line 323) | def test_metrics_add_response_latency(): function test_metrics_add_multiple_response_latencies (line 333) | def test_metrics_add_multiple_response_latencies(): function test_metrics_add_token_usage_first_time (line 344) | def test_metrics_add_token_usage_first_time(): function test_metrics_add_token_usage_accumulate (line 359) | def test_metrics_add_token_usage_accumulate(): function test_metrics_merge_empty_metrics (line 373) | def test_metrics_merge_empty_metrics(): function test_metrics_merge_with_costs (line 384) | def test_metrics_merge_with_costs(): function test_metrics_merge_with_token_usage (line 397) | def test_metrics_merge_with_token_usage(): function test_metrics_merge_with_response_latencies (line 411) | def test_metrics_merge_with_response_latencies(): function test_metrics_get_method (line 425) | def test_metrics_get_method(): function test_metrics_diff_method (line 440) | def test_metrics_diff_method(): function test_metrics_diff_with_none_token_usage (line 458) | def test_metrics_diff_with_none_token_usage(): function test_metrics_deep_copy (line 476) | def test_metrics_deep_copy(): function test_metrics_pydantic_features (line 500) | def test_metrics_pydantic_features(): function test_metrics_validation_errors (line 523) | def test_metrics_validation_errors(): function test_metrics_model_validator (line 538) | def test_metrics_model_validator(): function test_metrics_empty_state_operations (line 555) | def test_metrics_empty_state_operations(): function test_metrics_as_pydantic_field (line 576) | def test_metrics_as_pydantic_field(): function test_metrics_cost_negative_validation (line 600) | def test_metrics_cost_negative_validation(): function test_metrics_accumulated_cost_negative_validation (line 609) | def test_metrics_accumulated_cost_negative_validation(): function test_metrics_add_token_usage_none_accumulated (line 618) | def test_metrics_add_token_usage_none_accumulated(): function test_metrics_merge_max_budget_from_other (line 640) | def test_metrics_merge_max_budget_from_other(): function test_metrics_merge_accumulated_token_usage_none_self (line 654) | def test_metrics_merge_accumulated_token_usage_none_self(): function test_metrics_diff_current_usage_not_none (line 678) | def test_metrics_diff_current_usage_not_none(): function test_metrics_diff_both_usage_none (line 709) | def test_metrics_diff_both_usage_none(): function test_cost_positive_validation (line 722) | def test_cost_positive_validation(): function test_metrics_accumulated_cost_positive_validation (line 730) | def test_metrics_accumulated_cost_positive_validation(): function test_metrics_add_token_usage_with_existing_accumulated (line 737) | def test_metrics_add_token_usage_with_existing_accumulated(): function test_metrics_add_token_usage_none_accumulated_initial (line 766) | def test_metrics_add_token_usage_none_accumulated_initial(): function test_cost_validator_positive_path (line 788) | def test_cost_validator_positive_path(): function test_metrics_accumulated_cost_validator_positive_path (line 796) | def test_metrics_accumulated_cost_validator_positive_path(): function test_metrics_diff_current_only_not_none (line 803) | def test_metrics_diff_current_only_not_none(): FILE: tests/sdk/llm/test_llm_no_response_retry.py function create_mock_response (line 11) | def create_mock_response( function create_empty_choices_response (line 31) | def create_empty_choices_response(response_id: str = "empty-1") -> Model... function base_llm (line 43) | def base_llm() -> LLM: function test_no_response_retries_then_succeeds (line 56) | def test_no_response_retries_then_succeeds(mock_completion, base_llm: LL... function test_no_response_exhausts_retries_bubbles_llm_no_response (line 72) | def test_no_response_exhausts_retries_bubbles_llm_no_response( function test_no_response_retry_bumps_temperature (line 91) | def test_no_response_retry_bumps_temperature(mock_completion, base_llm: ... FILE: tests/sdk/llm/test_llm_pricing_passthrough.py function test_llm_pricing_passthrough_custom_rates (line 9) | def test_llm_pricing_passthrough_custom_rates(): FILE: tests/sdk/llm/test_llm_profile_store.py function profile_store (line 18) | def profile_store(tmp_path: Path) -> LLMProfileStore: function sample_llm (line 24) | def sample_llm() -> LLM: function sample_llm_with_secrets (line 35) | def sample_llm_with_secrets() -> LLM: function test_init_creates_directory (line 45) | def test_init_creates_directory(tmp_path: Path) -> None: function test_init_with_string_path (line 56) | def test_init_with_string_path(tmp_path: Path) -> None: function test_init_with_path_object (line 65) | def test_init_with_path_object(tmp_path: Path) -> None: function test_init_with_existing_directory (line 74) | def test_init_with_existing_directory(tmp_path: Path) -> None: function test_list_empty_store (line 84) | def test_list_empty_store(profile_store: LLMProfileStore) -> None: function test_list_with_profiles (line 90) | def test_list_with_profiles(profile_store: LLMProfileStore, sample_llm: ... function test_list_excludes_non_json_files (line 102) | def test_list_excludes_non_json_files( function test_save_creates_file (line 116) | def test_save_creates_file(profile_store: LLMProfileStore, sample_llm: L... function test_save_writes_profile_schema_version (line 124) | def test_save_writes_profile_schema_version( function test_load_rejects_newer_profile_schema_version (line 135) | def test_load_rejects_newer_profile_schema_version( function test_save_with_invalid_profile_name (line 163) | def test_save_with_invalid_profile_name( function test_save_writes_valid_json (line 170) | def test_save_writes_valid_json( function test_save_with_json_extension (line 184) | def test_save_with_json_extension( function test_save_overwrites_existing (line 195) | def test_save_overwrites_existing( function test_save_without_secrets (line 215) | def test_save_without_secrets( function test_save_with_secrets (line 228) | def test_save_with_secrets( function test_load_existing_profile (line 242) | def test_load_existing_profile( function test_load_nonexistent_profile (line 256) | def test_load_nonexistent_profile(profile_store: LLMProfileStore) -> None: function test_load_nonexistent_shows_available (line 265) | def test_load_nonexistent_shows_available( function test_load_corrupted_profile (line 280) | def test_load_corrupted_profile(profile_store: LLMProfileStore) -> None: function test_delete_existing_profile (line 294) | def test_delete_existing_profile( function test_delete_nonexistent_profile (line 306) | def test_delete_nonexistent_profile(profile_store: LLMProfileStore) -> N... function test_concurrent_saves (line 311) | def test_concurrent_saves(tmp_path: Path) -> None: function test_concurrent_reads_and_writes (line 347) | def test_concurrent_reads_and_writes(tmp_path: Path) -> None: function test_full_workflow (line 391) | def test_full_workflow(profile_store: LLMProfileStore) -> None: function test_rename_moves_file (line 422) | def test_rename_moves_file(profile_store: LLMProfileStore, sample_llm: L... function test_rename_preserves_secrets (line 431) | def test_rename_preserves_secrets( function test_rename_source_missing_raises (line 442) | def test_rename_source_missing_raises(profile_store: LLMProfileStore) ->... function test_rename_target_exists_raises (line 447) | def test_rename_target_exists_raises( function test_rename_same_name_is_noop (line 461) | def test_rename_same_name_is_noop( function test_rename_same_name_missing_raises (line 469) | def test_rename_same_name_missing_raises(profile_store: LLMProfileStore)... function test_rename_invalid_name_raises (line 475) | def test_rename_invalid_name_raises( function test_list_summaries_empty (line 488) | def test_list_summaries_empty(profile_store: LLMProfileStore) -> None: function test_list_summaries_returns_metadata (line 492) | def test_list_summaries_returns_metadata( function test_list_summaries_api_key_set_with_secrets (line 506) | def test_list_summaries_api_key_set_with_secrets( function test_list_summaries_api_key_redacted_means_not_set (line 515) | def test_list_summaries_api_key_redacted_means_not_set( function test_list_summaries_skips_corrupted (line 525) | def test_list_summaries_skips_corrupted( function test_list_summaries_skips_non_dict (line 535) | def test_list_summaries_skips_non_dict( function test_list_summaries_skips_invalid_filename (line 547) | def test_list_summaries_skips_invalid_filename( function test_save_with_max_profiles_blocks_over_limit (line 562) | def test_save_with_max_profiles_blocks_over_limit( function test_save_with_max_profiles_allows_overwrite (line 572) | def test_save_with_max_profiles_allows_overwrite( function test_save_with_max_profiles_allows_under_limit (line 583) | def test_save_with_max_profiles_allows_under_limit( function test_save_cleans_up_tmp_on_replace_failure (line 591) | def test_save_cleans_up_tmp_on_replace_failure( function test_save_with_max_profiles_ignores_invalid_filenames (line 610) | def test_save_with_max_profiles_ignores_invalid_filenames( function test_list_summaries_does_not_mutate_env (line 623) | def test_list_summaries_does_not_mutate_env( function test_multiple_profiles (line 645) | def test_multiple_profiles(profile_store: LLMProfileStore) -> None: FILE: tests/sdk/llm/test_llm_registry.py class TestLLMRegistry (line 10) | class TestLLMRegistry(unittest.TestCase): method setUp (line 11) | def setUp(self): method test_subscribe_and_notify (line 16) | def test_subscribe_and_notify(self): method test_registry_has_unique_id (line 49) | def test_registry_has_unique_id(self): function test_llm_registry_notify_exception_handling (line 57) | def test_llm_registry_notify_exception_handling(): function test_llm_registry_list_usage_ids (line 80) | def test_llm_registry_list_usage_ids(): function test_llm_registry_add_method (line 107) | def test_llm_registry_add_method(): function test_llm_registry_get_method (line 137) | def test_llm_registry_get_method(): function test_llm_registry_add_get_workflow (line 164) | def test_llm_registry_add_get_workflow(): function test_llm_registry_ensures_independent_metrics_for_copied_llms (line 197) | def test_llm_registry_ensures_independent_metrics_for_copied_llms(): function test_llm_registry_ensures_independent_telemetry_for_copied_llms (line 244) | def test_llm_registry_ensures_independent_telemetry_for_copied_llms(): function test_llm_registry_does_not_reset_metrics_for_independent_llms (line 276) | def test_llm_registry_does_not_reset_metrics_for_independent_llms(): FILE: tests/sdk/llm/test_llm_retry_telemetry.py function create_mock_response (line 19) | def create_mock_response( function test_telemetry_records_only_successful_attempt_latency (line 48) | def test_telemetry_records_only_successful_attempt_latency(mock_litellm_... function test_telemetry_on_request_called_per_retry (line 133) | def test_telemetry_on_request_called_per_retry(mock_litellm_completion): function test_telemetry_metrics_accurate_with_retries (line 199) | def test_telemetry_metrics_accurate_with_retries(mock_litellm_completion): function test_telemetry_no_multiple_records_on_retry (line 258) | def test_telemetry_no_multiple_records_on_retry(mock_litellm_completion): FILE: tests/sdk/llm/test_llm_serialization.py function test_llm_basic_json_serialization (line 11) | def test_llm_basic_json_serialization() -> None: function test_llm_secret_fields_serialization (line 31) | def test_llm_secret_fields_serialization() -> None: function test_llm_model_dump_json_masks_secrets (line 65) | def test_llm_model_dump_json_masks_secrets() -> None: function test_llm_excluded_fields_not_serialized (line 78) | def test_llm_excluded_fields_not_serialized() -> None: function test_llm_private_attributes_not_serialized (line 103) | def test_llm_private_attributes_not_serialized() -> None: function test_llm_field_validation_during_deserialization (line 135) | def test_llm_field_validation_during_deserialization() -> None: function test_llm_supports_field_json_serialization (line 154) | def test_llm_supports_field_json_serialization() -> None: function test_llm_supports_nested_json_serialization (line 179) | def test_llm_supports_nested_json_serialization() -> None: function test_llm_model_validate_json_dict (line 210) | def test_llm_model_validate_json_dict() -> None: FILE: tests/sdk/llm/test_llm_telemetry.py function mock_metrics (line 17) | def mock_metrics(): function basic_telemetry (line 23) | def basic_telemetry(mock_metrics): function mock_response (line 29) | def mock_response(): class TestTelemetryInitialization (line 41) | class TestTelemetryInitialization: method test_telemetry_default_initialization (line 44) | def test_telemetry_default_initialization(self, mock_metrics): method test_telemetry_custom_initialization (line 55) | def test_telemetry_custom_initialization(self, mock_metrics): method test_telemetry_validation_error (line 73) | def test_telemetry_validation_error(self): method test_telemetry_private_attributes (line 78) | def test_telemetry_private_attributes(self, basic_telemetry): class TestTelemetryLifecycle (line 91) | class TestTelemetryLifecycle: method test_on_request_basic (line 94) | def test_on_request_basic(self, basic_telemetry): method test_on_request_with_context (line 103) | def test_on_request_with_context(self, basic_telemetry): method test_on_error_noop_when_logging_disabled (line 110) | def test_on_error_noop_when_logging_disabled(self, basic_telemetry): method test_on_response_latency_tracking (line 117) | def test_on_response_latency_tracking( method test_on_response_with_usage (line 130) | def test_on_response_with_usage(self, basic_telemetry): class TestTelemetryTokenUsage (line 149) | class TestTelemetryTokenUsage: method test_record_usage_basic (line 152) | def test_record_usage_basic(self, basic_telemetry): method test_record_usage_with_cache_read (line 167) | def test_record_usage_with_cache_read(self, basic_telemetry): method test_record_usage_with_cache_write (line 182) | def test_record_usage_with_cache_write(self, basic_telemetry): method test_record_usage_missing_tokens (line 200) | def test_record_usage_missing_tokens(self, basic_telemetry): method test_record_usage_with_none_context_window (line 210) | def test_record_usage_with_none_context_window(self, basic_telemetry): class TestTelemetryCostCalculation (line 226) | class TestTelemetryCostCalculation: method test_compute_cost_with_custom_rates (line 229) | def test_compute_cost_with_custom_rates(self, mock_metrics): method test_compute_cost_from_headers (line 262) | def test_compute_cost_from_headers(self, basic_telemetry): method test_compute_cost_litellm_fallback (line 272) | def test_compute_cost_litellm_fallback(self, basic_telemetry): method test_compute_cost_failure_handling (line 291) | def test_compute_cost_failure_handling(self, basic_telemetry): method test_compute_cost_model_name_processing (line 314) | def test_compute_cost_model_name_processing(self, mock_metrics): method test_compute_cost_passes_provider_to_litellm_cost_calculator (line 337) | def test_compute_cost_passes_provider_to_litellm_cost_calculator( method test_compute_cost_passes_provider_to_litellm_cost_calculator_azure (line 364) | def test_compute_cost_passes_provider_to_litellm_cost_calculator_azure( class TestTelemetryLogging (line 392) | class TestTelemetryLogging: method test_log_completion_disabled (line 395) | def test_log_completion_disabled(self, basic_telemetry, mock_response): method test_log_completion_no_directory (line 408) | def test_log_completion_no_directory(self, mock_metrics, mock_response): method test_log_completion_success (line 417) | def test_log_completion_success(self, mock_metrics, mock_response): method test_log_error_success (line 448) | def test_log_error_success(self, mock_metrics): method test_log_completion_with_raw_response (line 496) | def test_log_completion_with_raw_response(self, mock_metrics, mock_res... method test_log_completion_with_pydantic_objects_in_context (line 523) | def test_log_completion_with_pydantic_objects_in_context( method test_log_completion_error_handling (line 585) | def test_log_completion_error_handling(self, mock_metrics, mock_respon... class TestTelemetryIntegration (line 620) | class TestTelemetryIntegration: method test_full_request_response_cycle (line 623) | def test_full_request_response_cycle(self, mock_metrics): method test_multiple_requests (line 661) | def test_multiple_requests(self, basic_telemetry): class TestSafeJsonFunction (line 694) | class TestSafeJsonFunction: method test_safe_json_with_dict_object (line 697) | def test_safe_json_with_dict_object(self): method test_safe_json_without_dict (line 710) | def test_safe_json_without_dict(self): method test_safe_json_with_exception (line 717) | def test_safe_json_with_exception(self): class TestTelemetryEdgeCases (line 733) | class TestTelemetryEdgeCases: method test_log_completions_no_serialization_warnings (line 736) | def test_log_completions_no_serialization_warnings(self, mock_metrics): method test_on_response_without_on_request (line 816) | def test_on_response_without_on_request(self, basic_telemetry, mock_re... method test_response_id_extraction_edge_cases (line 826) | def test_response_id_extraction_edge_cases(self, basic_telemetry): method test_usage_extraction_edge_cases (line 847) | def test_usage_extraction_edge_cases(self, basic_telemetry): method test_cost_calculation_with_zero_cost (line 871) | def test_cost_calculation_with_zero_cost(self, basic_telemetry, mock_r... class TestTelemetryCallbacks (line 888) | class TestTelemetryCallbacks: method test_set_log_callback (line 891) | def test_set_log_callback(self, basic_telemetry): method test_set_stats_update_callback (line 905) | def test_set_stats_update_callback(self, basic_telemetry): method test_stats_update_callback_triggered_on_response (line 919) | def test_stats_update_callback_triggered_on_response( method test_stats_update_callback_exception_handling (line 935) | def test_stats_update_callback_exception_handling( FILE: tests/sdk/llm/test_llm_timeout.py class TestLLMTimeoutDefaults (line 15) | class TestLLMTimeoutDefaults: method test_default_timeout_is_5_minutes (line 18) | def test_default_timeout_is_5_minutes(self): method test_timeout_can_be_overridden (line 36) | def test_timeout_can_be_overridden(self): method test_timeout_can_be_set_to_none_for_no_timeout (line 43) | def test_timeout_can_be_set_to_none_for_no_timeout(self): method test_timeout_validation_rejects_negative_values (line 54) | def test_timeout_validation_rejects_negative_values(self): method test_timeout_accepts_zero (line 59) | def test_timeout_accepts_zero(self): class TestLLMTimeoutPassthrough (line 65) | class TestLLMTimeoutPassthrough: method test_default_timeout_passed_to_litellm (line 69) | def test_default_timeout_passed_to_litellm(self, mock_completion): method test_custom_timeout_passed_to_litellm (line 115) | def test_custom_timeout_passed_to_litellm(self, mock_completion): method test_none_timeout_passed_to_litellm (line 157) | def test_none_timeout_passed_to_litellm(self, mock_completion): FILE: tests/sdk/llm/test_message.py function test_content_base_class_not_implemented (line 16) | def test_content_base_class_not_implemented(): function test_text_content_with_cache_prompt (line 24) | def test_text_content_with_cache_prompt(): function test_image_content_with_cache_prompt (line 37) | def test_image_content_with_cache_prompt(): function test_message_contains_image_property (line 57) | def test_message_contains_image_property(): function test_message_tool_role_with_cache_prompt (line 78) | def test_message_tool_role_with_cache_prompt(): function test_message_tool_role_with_image_cache_prompt (line 99) | def test_message_tool_role_with_image_cache_prompt(): function test_message_with_tool_calls (line 125) | def test_message_with_tool_calls(): function test_message_tool_calls_drop_empty_string_content (line 156) | def test_message_tool_calls_drop_empty_string_content(): function test_message_tool_calls_strip_blank_list_content (line 177) | def test_message_tool_calls_strip_blank_list_content(): function test_message_from_llm_chat_message_function_role_error (line 200) | def test_message_from_llm_chat_message_function_role_error(): function test_message_from_llm_chat_message_with_non_string_content (line 212) | def test_message_from_llm_chat_message_with_non_string_content(): function test_text_content_truncation_under_limit (line 226) | def test_text_content_truncation_under_limit(): function test_text_content_no_truncation_over_limit (line 237) | def test_text_content_no_truncation_over_limit(): function test_tool_message_truncates_text_over_limit (line 253) | def test_tool_message_truncates_text_over_limit(): function test_user_message_does_not_truncate_text_over_limit (line 284) | def test_user_message_does_not_truncate_text_over_limit(): function test_tool_message_truncates_text_over_limit_with_string_serializer (line 305) | def test_tool_message_truncates_text_over_limit_with_string_serializer(): function test_text_content_truncation_exact_limit (line 328) | def test_text_content_truncation_exact_limit(): function test_message_with_reasoning_content_when_enabled (line 348) | def test_message_with_reasoning_content_when_enabled(): function test_message_with_reasoning_content_when_disabled (line 366) | def test_message_with_reasoning_content_when_disabled(): function test_message_with_reasoning_content_default_disabled (line 382) | def test_message_with_reasoning_content_default_disabled(): function test_message_with_reasoning_content_none (line 398) | def test_message_with_reasoning_content_none(): function test_message_with_reasoning_content_empty_string (line 416) | def test_message_with_reasoning_content_empty_string(): function test_message_with_reasoning_content_list_serializer (line 434) | def test_message_with_reasoning_content_list_serializer(): function test_message_deprecated_fields_silently_removed (line 457) | def test_message_deprecated_fields_silently_removed(): function test_message_deprecated_fields_are_ignored (line 484) | def test_message_deprecated_fields_are_ignored(): function test_text_content_deprecated_enable_truncation_silently_removed (line 513) | def test_text_content_deprecated_enable_truncation_silently_removed(): function test_text_content_old_format_with_enable_truncation_loads_successfully (line 533) | def test_text_content_old_format_with_enable_truncation_loads_successful... function test_text_content_both_old_and_new_format_in_sequence (line 562) | def test_text_content_both_old_and_new_format_in_sequence(): FILE: tests/sdk/llm/test_message_backward_compatibility.py function test_v1_10_0_text_content_with_enable_truncation (line 28) | def test_v1_10_0_text_content_with_enable_truncation(): function test_v1_10_0_text_content_with_enable_truncation_false (line 52) | def test_v1_10_0_text_content_with_enable_truncation_false(): function test_text_content_current_format (line 74) | def test_text_content_current_format(): function test_v1_9_0_message_with_deprecated_fields (line 98) | def test_v1_9_0_message_with_deprecated_fields(): function test_message_current_format (line 141) | def test_message_current_format(): function test_mixed_version_conversation_loads (line 174) | def test_mixed_version_conversation_loads(): function test_v1_10_0_text_content_json_deserialization (line 232) | def test_v1_10_0_text_content_json_deserialization(): function test_v1_9_0_message_json_deserialization (line 255) | def test_v1_9_0_message_json_deserialization(): FILE: tests/sdk/llm/test_message_from_chat_and_helpers.py function test_from_llm_chat_message_raises_when_only_non_function_tool_calls (line 8) | def test_from_llm_chat_message_raises_when_only_non_function_tool_calls(): function test_coerce_content_validator_handles_none_and_string (line 17) | def test_coerce_content_validator_handles_none_and_string(): function test_content_to_str_helper (line 29) | def test_content_to_str_helper(): function test_to_responses_value_system_direct (line 34) | def test_to_responses_value_system_direct(): FILE: tests/sdk/llm/test_message_serialization.py class TestStorageSerialization (line 32) | class TestStorageSerialization: method test_basic_text_message_storage_serialization (line 37) | def test_basic_text_message_storage_serialization(self): method test_vision_message_storage_serialization (line 57) | def test_vision_message_storage_serialization(self): method test_tool_response_message_storage_serialization (line 80) | def test_tool_response_message_storage_serialization(self): method test_empty_content_storage_serialization (line 99) | def test_empty_content_storage_serialization(self): method test_field_defaults_after_minimal_deserialization (line 111) | def test_field_defaults_after_minimal_deserialization(self): class TestLLMAPISerialization (line 128) | class TestLLMAPISerialization: method test_basic_text_message_llm_string_serialization (line 133) | def test_basic_text_message_llm_string_serialization(self): method test_cache_enabled_triggers_list_serialization (line 146) | def test_cache_enabled_triggers_list_serialization(self): method test_vision_enabled_triggers_list_serialization (line 161) | def test_vision_enabled_triggers_list_serialization(self): method test_function_calling_enabled_triggers_list_serialization (line 182) | def test_function_calling_enabled_triggers_list_serialization(self): method test_force_string_serializer_override (line 197) | def test_force_string_serializer_override(self): method test_tool_response_message_llm_serialization (line 215) | def test_tool_response_message_llm_serialization(self): method test_empty_content_llm_serialization (line 231) | def test_empty_content_llm_serialization(self): method test_multiple_text_content_string_serialization (line 242) | def test_multiple_text_content_string_serialization(self): method test_content_type_preservation_in_list_serializer (line 260) | def test_content_type_preservation_in_list_serializer(self): class TestSerializationPathSelection (line 282) | class TestSerializationPathSelection: method test_serialization_path_selection_logic (line 285) | def test_serialization_path_selection_logic(self): class TestDualSerializationConsistency (line 325) | class TestDualSerializationConsistency: method test_storage_always_list_llm_adapts (line 328) | def test_storage_always_list_llm_adapts(self): FILE: tests/sdk/llm/test_message_tool_call.py function test_from_chat_tool_call_success (line 15) | def test_from_chat_tool_call_success(): function test_from_chat_tool_call_non_function_type_raises (line 28) | def test_from_chat_tool_call_non_function_type_raises(): function test_from_chat_tool_call_missing_function_raises (line 36) | def test_from_chat_tool_call_missing_function_raises(): function test_from_chat_tool_call_missing_function_name_raises (line 42) | def test_from_chat_tool_call_missing_function_name_raises(): function test_from_responses_function_call_output_and_response_variants (line 49) | def test_from_responses_function_call_output_and_response_variants(): function test_from_responses_function_call_missing_ids_raises (line 72) | def test_from_responses_function_call_missing_ids_raises(): function test_from_responses_function_call_missing_name_raises (line 81) | def test_from_responses_function_call_missing_name_raises(): function test_to_responses_dict_prefix_and_stringify_arguments (line 89) | def test_to_responses_dict_prefix_and_stringify_arguments(): function test_responses_function_call_round_trip_preserves_ids (line 109) | def test_responses_function_call_round_trip_preserves_ids(): FILE: tests/sdk/llm/test_model_canonical_name_resolution.py class DummyFeatures (line 6) | class DummyFeatures: method __init__ (line 9) | def __init__(self, model: str): function test_model_canonical_name_used_for_capabilities (line 18) | def test_model_canonical_name_used_for_capabilities(monkeypatch): function test_model_canonical_name_with_real_model_info (line 68) | def test_model_canonical_name_with_real_model_info(): FILE: tests/sdk/llm/test_model_features.py function test_model_matches (line 21) | def test_model_matches(name, pattern, expected): function test_reasoning_effort_support (line 72) | def test_reasoning_effort_support(model, expected_reasoning): function test_extended_thinking_support (line 98) | def test_extended_thinking_support(model, expected_extended_thinking): function test_prompt_cache_support (line 135) | def test_prompt_cache_support(model, expected_cache): function test_stop_words_support (line 158) | def test_stop_words_support(model, expected_stop_words): function test_get_features_with_provider_prefix (line 163) | def test_get_features_with_provider_prefix(): function test_get_features_case_insensitive (line 180) | def test_get_features_case_insensitive(): function test_get_features_with_version_suffixes (line 197) | def test_get_features_with_version_suffixes(): function test_model_matches_multiple_patterns (line 213) | def test_model_matches_multiple_patterns(): function test_model_matches_substring_semantics (line 223) | def test_model_matches_substring_semantics(): function test_get_features_unknown_model (line 234) | def test_get_features_unknown_model(): function test_get_features_empty_model (line 244) | def test_get_features_empty_model(): function test_model_matches_with_provider_pattern (line 256) | def test_model_matches_with_provider_pattern(): function test_stop_words_grok_provider_prefixed (line 263) | def test_stop_words_grok_provider_prefixed(): function test_supports_stop_words_false_models (line 280) | def test_supports_stop_words_false_models(model): function test_responses_api_support (line 301) | def test_responses_api_support(model, expected_responses): function test_force_string_serializer_full_model_names (line 306) | def test_force_string_serializer_full_model_names(): function test_prompt_cache_retention_support (line 345) | def test_prompt_cache_retention_support(model, expected_retention): function test_send_reasoning_content_support (line 384) | def test_send_reasoning_content_support(model, expected_send_reasoning): FILE: tests/sdk/llm/test_model_list.py function test_organize_models_and_providers (line 14) | def test_organize_models_and_providers(): function test_list_bedrock_models_without_boto3 (line 51) | def test_list_bedrock_models_without_boto3(monkeypatch): function test_list_bedrock_models_with_boto3 (line 67) | def test_list_bedrock_models_with_boto3(monkeypatch): function test_openhands_models_all_have_provider_list (line 86) | def test_openhands_models_all_have_provider_list(): function test_trinity_model_is_openhands_only (line 111) | def test_trinity_model_is_openhands_only(): FILE: tests/sdk/llm/test_prompt_caching_cross_conversation.py function test_static_system_message_is_constant_across_different_contexts (line 18) | def test_static_system_message_is_constant_across_different_contexts(): function test_end_to_end_caching_flow (line 72) | def test_end_to_end_caching_flow(tmp_path, dynamic_context, expect_dynam... function test_gemini_prompt_caching_marks_formatted_messages (line 147) | def test_gemini_prompt_caching_marks_formatted_messages(): function test_cross_conversation_cache_sharing (line 184) | def test_cross_conversation_cache_sharing(tmp_path, first_suffix, second... FILE: tests/sdk/llm/test_pydantic_warning_suppression.py function test_pydantic_serializer_warnings_suppressed (line 10) | def test_pydantic_serializer_warnings_suppressed(): function test_llm_response_serialization_no_warnings (line 41) | def test_llm_response_serialization_no_warnings(): FILE: tests/sdk/llm/test_reasoning_content.py class _TestActionForReasoningContent (line 8) | class _TestActionForReasoningContent(Action): function create_mock_response (line 20) | def create_mock_response(content: str = "Test response", response_id: st... function test_message_with_reasoning_content (line 38) | def test_message_with_reasoning_content(): function test_message_without_reasoning_content (line 51) | def test_message_without_reasoning_content(): function test_message_from_llm_chat_message_with_reasoning (line 60) | def test_message_from_llm_chat_message_with_reasoning(): function test_message_from_llm_chat_message_without_reasoning (line 80) | def test_message_from_llm_chat_message_without_reasoning(): function test_message_serialization_with_reasoning (line 97) | def test_message_serialization_with_reasoning(): function test_message_serialization_without_reasoning (line 112) | def test_message_serialization_without_reasoning(): function test_action_event_with_reasoning_content (line 123) | def test_action_event_with_reasoning_content(): FILE: tests/sdk/llm/test_responses_parsing_and_kwargs.py function build_responses_message_output (line 22) | def build_responses_message_output(texts: list[str]) -> ResponseOutputMe... function test_from_llm_responses_output_parsing (line 36) | def test_from_llm_responses_output_parsing(): function test_normalize_responses_kwargs_policy (line 65) | def test_normalize_responses_kwargs_policy(): function test_normalize_responses_kwargs_with_summary (line 91) | def test_normalize_responses_kwargs_with_summary(): function test_normalize_responses_kwargs_encrypted_reasoning_disabled (line 104) | def test_normalize_responses_kwargs_encrypted_reasoning_disabled(): function test_llm_responses_end_to_end (line 120) | def test_llm_responses_end_to_end(mock_responses_call): function test_responses_reasoning_effort_none_not_sent_for_gpt_5_1 (line 162) | def test_responses_reasoning_effort_none_not_sent_for_gpt_5_1(model): function test_chat_and_responses_options_prompt_cache_retention_gpt_5_plus_and_non_gpt (line 169) | def test_chat_and_responses_options_prompt_cache_retention_gpt_5_plus_an... function test_responses_options_forwards_prompt_cache_key_when_set (line 251) | def test_responses_options_forwards_prompt_cache_key_when_set(): function test_responses_options_omits_prompt_cache_key_when_unset (line 263) | def test_responses_options_omits_prompt_cache_key_when_unset(): FILE: tests/sdk/llm/test_responses_serialization.py function test_function_call_and_output_paired (line 11) | def test_function_call_and_output_paired(): function test_system_to_responses_value_instructions_concat (line 42) | def test_system_to_responses_value_instructions_concat(): function test_subscription_codex_transport_does_not_use_top_level_instructions_and_prepend_system_to_user (line 53) | def test_subscription_codex_transport_does_not_use_top_level_instruction... function test_subscription_codex_transport_injects_synthetic_user_message_when_none_exists (line 71) | def test_subscription_codex_transport_injects_synthetic_user_message_whe... function test_api_codex_models_keep_system_as_instructions (line 87) | def test_api_codex_models_keep_system_as_instructions(): function test_user_to_responses_dict_with_and_without_vision (line 96) | def test_user_to_responses_dict_with_and_without_vision(): function test_assistant_to_responses_dict_with_text_and_tool_calls (line 120) | def test_assistant_to_responses_dict_with_text_and_tool_calls(): function test_tool_to_responses_emits_function_call_output_with_verbatim_call_id (line 146) | def test_tool_to_responses_emits_function_call_output_with_verbatim_call... function test_tool_to_responses_truncates_output_over_limit (line 159) | def test_tool_to_responses_truncates_output_over_limit(): function test_tool_to_responses_includes_images_in_function_call_output_when_vision_enabled (line 181) | def test_tool_to_responses_includes_images_in_function_call_output_when_... function test_assistant_includes_reasoning_passthrough (line 203) | def test_assistant_includes_reasoning_passthrough(): FILE: tests/sdk/llm/test_subscription_mode.py function _make_subscription_llm (line 37) | def _make_subscription_llm() -> LLM: function _make_generic_output_item (line 49) | def _make_generic_output_item(**kwargs: Any) -> BaseLiteLLMOpenAIRespons... function test_subscription_skips_unsupported_param (line 70) | def test_subscription_skips_unsupported_param(param: str): function test_non_subscription_keeps_scalar_param (line 86) | def test_non_subscription_keeps_scalar_param(param: str, expected_value:... function test_non_subscription_keeps_structured_param (line 102) | def test_non_subscription_keeps_structured_param(param: str, check: Any): function _generic_function_call_item (line 117) | def _generic_function_call_item() -> BaseLiteLLMOpenAIResponseObject: function _generic_message_item (line 128) | def _generic_message_item() -> BaseLiteLLMOpenAIResponseObject: function _generic_reasoning_item (line 139) | def _generic_reasoning_item() -> BaseLiteLLMOpenAIResponseObject: function _dict_function_call_item (line 151) | def _dict_function_call_item() -> dict[str, Any]: function _dict_message_item (line 161) | def _dict_message_item() -> dict[str, Any]: function _typed_function_call_item (line 169) | def _typed_function_call_item() -> ResponseFunctionToolCall: function test_from_llm_responses_output_item_type (line 218) | def test_from_llm_responses_output_item_type( function test_from_llm_responses_output_reasoning_item (line 253) | def test_from_llm_responses_output_reasoning_item( function test_mixed_typed_and_generic_items (line 266) | def test_mixed_typed_and_generic_items(): function _make_conversation_messages (line 281) | def _make_conversation_messages() -> tuple[Message, Message, Message, Me... function test_format_messages_reasoning_item_handling (line 325) | def test_format_messages_reasoning_item_handling( FILE: tests/sdk/llm/test_telemetry_policy.py function test_chat_forwards_extra_body_for_all_models (line 12) | def test_chat_forwards_extra_body_for_all_models(): function test_chat_proxy_forwards_extra_body (line 38) | def test_chat_proxy_forwards_extra_body(): function test_responses_forwards_extra_body_for_all_models (line 65) | def test_responses_forwards_extra_body_for_all_models(mock_responses): function test_responses_proxy_forwards_extra_body (line 94) | def test_responses_proxy_forwards_extra_body(mock_responses): FILE: tests/sdk/llm/test_thinking_blocks.py function create_mock_response_with_thinking (line 10) | def create_mock_response_with_thinking( function test_thinking_block_model (line 49) | def test_thinking_block_model(): function test_thinking_block_without_signature (line 62) | def test_thinking_block_without_signature(): function test_thinking_block_from_litellm_without_signature (line 88) | def test_thinking_block_from_litellm_without_signature(): function test_message_from_llm_chat_message_with_thinking_no_signature (line 113) | def test_message_from_llm_chat_message_with_thinking_no_signature(): function test_message_with_thinking_blocks (line 146) | def test_message_with_thinking_blocks(): function test_message_without_thinking_blocks (line 169) | def test_message_without_thinking_blocks(): function test_message_from_llm_chat_message_with_thinking (line 176) | def test_message_from_llm_chat_message_with_thinking(): function test_message_from_llm_chat_message_without_thinking (line 205) | def test_message_from_llm_chat_message_without_thinking(): function test_message_serialization_with_thinking_blocks (line 219) | def test_message_serialization_with_thinking_blocks(): function test_message_serialization_without_thinking_blocks (line 240) | def test_message_serialization_without_thinking_blocks(): function test_message_list_serializer_with_thinking_blocks (line 249) | def test_message_list_serializer_with_thinking_blocks(): function test_message_event_thinking_blocks_property (line 278) | def test_message_event_thinking_blocks_property(): function test_message_event_str_with_thinking_blocks (line 301) | def test_message_event_str_with_thinking_blocks(): function test_multiple_thinking_blocks (line 322) | def test_multiple_thinking_blocks(): function test_llm_preserves_existing_thinking_blocks (line 356) | def test_llm_preserves_existing_thinking_blocks(): function test_thinking_blocks_in_message_dict (line 391) | def test_thinking_blocks_in_message_dict(): function test_thinking_blocks_in_message_dict_via_to_chat_dict (line 424) | def test_thinking_blocks_in_message_dict_via_to_chat_dict(): function test_no_thinking_blocks_field_when_empty (line 453) | def test_no_thinking_blocks_field_when_empty(): function test_thinking_blocks_only_for_assistant_role (line 467) | def test_thinking_blocks_only_for_assistant_role(): function test_redacted_thinking_block_in_message_dict (line 500) | def test_redacted_thinking_block_in_message_dict(): function test_mixed_thinking_and_redacted_blocks (line 523) | def test_mixed_thinking_and_redacted_blocks(): FILE: tests/sdk/llm/test_vision_support.py function test_vision_is_active_supported_models (line 23) | def test_vision_is_active_supported_models(model): function _collect_image_url_parts (line 31) | def _collect_image_url_parts(chat_message: dict) -> list[dict]: function _has_input_image (line 43) | def _has_input_image(item: dict) -> bool: function test_chat_serializes_images_when_vision_supported (line 62) | def test_chat_serializes_images_when_vision_supported(model): function test_message_with_image_does_not_enable_vision_for_text_only_model (line 85) | def test_message_with_image_does_not_enable_vision_for_text_only_model( function test_disable_vision_overrides_litellm_detection (line 115) | def test_disable_vision_overrides_litellm_detection(): function test_message_with_image_in_responses_does_not_include_input_image (line 154) | def test_message_with_image_in_responses_does_not_include_input_image( function test_responses_serializes_images_when_vision_supported (line 180) | def test_responses_serializes_images_when_vision_supported(model): FILE: tests/sdk/logger/test_litellm_log_suppression.py function test_litellm_loggers_suppressed (line 6) | def test_litellm_loggers_suppressed(): function test_litellm_info_logs_not_shown (line 21) | def test_litellm_info_logs_not_shown(caplog): function test_litellm_logger_level_blocks_info (line 44) | def test_litellm_logger_level_blocks_info(): FILE: tests/sdk/marketplace/test_deprecation.py function test_new_import_location_has_all_exports (line 17) | def test_new_import_location_has_all_exports(): function test_removed_import_from_plugin_raises (line 32) | def test_removed_import_from_plugin_raises(): function test_removed_import_from_plugin_types_raises (line 40) | def test_removed_import_from_plugin_types_raises(): function test_marketplace_functionality_preserved (line 48) | def test_marketplace_functionality_preserved(): FILE: tests/sdk/marketplace/test_marketplace.py class TestMarketplaceOwner (line 17) | class TestMarketplaceOwner: method test_basic_owner (line 20) | def test_basic_owner(self): method test_owner_with_email (line 26) | def test_owner_with_email(self): class TestMarketplacePluginSource (line 33) | class TestMarketplacePluginSource: method test_github_source (line 36) | def test_github_source(self): method test_url_source (line 43) | def test_url_source(self): method test_source_with_ref (line 52) | def test_source_with_ref(self): method test_source_with_path (line 59) | def test_source_with_path(self): method test_github_source_missing_repo_raises_error (line 66) | def test_github_source_missing_repo_raises_error(self): method test_url_source_missing_url_raises_error (line 71) | def test_url_source_missing_url_raises_error(self): class TestMarketplacePluginEntry (line 77) | class TestMarketplacePluginEntry: method test_basic_entry (line 80) | def test_basic_entry(self): method test_entry_with_all_fields (line 88) | def test_entry_with_all_fields(self): method test_entry_with_string_author (line 115) | def test_entry_with_string_author(self): method test_entry_with_github_source (line 128) | def test_entry_with_github_source(self): method test_entry_camel_case_fields (line 140) | def test_entry_camel_case_fields(self): class TestMarketplaceMetadata (line 154) | class TestMarketplaceMetadata: method test_basic_metadata (line 157) | def test_basic_metadata(self): method test_metadata_extra_fields_allowed (line 163) | def test_metadata_extra_fields_allowed(self): class TestMarketplace (line 171) | class TestMarketplace: method test_load_marketplace_with_plugin_dir (line 174) | def test_load_marketplace_with_plugin_dir(self, tmp_path: Path): method test_load_marketplace_with_claude_plugin_dir (line 204) | def test_load_marketplace_with_claude_plugin_dir(self, tmp_path: Path): method test_load_marketplace_with_metadata (line 224) | def test_load_marketplace_with_metadata(self, tmp_path: Path): method test_load_marketplace_with_github_plugin_source (line 251) | def test_load_marketplace_with_github_plugin_source(self, tmp_path: Pa... method test_load_marketplace_with_full_plugin_entry (line 284) | def test_load_marketplace_with_full_plugin_entry(self, tmp_path: Path): method test_load_nonexistent_marketplace (line 329) | def test_load_nonexistent_marketplace(self, tmp_path: Path): method test_load_marketplace_without_manifest (line 334) | def test_load_marketplace_without_manifest(self, tmp_path: Path): method test_load_marketplace_with_invalid_json (line 342) | def test_load_marketplace_with_invalid_json(self, tmp_path: Path): method test_load_marketplace_missing_name (line 355) | def test_load_marketplace_missing_name(self, tmp_path: Path): method test_load_marketplace_missing_owner (line 370) | def test_load_marketplace_missing_owner(self, tmp_path: Path): method test_get_plugin (line 385) | def test_get_plugin(self, tmp_path: Path): method test_resolve_plugin_source_relative_path (line 417) | def test_resolve_plugin_source_relative_path(self, tmp_path: Path): method test_resolve_plugin_source_github (line 444) | def test_resolve_plugin_source_github(self, tmp_path: Path): method test_resolve_plugin_source_github_with_ref_and_path (line 473) | def test_resolve_plugin_source_github_with_ref_and_path(self, tmp_path... method test_resolve_plugin_source_url (line 507) | def test_resolve_plugin_source_url(self, tmp_path: Path): method test_resolve_plugin_source_url_with_ref_and_path (line 536) | def test_resolve_plugin_source_url_with_ref_and_path(self, tmp_path: P... class TestMarketplaceIntegration (line 571) | class TestMarketplaceIntegration: method test_marketplace_plugin_entry_consistency (line 574) | def test_marketplace_plugin_entry_consistency(self): method test_to_plugin_manifest (line 601) | def test_to_plugin_manifest(self): method test_to_plugin_manifest_defaults (line 622) | def test_to_plugin_manifest_defaults(self): method test_to_plugin_manifest_with_entry_command (line 636) | def test_to_plugin_manifest_with_entry_command(self): method test_entry_with_entry_command (line 651) | def test_entry_with_entry_command(self): method test_invalid_github_source_missing_repo (line 661) | def test_invalid_github_source_missing_repo(self, tmp_path: Path): method test_invalid_url_source_missing_url (line 689) | def test_invalid_url_source_missing_url(self, tmp_path: Path): method test_skill_compatible_fields (line 715) | def test_skill_compatible_fields(self): FILE: tests/sdk/mcp/test_create_mcp_tool.py function _find_free_port (line 25) | def _find_free_port() -> int: function _wait_for_port (line 32) | def _wait_for_port(port: int, timeout: float = 5.0, interval: float = 0.... class MCPTestServer (line 53) | class MCPTestServer: method __init__ (line 56) | def __init__(self, name: str = "test-server"): method add_tool (line 61) | def add_tool(self, func): method start (line 65) | def start(self, transport: MCPTransport = "http") -> int: method stop (line 104) | def stop(self): function http_mcp_server (line 113) | def http_mcp_server() -> Generator[MCPTestServer]: function sse_mcp_server (line 133) | def sse_mcp_server() -> Generator[MCPTestServer]: function test_create_mcp_tools_empty_config (line 152) | def test_create_mcp_tools_empty_config(): function test_create_mcp_tools_http_server (line 159) | def test_create_mcp_tools_http_server(http_mcp_server: MCPTestServer): function test_create_mcp_tools_sse_server (line 185) | def test_create_mcp_tools_sse_server(sse_mcp_server: MCPTestServer): function test_create_mcp_tools_mixed_servers (line 204) | def test_create_mcp_tools_mixed_servers( function test_create_mcp_tools_http_schema_validation (line 232) | def test_create_mcp_tools_http_schema_validation(http_mcp_server: MCPTes... function test_create_mcp_tools_transport_inferred_from_url (line 254) | def test_create_mcp_tools_transport_inferred_from_url(http_mcp_server: M... function test_create_mcp_tools_sse_inferred_from_url (line 269) | def test_create_mcp_tools_sse_inferred_from_url(sse_mcp_server: MCPTestS... function test_execute_http_tool (line 284) | def test_execute_http_tool(http_mcp_server: MCPTestServer): function test_execute_sse_tool (line 306) | def test_execute_sse_tool(sse_mcp_server: MCPTestServer): function test_create_mcp_tools_connection_to_nonexistent_server (line 328) | def test_create_mcp_tools_connection_to_nonexistent_server(): function test_create_mcp_tools_stdio_server (line 348) | def test_create_mcp_tools_stdio_server(): function test_create_mcp_tools_timeout_error_message (line 406) | def test_create_mcp_tools_timeout_error_message(): FILE: tests/sdk/mcp/test_mcp_action_serialization.py class _ChildMCPToolActionForSerialization (line 7) | class _ChildMCPToolActionForSerialization(MCPToolAction): function test_data_field_emerges_from_to_mcp_arguments (line 19) | def test_data_field_emerges_from_to_mcp_arguments(): function test_declared_child_fields_with_data (line 31) | def test_declared_child_fields_with_data(): function test_empty_data_field (line 43) | def test_empty_data_field(): function test_data_field_with_none_values (line 50) | def test_data_field_with_none_values(): function test_frozen_model_is_immutable (line 59) | def test_frozen_model_is_immutable(): function test_data_field_type_validation (line 66) | def test_data_field_type_validation(): function test_extra_fields_not_allowed (line 77) | def test_extra_fields_not_allowed(): FILE: tests/sdk/mcp/test_mcp_observation.py function test_mcp_observation_with_list_json (line 12) | def test_mcp_observation_with_list_json(): function test_mcp_observation_with_dict_json (line 48) | def test_mcp_observation_with_dict_json(): function test_mcp_observation_with_string_json (line 77) | def test_mcp_observation_with_string_json(): function test_mcp_observation_with_number_json (line 102) | def test_mcp_observation_with_number_json(): function test_mcp_observation_with_invalid_json (line 127) | def test_mcp_observation_with_invalid_json(): FILE: tests/sdk/mcp/test_mcp_security_risk.py class MockMCPClient (line 10) | class MockMCPClient(MCPClient): method __init__ (line 13) | def __init__(self): method is_connected (line 17) | def is_connected(self): method call_tool_mcp (line 20) | async def call_tool_mcp( # type: ignore[override] method call_async_from_sync (line 29) | def call_async_from_sync(self, coro_func, timeout=None, **kwargs): method __aenter__ (line 39) | async def __aenter__(self): method __aexit__ (line 42) | async def __aexit__(self, *args): function test_mcp_tool_to_openai_with_security_risk (line 46) | def test_mcp_tool_to_openai_with_security_risk(): function test_mcp_tool_action_from_arguments_with_security_risk (line 98) | def test_mcp_tool_action_from_arguments_with_security_risk(): function test_mcp_tool_validates_correctly_after_security_risk_pop (line 136) | def test_mcp_tool_validates_correctly_after_security_risk_pop(): FILE: tests/sdk/mcp/test_mcp_session_persistence.py function _find_free_port (line 21) | def _find_free_port() -> int: function live_server (line 29) | def live_server(): class TestSessionPersistence (line 64) | class TestSessionPersistence: method test_connection_reused_across_tool_calls (line 67) | def test_connection_reused_across_tool_calls(self, live_server: int): method test_close_releases_connection (line 102) | def test_close_releases_connection(self, live_server: int): FILE: tests/sdk/mcp/test_mcp_tool.py class MockMCPClient (line 15) | class MockMCPClient(MCPClient): method __init__ (line 18) | def __init__(self): class TestMCPToolObservation (line 23) | class TestMCPToolObservation: method test_from_call_tool_result_success (line 26) | def test_from_call_tool_result_success(self): method test_from_call_tool_result_error (line 48) | def test_from_call_tool_result_error(self): method test_from_call_tool_result_with_image (line 67) | def test_from_call_tool_result_with_image(self): method test_to_llm_content_success (line 97) | def test_to_llm_content_success(self): method test_to_llm_content_error (line 111) | def test_to_llm_content_error(self): class TestMCPToolExecutor (line 133) | class TestMCPToolExecutor: method setup_method (line 136) | def setup_method(self): method test_call_tool_success (line 143) | def test_call_tool_success(self): method test_call_tool_error (line 170) | def test_call_tool_error(self): method test_call_tool_exception (line 197) | def test_call_tool_exception(self): method test_call_tool_timeout (line 221) | def test_call_tool_timeout(self): method test_close_calls_client_sync_close (line 241) | def test_close_calls_client_sync_close(self): class TestMCPTool (line 249) | class TestMCPTool: method setup_method (line 252) | def setup_method(self): method test_mcp_tool_creation (line 272) | def test_mcp_tool_creation(self): method test_mcp_tool_with_annotations (line 294) | def test_mcp_tool_with_annotations(self): method test_mcp_tool_no_description (line 313) | def test_mcp_tool_no_description(self): method test_executor_assignment (line 331) | def test_executor_assignment(self): FILE: tests/sdk/mcp/test_mcp_tool_immutability.py class MockMCPClient (line 13) | class MockMCPClient(MCPClient): method __init__ (line 16) | def __init__(self): class TestMCPToolImmutability (line 21) | class TestMCPToolImmutability: method setup_method (line 24) | def setup_method(self): method test_mcp_tool_is_frozen (line 44) | def test_mcp_tool_is_frozen(self): method test_mcp_tool_set_executor_returns_new_instance (line 59) | def test_mcp_tool_set_executor_returns_new_instance(self): method test_mcp_tool_model_copy_creates_modified_instance (line 71) | def test_mcp_tool_model_copy_creates_modified_instance(self): method test_mcp_tool_meta_field_immutability (line 97) | def test_mcp_tool_meta_field_immutability(self): method test_mcp_tool_extra_fields_immutability (line 112) | def test_mcp_tool_extra_fields_immutability(self): method test_mcp_tool_create_immutable_instance (line 120) | def test_mcp_tool_create_immutable_instance(self): FILE: tests/sdk/mcp/test_mcp_tool_kind_field.py function fetch_tool (line 13) | def fetch_tool(): function test_real_mcp_tool_excludes_kind_field_from_action_data (line 24) | def test_real_mcp_tool_excludes_kind_field_from_action_data(fetch_tool): function test_real_mcp_tool_with_optional_field_no_kind (line 47) | def test_real_mcp_tool_with_optional_field_no_kind(fetch_tool): function test_real_mcp_tool_drops_none_values_but_not_kind (line 61) | def test_real_mcp_tool_drops_none_values_but_not_kind(fetch_tool): function test_real_mcp_tool_execution_without_kind_field (line 73) | def test_real_mcp_tool_execution_without_kind_field(fetch_tool): FILE: tests/sdk/mcp/test_mcp_tool_serialization.py function create_mock_mcp_tool (line 19) | def create_mock_mcp_tool(name: str) -> mcp.types.Tool: function test_mcp_tool_json_serialization_deserialization (line 34) | def test_mcp_tool_json_serialization_deserialization() -> None: function test_mcp_tool_polymorphic_behavior (line 50) | def test_mcp_tool_polymorphic_behavior() -> None: function test_mcp_tool_kind_field (line 70) | def test_mcp_tool_kind_field() -> None: function test_mcp_tool_fallback_behavior (line 86) | def test_mcp_tool_fallback_behavior() -> None: function test_mcp_tool_essential_properties (line 111) | def test_mcp_tool_essential_properties() -> None: FILE: tests/sdk/mcp/test_mcp_tool_validation.py function _make_tool_with_schema (line 11) | def _make_tool_with_schema(schema: dict): function test_mcp_action_from_arguments_validates_and_sanitizes (line 21) | def test_mcp_action_from_arguments_validates_and_sanitizes(): function test_mcp_action_from_arguments_raises_on_invalid (line 42) | def test_mcp_action_from_arguments_raises_on_invalid(): FILE: tests/sdk/mcp/test_stateful_mcp.py function _find_free_port (line 32) | def _find_free_port() -> int: function stateful_server (line 39) | def stateful_server(): class TestStatefulMCPSessionPersistence (line 109) | class TestStatefulMCPSessionPersistence: method test_counter_persists_across_calls (line 117) | def test_counter_persists_across_calls(self, stateful_server): method test_auth_token_persists_across_tools (line 155) | def test_auth_token_persists_across_tools(self, stateful_server): method test_multiple_operations_same_session (line 198) | def test_multiple_operations_same_session(self, stateful_server): FILE: tests/sdk/observability/test_laminar.py function _reset_observability_cache (line 13) | def _reset_observability_cache(): function test_lmnr_base_url_parsing (line 35) | def test_lmnr_base_url_parsing(env_value, expected): function test_lmnr_base_url_passed_to_laminar (line 70) | def test_lmnr_base_url_passed_to_laminar(): function test_lmnr_base_url_not_passed_when_empty (line 105) | def test_lmnr_base_url_not_passed_when_empty(): function test_get_bool_env (line 157) | def test_get_bool_env(env_value, expected): function test_observe_preserves_async_signature (line 178) | def test_observe_preserves_async_signature(): function test_lmnr_force_http_passed_to_laminar (line 210) | def test_lmnr_force_http_passed_to_laminar(force_http_value, expected_fo... class _DummyOwner (line 256) | class _DummyOwner: method __init__ (line 259) | def __init__(self, root_span): function test_observe_calls_use_span_with_owner_root_span_on_sync (line 268) | def test_observe_calls_use_span_with_owner_root_span_on_sync(): function test_observe_with_owner_root_span_preserves_wrapped_exceptions (line 305) | def test_observe_with_owner_root_span_preserves_wrapped_exceptions(): function test_observe_calls_use_span_with_owner_root_span_on_async (line 338) | def test_observe_calls_use_span_with_owner_root_span_on_async(): function test_two_concurrent_conversations_do_not_collide (line 381) | def test_two_concurrent_conversations_do_not_collide(): function contextlib_compat (line 435) | def contextlib_compat(): function test_deprecated_shims_emit_warnings (line 441) | def test_deprecated_shims_emit_warnings(): FILE: tests/sdk/plugin/test_installed_plugins.py function installed_dir (line 39) | def installed_dir(tmp_path: Path) -> Path: function sample_plugin_dir (line 46) | def sample_plugin_dir(tmp_path: Path) -> Path: function test_get_installed_plugins_dir_returns_default_path (line 74) | def test_get_installed_plugins_dir_returns_default_path(): function test_install_from_local_path (line 81) | def test_install_from_local_path(sample_plugin_dir: Path, installed_dir:... function test_install_already_exists_raises_error (line 90) | def test_install_already_exists_raises_error( function test_install_with_force_overwrites (line 98) | def test_install_with_force_overwrites( function test_uninstall_existing_plugin (line 113) | def test_uninstall_existing_plugin( function test_list_installed_plugins (line 121) | def test_list_installed_plugins(sample_plugin_dir: Path, installed_dir: ... function test_load_installed_plugins (line 128) | def test_load_installed_plugins(sample_plugin_dir: Path, installed_dir: ... function test_disable_plugin_filters_load (line 137) | def test_disable_plugin_filters_load( function test_enable_plugin_restores_load (line 149) | def test_enable_plugin_restores_load( function test_get_existing_plugin (line 161) | def test_get_existing_plugin(sample_plugin_dir: Path, installed_dir: Pat... function test_get_nonexistent_plugin (line 168) | def test_get_nonexistent_plugin(installed_dir: Path) -> None: function test_update_existing_plugin_local (line 172) | def test_update_existing_plugin_local( function test_update_nonexistent_plugin (line 194) | def test_update_nonexistent_plugin(installed_dir: Path) -> None: function test_install_from_github_with_repo_path (line 204) | def test_install_from_github_with_repo_path(installed_dir: Path) -> None: function test_install_from_github_with_ref (line 230) | def test_install_from_github_with_ref(installed_dir: Path) -> None: function test_install_document_skills_plugin (line 251) | def test_install_document_skills_plugin(installed_dir: Path) -> None: FILE: tests/sdk/plugin/test_plugin_fetch.py function test_fetch_git_error_raises_plugin_fetch_error (line 23) | def test_fetch_git_error_raises_plugin_fetch_error(tmp_path: Path): function test_fetch_generic_error_raises_plugin_fetch_error (line 40) | def test_fetch_generic_error_raises_plugin_fetch_error(tmp_path: Path): function test_fetch_local_with_repo_path_raises_plugin_fetch_error (line 53) | def test_fetch_local_with_repo_path_raises_plugin_fetch_error( function test_fetch_uses_default_cache_dir (line 64) | def test_fetch_uses_default_cache_dir(tmp_path: Path): function test_plugin_fetch_delegates (line 85) | def test_plugin_fetch_delegates(tmp_path: Path): function test_plugin_fetch_local_with_repo_path_raises_error (line 94) | def test_plugin_fetch_local_with_repo_path_raises_error(tmp_path: Path): FILE: tests/sdk/plugin/test_plugin_fetch_integration.py class TestGitHelperIntegration (line 15) | class TestGitHelperIntegration: method test_clone_real_repo (line 18) | def test_clone_real_repo(self, tmp_path: Path): method test_clone_with_branch (line 32) | def test_clone_with_branch(self, tmp_path: Path): method test_fetch_and_checkout (line 62) | def test_fetch_and_checkout(self, tmp_path: Path): method test_get_current_branch (line 95) | def test_get_current_branch(self, tmp_path: Path): method test_get_current_branch_detached_head (line 120) | def test_get_current_branch_detached_head(self, tmp_path: Path): class TestFetchPluginIntegration (line 155) | class TestFetchPluginIntegration: method test_fetch_from_local_git_repo (line 158) | def test_fetch_from_local_git_repo(self, tmp_path: Path): method test_fetch_caches_and_updates (line 188) | def test_fetch_caches_and_updates(self, tmp_path: Path): method test_fetch_with_ref (line 224) | def test_fetch_with_ref(self, tmp_path: Path): class TestPluginFetchMethodIntegration (line 259) | class TestPluginFetchMethodIntegration: method test_fetch_and_load_plugin (line 262) | def test_fetch_and_load_plugin(self, tmp_path: Path): FILE: tests/sdk/plugin/test_plugin_loader.py function mock_llm (line 22) | def mock_llm(): function basic_agent (line 31) | def basic_agent(mock_llm): function agent_with_context (line 40) | def agent_with_context(mock_llm): function agent_with_mcp (line 53) | def agent_with_mcp(mock_llm): function create_test_plugin (line 62) | def create_test_plugin( class TestHookConfigMerge (line 103) | class TestHookConfigMerge: method test_merge_empty_list_returns_none (line 106) | def test_merge_empty_list_returns_none(self): method test_merge_single_config (line 111) | def test_merge_single_config(self): method test_merge_multiple_pre_tool_use (line 123) | def test_merge_multiple_pre_tool_use(self): method test_merge_different_event_types (line 141) | def test_merge_different_event_types(self): method test_merge_all_event_types (line 158) | def test_merge_all_event_types(self): method test_merge_empty_configs_returns_none (line 191) | def test_merge_empty_configs_returns_none(self): class TestLoadPluginsSinglePlugin (line 199) | class TestLoadPluginsSinglePlugin: method test_load_empty_list_returns_unchanged_agent (line 202) | def test_load_empty_list_returns_unchanged_agent(self, basic_agent): method test_load_single_plugin_with_skills (line 208) | def test_load_single_plugin_with_skills(self, tmp_path: Path, basic_ag... method test_load_single_plugin_with_mcp (line 224) | def test_load_single_plugin_with_mcp(self, tmp_path: Path, basic_agent): method test_load_single_plugin_with_hooks (line 239) | def test_load_single_plugin_with_hooks(self, tmp_path: Path, basic_age... class TestLoadPluginsMultiplePlugins (line 260) | class TestLoadPluginsMultiplePlugins: method test_load_multiple_plugins_skills_override (line 263) | def test_load_multiple_plugins_skills_override(self, tmp_path: Path, b... method test_load_multiple_plugins_mcp_override (line 286) | def test_load_multiple_plugins_mcp_override(self, tmp_path: Path, basi... method test_load_multiple_plugins_hooks_concatenate (line 307) | def test_load_multiple_plugins_hooks_concatenate(self, tmp_path: Path,... method test_load_multiple_plugins_different_skills (line 337) | def test_load_multiple_plugins_different_skills(self, tmp_path: Path, ... class TestLoadPluginsWithExistingContext (line 362) | class TestLoadPluginsWithExistingContext: method test_preserves_existing_skills (line 365) | def test_preserves_existing_skills(self, tmp_path: Path, agent_with_co... method test_plugin_skill_overrides_existing (line 381) | def test_plugin_skill_overrides_existing(self, tmp_path: Path, agent_w... method test_preserves_existing_mcp (line 396) | def test_preserves_existing_mcp(self, tmp_path: Path, agent_with_mcp): class TestLoadPluginsMaxSkills (line 411) | class TestLoadPluginsMaxSkills: method test_max_skills_not_exceeded (line 414) | def test_max_skills_not_exceeded(self, tmp_path: Path, basic_agent): method test_max_skills_exceeded_raises_error (line 431) | def test_max_skills_exceeded_raises_error(self, tmp_path: Path, basic_... class TestLoadPluginsErrorHandling (line 448) | class TestLoadPluginsErrorHandling: method test_nonexistent_plugin_raises_error (line 451) | def test_nonexistent_plugin_raises_error(self, basic_agent): method test_invalid_plugin_dir_raises_error (line 457) | def test_invalid_plugin_dir_raises_error(self, tmp_path: Path, basic_a... class TestPluginSource (line 469) | class TestPluginSource: method test_create_basic (line 472) | def test_create_basic(self): method test_create_with_ref (line 479) | def test_create_with_ref(self): method test_create_with_repo_path (line 484) | def test_create_with_repo_path(self): method test_create_local_path (line 492) | def test_create_local_path(self): FILE: tests/sdk/plugin/test_plugin_loading.py class TestPluginManifest (line 14) | class TestPluginManifest: method test_basic_manifest (line 17) | def test_basic_manifest(self): method test_manifest_with_author_object (line 29) | def test_manifest_with_author_object(self): method test_manifest_with_entry_command (line 41) | def test_manifest_with_entry_command(self): method test_manifest_without_entry_command (line 51) | def test_manifest_without_entry_command(self): class TestPluginLoading (line 57) | class TestPluginLoading: method test_load_plugin_with_manifest (line 60) | def test_load_plugin_with_manifest(self, tmp_path: Path): method test_load_plugin_with_claude_plugin_dir (line 85) | def test_load_plugin_with_claude_plugin_dir(self, tmp_path: Path): method test_load_plugin_without_manifest (line 103) | def test_load_plugin_without_manifest(self, tmp_path: Path): method test_load_plugin_with_skills (line 113) | def test_load_plugin_with_skills(self, tmp_path: Path): method test_load_plugin_with_hooks (line 141) | def test_load_plugin_with_hooks(self, tmp_path: Path): method test_load_plugin_with_agents (line 176) | def test_load_plugin_with_agents(self, tmp_path: Path): method test_load_plugin_with_commands (line 213) | def test_load_plugin_with_commands(self, tmp_path: Path): method test_load_plugin_with_entry_command (line 247) | def test_load_plugin_with_entry_command(self, tmp_path: Path): method test_load_plugin_without_entry_command (line 271) | def test_load_plugin_without_entry_command(self, tmp_path: Path): method test_command_to_skill_conversion (line 281) | def test_command_to_skill_conversion(self, tmp_path: Path): method test_get_all_skills_with_commands (line 328) | def test_get_all_skills_with_commands(self, tmp_path: Path): method test_get_all_skills_empty_commands (line 389) | def test_get_all_skills_empty_commands(self, tmp_path: Path): method test_load_all_plugins (line 416) | def test_load_all_plugins(self, tmp_path: Path): method test_load_nonexistent_plugin (line 436) | def test_load_nonexistent_plugin(self, tmp_path: Path): method test_load_plugin_with_invalid_manifest (line 441) | def test_load_plugin_with_invalid_manifest(self, tmp_path: Path): method test_load_all_nonexistent_directory (line 454) | def test_load_all_nonexistent_directory(self, tmp_path: Path): method test_load_all_with_failing_plugin (line 459) | def test_load_all_with_failing_plugin(self, tmp_path: Path): method test_load_plugin_with_author_string (line 484) | def test_load_plugin_with_author_string(self, tmp_path: Path): method test_load_plugin_with_manifest_parse_error (line 508) | def test_load_plugin_with_manifest_parse_error(self, tmp_path: Path): class TestPluginAuthor (line 524) | class TestPluginAuthor: method test_from_string_with_email (line 527) | def test_from_string_with_email(self): method test_from_string_without_email (line 533) | def test_from_string_without_email(self): method test_from_string_with_whitespace (line 539) | def test_from_string_with_whitespace(self): method test_with_url (line 545) | def test_with_url(self): method test_url_defaults_to_none (line 556) | def test_url_defaults_to_none(self): class TestCommandDefinition (line 562) | class TestCommandDefinition: method test_load_command_basic (line 565) | def test_load_command_basic(self, tmp_path: Path): method test_load_command_with_argument_hint_list (line 589) | def test_load_command_with_argument_hint_list(self, tmp_path: Path): method test_load_command_with_camel_case_fields (line 607) | def test_load_command_with_camel_case_fields(self, tmp_path: Path): method test_load_command_with_allowed_tools_as_string (line 626) | def test_load_command_with_allowed_tools_as_string(self, tmp_path: Path): method test_load_command_defaults (line 642) | def test_load_command_defaults(self, tmp_path: Path): method test_load_command_with_metadata (line 659) | def test_load_command_with_metadata(self, tmp_path: Path): class TestPluginMcpConfigLoading (line 676) | class TestPluginMcpConfigLoading: method test_plugin_mcp_config_preserves_unexpanded_variables (line 684) | def test_plugin_mcp_config_preserves_unexpanded_variables(self, tmp_pa... method test_plugin_mcp_config_preserves_variables_with_defaults (line 728) | def test_plugin_mcp_config_preserves_variables_with_defaults(self, tmp... method test_plugin_mcp_skill_root_is_expanded (line 788) | def test_plugin_mcp_skill_root_is_expanded(self, tmp_path: Path): FILE: tests/sdk/plugin/test_plugin_merging.py class TestPluginAddSkillsTo (line 10) | class TestPluginAddSkillsTo: method test_add_skills_to_empty_plugin (line 13) | def test_add_skills_to_empty_plugin(self, empty_plugin): method test_add_skills_to_none_context_empty_plugin (line 19) | def test_add_skills_to_none_context_empty_plugin(self, empty_plugin): method test_add_skills_to_none_input (line 25) | def test_add_skills_to_none_input(self, mock_plugin_with_skills): method test_add_skills_to_with_skills (line 31) | def test_add_skills_to_with_skills(self, mock_plugin_with_skills): method test_add_skills_to_adds_new_skill (line 37) | def test_add_skills_to_adds_new_skill(self, mock_skill, another_mock_s... method test_add_skills_to_overrides_existing_skill (line 50) | def test_add_skills_to_overrides_existing_skill(self): method test_add_skills_to_preserves_insertion_order (line 64) | def test_add_skills_to_preserves_insertion_order(self): method test_add_skills_to_returns_new_context (line 79) | def test_add_skills_to_returns_new_context(self, mock_skill): method test_add_skills_to_enforces_max_skills (line 94) | def test_add_skills_to_enforces_max_skills(self, mock_plugin_with_skil... method test_add_skills_to_max_skills_with_existing (line 100) | def test_add_skills_to_max_skills_with_existing(self, mock_skill): method test_add_skills_to_max_skills_with_override (line 119) | def test_add_skills_to_max_skills_with_override(self): method test_add_skills_to_preserves_context_fields (line 135) | def test_add_skills_to_preserves_context_fields(self, mock_plugin_with... class TestPluginAddMcpConfigTo (line 145) | class TestPluginAddMcpConfigTo: method test_add_mcp_config_to_empty_plugin (line 148) | def test_add_mcp_config_to_empty_plugin(self, empty_plugin): method test_add_mcp_config_to_both_none (line 153) | def test_add_mcp_config_to_both_none(self, empty_plugin): method test_add_mcp_config_to_none_input (line 158) | def test_add_mcp_config_to_none_input(self, mock_plugin_with_mcp): method test_add_mcp_config_to_with_config (line 164) | def test_add_mcp_config_to_with_config(self, mock_plugin_with_mcp): method test_add_mcp_config_to_both_empty (line 169) | def test_add_mcp_config_to_both_empty(self): method test_add_mcp_config_to_merges_configs (line 179) | def test_add_mcp_config_to_merges_configs(self): method test_add_mcp_config_to_plugin_overrides (line 197) | def test_add_mcp_config_to_plugin_overrides(self): method test_add_mcp_config_to_does_not_modify_inputs (line 211) | def test_add_mcp_config_to_does_not_modify_inputs(self): method test_add_mcp_config_to_merges_mcp_servers (line 229) | def test_add_mcp_config_to_merges_mcp_servers(self): method test_add_mcp_config_to_mcp_servers_plugin_overrides (line 246) | def test_add_mcp_config_to_mcp_servers_plugin_overrides(self): function mock_skill (line 266) | def mock_skill(): function another_mock_skill (line 275) | def another_mock_skill(): function empty_plugin (line 284) | def empty_plugin(): function mock_plugin_with_skills (line 295) | def mock_plugin_with_skills(mock_skill, another_mock_skill): function mock_plugin_with_mcp (line 307) | def mock_plugin_with_mcp(): FILE: tests/sdk/plugin/test_source.py class TestParseGitHubURL (line 15) | class TestParseGitHubURL: method test_parse_blob_url (line 16) | def test_parse_blob_url(self): method test_parse_tree_url (line 26) | def test_parse_tree_url(self): method test_returns_none_for_non_github (line 33) | def test_returns_none_for_non_github(self): class TestIsLocalPath (line 38) | class TestIsLocalPath: method test_local_paths (line 39) | def test_local_paths(self): method test_non_local_paths (line 46) | def test_non_local_paths(self): class TestValidateSourcePath (line 51) | class TestValidateSourcePath: method test_valid_paths (line 52) | def test_valid_paths(self): method test_invalid_source_raises (line 58) | def test_invalid_source_raises(self): class TestResolveSourcePath (line 63) | class TestResolveSourcePath: method test_resolve_file_url (line 64) | def test_resolve_file_url(self): method test_resolve_absolute_path (line 67) | def test_resolve_absolute_path(self): method test_resolve_relative_with_base (line 70) | def test_resolve_relative_with_base(self): method test_resolve_home_path (line 74) | def test_resolve_home_path(self): FILE: tests/sdk/security/defense_in_depth/test_adversarial.py class _FixedRiskHelper (line 63) | class _FixedRiskHelper(SecurityAnalyzerBase): method security_risk (line 68) | def security_risk(self, action: ActionEvent) -> SecurityRisk: function make_action (line 77) | def make_action(command: str, tool_name: str = "bash") -> ActionEvent: class TestTDDRedGreen (line 98) | class TestTDDRedGreen: method test_json_recursion_bomb_handled (line 115) | def test_json_recursion_bomb_handled(self): method test_word_joiner_evasion_detected (line 131) | def test_word_joiner_evasion_detected(self): method test_fetch_to_exec_does_not_cross_fields (line 143) | def test_fetch_to_exec_does_not_cross_fields(self): class TestDesignBoundaries (line 177) | class TestDesignBoundaries: method test_cyrillic_homoglyph_evasion (line 208) | def test_cyrillic_homoglyph_evasion(self): method test_combining_character_evasion (line 228) | def test_combining_character_evasion(self): method test_payload_past_hard_cap (line 248) | def test_payload_past_hard_cap(self): method test_payload_in_thinking_blocks (line 269) | def test_payload_in_thinking_blocks(self): method test_fetch_pipe_to_node (line 301) | def test_fetch_pipe_to_node(self): class TestAdversarialGarbage (line 353) | class TestAdversarialGarbage: method test_normalization_stress (line 377) | def test_normalization_stress(self, command, expected, desc): method test_pattern_boundary_garbage (line 387) | def test_pattern_boundary_garbage(self, command, expected, desc): method test_ensemble_unknown_dilution (line 400) | def test_ensemble_unknown_dilution(self, concrete_risk, desc): FILE: tests/sdk/security/defense_in_depth/test_ensemble.py class FixedRiskTestAnalyzer (line 23) | class FixedRiskTestAnalyzer(SecurityAnalyzerBase): method security_risk (line 28) | def security_risk(self, action: ActionEvent) -> SecurityRisk: class FailingTestAnalyzer (line 32) | class FailingTestAnalyzer(SecurityAnalyzerBase): method security_risk (line 35) | def security_risk(self, action: ActionEvent) -> SecurityRisk: function make_action (line 39) | def make_action(command: str) -> ActionEvent: class TestEnsemble (line 59) | class TestEnsemble: method test_max_severity_low_low (line 62) | def test_max_severity_low_low(self): method test_max_severity_low_high (line 71) | def test_max_severity_low_high(self): method test_max_severity_medium_high (line 80) | def test_max_severity_medium_high(self): method test_fail_closed_on_exception (line 89) | def test_fail_closed_on_exception(self): method test_unknown_plus_high (line 97) | def test_unknown_plus_high(self): method test_unknown_plus_low (line 106) | def test_unknown_plus_low(self): method test_all_unknown_propagated (line 115) | def test_all_unknown_propagated(self): method test_single_analyzer (line 124) | def test_single_analyzer(self): method test_empty_analyzers_rejected (line 130) | def test_empty_analyzers_rejected(self): class TestPropagateUnknown (line 135) | class TestPropagateUnknown: method test_default_false_unknown_plus_low (line 138) | def test_default_false_unknown_plus_low(self): method test_propagate_unknown_plus_low (line 148) | def test_propagate_unknown_plus_low(self): method test_propagate_unknown_plus_high (line 159) | def test_propagate_unknown_plus_high(self): method test_all_unknown_both_modes (line 170) | def test_all_unknown_both_modes(self): method test_no_unknown_both_modes_agree (line 182) | def test_no_unknown_both_modes_agree(self): FILE: tests/sdk/security/defense_in_depth/test_field_cap.py function _make_action (line 43) | def _make_action( class TestPrimaryFirstOrdering (line 78) | class TestPrimaryFirstOrdering: method test_arguments_is_first_segment (line 81) | def test_arguments_is_first_segment(self): method test_oversized_non_argument_fields_do_not_starve_arguments (line 107) | def test_oversized_non_argument_fields_do_not_starve_arguments( method test_summary_is_first_text_segment (line 128) | def test_summary_is_first_text_segment(self): method test_oversized_text_fields_do_not_starve_summary (line 160) | def test_oversized_text_fields_do_not_starve_summary( class TestArgumentsFullRangeVisibility (line 185) | class TestArgumentsFullRangeVisibility: method test_payload_visible_at_any_position_up_to_total_cap (line 205) | def test_payload_visible_at_any_position_up_to_total_cap( class TestSizeAccounting (line 225) | class TestSizeAccounting: method test_total_cap_still_honored (line 228) | def test_total_cap_still_honored(self): method test_small_fields_unaffected (line 239) | def test_small_fields_unaffected(self): method test_oversized_arguments_leaves_no_budget_for_other_fields (line 252) | def test_oversized_arguments_leaves_no_budget_for_other_fields(self): class TestEndToEnd (line 271) | class TestEndToEnd: method test_malicious_arguments_detected_despite_oversized_fields (line 285) | def test_malicious_arguments_detected_despite_oversized_fields( class TestComposedPathGuarantee (line 308) | class TestComposedPathGuarantee: method test_summary_visible_in_all_content_when_exec_is_full (line 319) | def test_summary_visible_in_all_content_when_exec_is_full(self): method test_injection_in_summary_detected_when_exec_is_full (line 328) | def test_injection_in_summary_detected_when_exec_is_full(self): method test_exec_still_visible_in_all_content_when_text_is_large (line 337) | def test_exec_still_visible_in_all_content_when_text_is_large(self): method test_composed_content_length_actually_bounded (line 360) | def test_composed_content_length_actually_bounded(self): class TestResidualLimitations (line 392) | class TestResidualLimitations: method test_payload_past_total_cap_in_arguments_invisible (line 403) | def test_payload_past_total_cap_in_arguments_invisible(self): FILE: tests/sdk/security/defense_in_depth/test_pattern.py function make_action (line 31) | def make_action( class TestExtraction (line 56) | class TestExtraction: method test_whitelisted_fields_included (line 59) | def test_whitelisted_fields_included(self): method test_json_arguments_parsed (line 81) | def test_json_arguments_parsed(self): method test_raw_fallback_on_parse_failure (line 91) | def test_raw_fallback_on_parse_failure(self): method test_hard_cap_truncation (line 97) | def test_hard_cap_truncation(self): method test_empty_content (line 112) | def test_empty_content(self): method test_multiple_thoughts (line 117) | def test_multiple_thoughts(self): method test_exec_content_excludes_reasoning (line 131) | def test_exec_content_excludes_reasoning(self): class TestNormalization (line 159) | class TestNormalization: method test_fullwidth_ascii (line 162) | def test_fullwidth_ascii(self): method test_zero_width_stripped (line 165) | def test_zero_width_stripped(self): method test_bidi_controls_stripped (line 168) | def test_bidi_controls_stripped(self): method test_c0_controls_stripped (line 171) | def test_c0_controls_stripped(self): method test_tab_newline_preserved_then_collapsed (line 174) | def test_tab_newline_preserved_then_collapsed(self): method test_del_stripped (line 178) | def test_del_stripped(self): method test_whitespace_collapsed (line 181) | def test_whitespace_collapsed(self): method test_bom_stripped (line 184) | def test_bom_stripped(self): method test_soft_hyphen_stripped (line 189) | def test_soft_hyphen_stripped(self): method test_c1_controls_stripped (line 193) | def test_c1_controls_stripped(self): method test_variation_selector_stripped (line 197) | def test_variation_selector_stripped(self): method test_tag_block_stripped (line 201) | def test_tag_block_stripped(self): method test_format_chars_stripped (line 205) | def test_format_chars_stripped(self): method test_null_byte_stripped_explicitly (line 209) | def test_null_byte_stripped_explicitly(self): method test_idempotent (line 213) | def test_idempotent(self): method test_word_joiner_stripped (line 220) | def test_word_joiner_stripped(self): method test_mongolian_fvs_stripped (line 224) | def test_mongolian_fvs_stripped(self): class TestTwoCorpus (line 234) | class TestTwoCorpus: method test_reasoning_text_does_not_trip_shell_patterns (line 237) | def test_reasoning_text_does_not_trip_shell_patterns(self): method test_reasoning_sudo_rm_does_not_trip (line 253) | def test_reasoning_sudo_rm_does_not_trip(self): method test_reasoning_injection_still_detected (line 270) | def test_reasoning_injection_still_detected(self): function test_pattern_high (line 319) | def test_pattern_high(command: str, desc: str): function test_pattern_medium (line 337) | def test_pattern_medium(command: str, desc: str): function test_pattern_low (line 354) | def test_pattern_low(command: str, desc: str): function test_pattern_boundary_not_high (line 370) | def test_pattern_boundary_not_high(command: str, desc: str): function test_fullwidth_evasion_detected (line 379) | def test_fullwidth_evasion_detected(): function test_bidi_evasion_detected (line 385) | def test_bidi_evasion_detected(): function test_zero_width_evasion_detected (line 391) | def test_zero_width_evasion_detected(): FILE: tests/sdk/security/defense_in_depth/test_policy_rails.py function make_action (line 19) | def make_action(command: str, tool_name: str = "bash") -> ActionEvent: class TestPolicyRails (line 34) | class TestPolicyRails: method test_safe_command_passes (line 37) | def test_safe_command_passes(self): method test_fetch_to_curl_pipe_bash (line 41) | def test_fetch_to_curl_pipe_bash(self): method test_fetch_alone_passes (line 46) | def test_fetch_alone_passes(self): method test_raw_disk_dd (line 50) | def test_raw_disk_dd(self): method test_raw_disk_dd_reversed_operands (line 55) | def test_raw_disk_dd_reversed_operands(self): method test_raw_disk_dd_with_extra_operands (line 60) | def test_raw_disk_dd_with_extra_operands(self): method test_raw_disk_mkfs (line 65) | def test_raw_disk_mkfs(self): method test_catastrophic_delete_root (line 70) | def test_catastrophic_delete_root(self): method test_catastrophic_delete_home (line 75) | def test_catastrophic_delete_home(self): class TestPolicyRailAnalyzer (line 81) | class TestPolicyRailAnalyzer: method test_fetch_to_curl_returns_high (line 84) | def test_fetch_to_curl_returns_high(self): method test_safe_command_returns_low (line 89) | def test_safe_command_returns_low(self): method test_reasoning_does_not_trip_rails (line 94) | def test_reasoning_does_not_trip_rails(self): FILE: tests/sdk/security/defense_in_depth/test_serialization.py function make_action (line 54) | def make_action(command: str) -> ActionEvent: class TestPatternSerializationRoundTrip (line 74) | class TestPatternSerializationRoundTrip: method test_direct_roundtrip (line 75) | def test_direct_roundtrip(self): method test_polymorphic_roundtrip (line 81) | def test_polymorphic_roundtrip(self): method test_roundtrip_then_detect (line 87) | def test_roundtrip_then_detect(self): class TestPolicyRailSerializationRoundTrip (line 101) | class TestPolicyRailSerializationRoundTrip: method test_direct_roundtrip (line 102) | def test_direct_roundtrip(self): method test_polymorphic_roundtrip (line 108) | def test_polymorphic_roundtrip(self): method test_roundtrip_then_detect (line 114) | def test_roundtrip_then_detect(self): class TestEnsembleSerializationRoundTrip (line 127) | class TestEnsembleSerializationRoundTrip: method test_direct_roundtrip (line 128) | def test_direct_roundtrip(self): method test_polymorphic_roundtrip (line 135) | def test_polymorphic_roundtrip(self): method test_nested_polymorphic_children (line 143) | def test_nested_polymorphic_children(self): method test_roundtrip_then_detect (line 155) | def test_roundtrip_then_detect(self): method test_propagate_unknown_survives_roundtrip (line 167) | def test_propagate_unknown_survives_roundtrip(self): class TestContainerField (line 183) | class TestContainerField: method test_container_with_pattern (line 184) | def test_container_with_pattern(self): method test_container_with_ensemble (line 193) | def test_container_with_ensemble(self): class TestConfigDefaults (line 212) | class TestConfigDefaults: method test_pattern_defaults_non_empty (line 213) | def test_pattern_defaults_non_empty(self): method test_ensemble_empty_analyzers_rejected (line 220) | def test_ensemble_empty_analyzers_rejected(self): class TestKindDiscriminators (line 230) | class TestKindDiscriminators: method test_pattern_kind (line 231) | def test_pattern_kind(self): method test_policy_rail_kind (line 234) | def test_policy_rail_kind(self): method test_ensemble_kind (line 237) | def test_ensemble_kind(self): class TestPublicAPISurface (line 247) | class TestPublicAPISurface: method test_all_analyzers_importable_from_security (line 248) | def test_all_analyzers_importable_from_security(self): class TestStableIDs (line 265) | class TestStableIDs: method test_rail_ids (line 268) | def test_rail_ids(self): method test_rail_id_values (line 277) | def test_rail_id_values(self): method test_pattern_detector_id_constants (line 282) | def test_pattern_detector_id_constants(self): method test_pattern_tuples_reference_constants (line 299) | def test_pattern_tuples_reference_constants(self): FILE: tests/sdk/security/grayswan/test_grayswan_analyzer.py class GraySwanTestAction (line 17) | class GraySwanTestAction(Action): function create_mock_action_event (line 23) | def create_mock_action_event( function create_mock_message_event (line 45) | def create_mock_message_event( function create_mock_system_prompt_event (line 59) | def create_mock_system_prompt_event( class TestGraySwanAnalyzerInit (line 69) | class TestGraySwanAnalyzerInit: method test_init_without_api_key_logs_warning (line 72) | def test_init_without_api_key_logs_warning(self, caplog: pytest.LogCap... method test_init_with_api_key_from_env (line 79) | def test_init_with_api_key_from_env(self): method test_init_with_api_key_param (line 86) | def test_init_with_api_key_param(self): method test_init_with_default_policy_id (line 92) | def test_init_with_default_policy_id(self, caplog: pytest.LogCaptureFi... method test_init_with_policy_id_from_env (line 99) | def test_init_with_policy_id_from_env(self, caplog: pytest.LogCaptureF... method test_init_with_custom_thresholds (line 109) | def test_init_with_custom_thresholds(self): method test_init_with_invalid_threshold_order_raises_error (line 119) | def test_init_with_invalid_threshold_order_raises_error(self): method test_init_with_equal_thresholds_raises_error (line 130) | def test_init_with_equal_thresholds_raises_error(self): class TestGraySwanAnalyzerViolationMapping (line 142) | class TestGraySwanAnalyzerViolationMapping: method analyzer (line 146) | def analyzer(self) -> GraySwanAnalyzer: method test_map_low_violation (line 150) | def test_map_low_violation(self, analyzer: GraySwanAnalyzer): method test_map_medium_violation (line 156) | def test_map_medium_violation(self, analyzer: GraySwanAnalyzer): method test_map_high_violation (line 162) | def test_map_high_violation(self, analyzer: GraySwanAnalyzer): method test_map_boundary_low_threshold (line 168) | def test_map_boundary_low_threshold(self, analyzer: GraySwanAnalyzer): method test_map_boundary_medium_threshold (line 173) | def test_map_boundary_medium_threshold(self, analyzer: GraySwanAnalyzer): class TestGraySwanAnalyzerAPICall (line 179) | class TestGraySwanAnalyzerAPICall: method analyzer (line 183) | def analyzer(self) -> GraySwanAnalyzer: method test_api_call_success_low_risk (line 187) | def test_api_call_success_low_risk(self, analyzer: GraySwanAnalyzer): method test_api_call_success_high_risk (line 203) | def test_api_call_success_high_risk(self, analyzer: GraySwanAnalyzer): method test_api_call_ipi_detection_escalates_to_high (line 218) | def test_api_call_ipi_detection_escalates_to_high(self, analyzer: Gray... method test_api_call_error_returns_unknown (line 233) | def test_api_call_error_returns_unknown(self, analyzer: GraySwanAnalyz... method test_api_call_timeout_returns_unknown (line 248) | def test_api_call_timeout_returns_unknown(self, analyzer: GraySwanAnal... method test_api_call_without_api_key_returns_unknown (line 259) | def test_api_call_without_api_key_returns_unknown(self): method test_api_call_missing_violation_field_returns_unknown (line 265) | def test_api_call_missing_violation_field_returns_unknown( class TestGraySwanAnalyzerSecurityRisk (line 283) | class TestGraySwanAnalyzerSecurityRisk: method analyzer (line 287) | def analyzer(self) -> GraySwanAnalyzer: method test_security_risk_without_api_key (line 291) | def test_security_risk_without_api_key(self): method test_security_risk_with_events (line 298) | def test_security_risk_with_events(self, analyzer: GraySwanAnalyzer): method test_security_risk_respects_history_limit (line 328) | def test_security_risk_respects_history_limit(self, analyzer: GraySwan... class TestGraySwanAnalyzerSetEvents (line 357) | class TestGraySwanAnalyzerSetEvents: method test_set_events (line 360) | def test_set_events(self): class TestGraySwanAnalyzerClose (line 371) | class TestGraySwanAnalyzerClose: method test_close_cleans_up_client (line 374) | def test_close_cleans_up_client(self): method test_close_handles_no_client (line 388) | def test_close_handles_no_client(self): class TestGraySwanAnalyzerHTTPClientLifecycle (line 395) | class TestGraySwanAnalyzerHTTPClientLifecycle: method test_client_creation_and_reuse (line 398) | def test_client_creation_and_reuse(self): method test_client_recreated_after_close (line 423) | def test_client_recreated_after_close(self): method test_client_handles_json_decode_error (line 462) | def test_client_handles_json_decode_error(self): FILE: tests/sdk/security/grayswan/test_grayswan_utils.py class GraySwanUtilsTestAction (line 18) | class GraySwanUtilsTestAction(Action): class GraySwanUtilsTestObservation (line 24) | class GraySwanUtilsTestObservation(Observation): method to_llm_content (line 30) | def to_llm_content(self) -> list[TextContent]: function create_system_prompt_event (line 34) | def create_system_prompt_event(prompt: str = "You are a helpful assistan... function create_message_event (line 42) | def create_message_event(content: str, source: str = "user"): function create_action_event (line 53) | def create_action_event( function create_observation_event (line 75) | def create_observation_event( function create_agent_error_event (line 90) | def create_agent_error_event( function create_user_reject_observation (line 103) | def create_user_reject_observation( class TestConvertEventsToOpenAIMessages (line 118) | class TestConvertEventsToOpenAIMessages: method test_empty_events (line 121) | def test_empty_events(self): method test_system_prompt_event (line 126) | def test_system_prompt_event(self): method test_user_message_event (line 135) | def test_user_message_event(self): method test_agent_message_event (line 144) | def test_agent_message_event(self): method test_action_event (line 153) | def test_action_event(self): method test_action_event_removes_security_risk_from_arguments (line 173) | def test_action_event_removes_security_risk_from_arguments(self): method test_observation_event (line 195) | def test_observation_event(self): method test_agent_error_event (line 211) | def test_agent_error_event(self): method test_user_reject_observation (line 227) | def test_user_reject_observation(self): method test_full_conversation (line 243) | def test_full_conversation(self): method test_multiple_tool_calls_in_sequence (line 271) | def test_multiple_tool_calls_in_sequence(self): FILE: tests/sdk/security/test_confirmation_policy.py class TestConfirmationPolicyBase (line 14) | class TestConfirmationPolicyBase: method test_cannot_instantiate_base_class (line 17) | def test_cannot_instantiate_base_class(self) -> None: method test_confirmation_policy_container_serialization (line 25) | def test_confirmation_policy_container_serialization( class TestAlwaysConfirm (line 44) | class TestAlwaysConfirm: method test_always_confirm (line 48) | def test_always_confirm(self, risk: SecurityRisk) -> None: method test_roundtrip_serialization (line 53) | def test_roundtrip_serialization(self) -> None: method test_polymorphic_serialization (line 61) | def test_polymorphic_serialization(self) -> None: class TestNeverConfirm (line 72) | class TestNeverConfirm: method test_never_confirm (line 76) | def test_never_confirm(self, risk: SecurityRisk) -> None: method test_roundtrip_serialization (line 81) | def test_roundtrip_serialization(self) -> None: method test_polymorphic_serialization (line 89) | def test_polymorphic_serialization(self) -> None: FILE: tests/sdk/security/test_llm_security_analyzer.py class LlmSecurityAnalyzerMockAction (line 12) | class LlmSecurityAnalyzerMockAction(Action): function create_mock_action_event (line 18) | def create_mock_action_event( function test_llm_security_analyzer_returns_stored_risk (line 47) | def test_llm_security_analyzer_returns_stored_risk(risk_level: SecurityR... FILE: tests/sdk/security/test_security_analyzer.py class SecurityAnalyzerMockAction (line 12) | class SecurityAnalyzerMockAction(Action): class SecurityAnalyzer (line 18) | class SecurityAnalyzer(SecurityAnalyzerBase): method security_risk (line 28) | def security_risk(self, action: ActionEvent) -> SecurityRisk: method handle_api_request (line 33) | def handle_api_request(self, request_data: dict) -> dict: method close (line 38) | def close(self) -> None: function create_mock_action_event (line 43) | def create_mock_action_event(action: Action) -> ActionEvent: function test_analyze_event_with_action_event (line 60) | def test_analyze_event_with_action_event(): function test_analyze_event_with_non_action_event (line 73) | def test_analyze_event_with_non_action_event(): function test_analyze_pending_actions_success (line 83) | def test_analyze_pending_actions_success(): function test_analyze_pending_actions_empty_list (line 102) | def test_analyze_pending_actions_empty_list(): function test_analyze_pending_actions_with_exception (line 112) | def test_analyze_pending_actions_with_exception(): function test_analyze_pending_actions_mixed_risks (line 131) | def test_analyze_pending_actions_mixed_risks() -> None: function test_analyze_pending_actions_partial_failure (line 162) | def test_analyze_pending_actions_partial_failure(): FILE: tests/sdk/security/test_security_risk.py function test_security_risk_enum_values (line 10) | def test_security_risk_enum_values(): function test_security_risk_string_representation (line 18) | def test_security_risk_string_representation(): function test_riskiness_ordering (line 26) | def test_riskiness_ordering(): function test_riskiness_ordering_is_reflexive (line 47) | def test_riskiness_ordering_is_reflexive(risk_level): function test_riskiness_ordering_non_reflexive (line 60) | def test_riskiness_ordering_non_reflexive(risk_level): function test_riskiness_ordering_undefined_for_unknown (line 65) | def test_riskiness_ordering_undefined_for_unknown(): function test_security_risk_get_color (line 79) | def test_security_risk_get_color(): function test_lt_ordering (line 87) | def test_lt_ordering(): function test_lt_not_less_than_self (line 94) | def test_lt_not_less_than_self(): function test_lt_reverse_ordering (line 101) | def test_lt_reverse_ordering(): function test_lt_unknown_raises (line 108) | def test_lt_unknown_raises(): function test_max_on_concrete_risks (line 118) | def test_max_on_concrete_risks(): FILE: tests/sdk/settings/test_acp_providers.py class TestACPProviderInfo (line 18) | class TestACPProviderInfo: method test_known_providers_are_registered (line 19) | def test_known_providers_are_registered(self): method test_all_entries_are_acp_provider_info (line 22) | def test_all_entries_are_acp_provider_info(self): method test_claude_code_metadata (line 26) | def test_claude_code_metadata(self): method test_codex_metadata (line 39) | def test_codex_metadata(self): method test_gemini_cli_metadata (line 51) | def test_gemini_cli_metadata(self): method test_provider_info_is_frozen (line 63) | def test_provider_info_is_frozen(self): method test_default_command_is_tuple (line 68) | def test_default_command_is_tuple(self): method test_acp_providers_is_read_only (line 74) | def test_acp_providers_is_read_only(self): class TestGetACPProvider (line 80) | class TestGetACPProvider: method test_returns_info_for_known_keys (line 81) | def test_returns_info_for_known_keys(self): method test_returns_none_for_custom (line 87) | def test_returns_none_for_custom(self): method test_returns_none_for_unknown (line 90) | def test_returns_none_for_unknown(self): class TestDetectACPProviderByAgentName (line 94) | class TestDetectACPProviderByAgentName: method test_detects_claude_code_by_agent_name (line 95) | def test_detects_claude_code_by_agent_name(self): method test_detects_codex_by_agent_name (line 100) | def test_detects_codex_by_agent_name(self): method test_detects_gemini_cli_by_agent_name (line 105) | def test_detects_gemini_cli_by_agent_name(self): method test_case_insensitive_detection (line 110) | def test_case_insensitive_detection(self): method test_returns_none_for_unknown_agent_name (line 114) | def test_returns_none_for_unknown_agent_name(self): method test_returns_none_for_empty_string (line 117) | def test_returns_none_for_empty_string(self): class TestProviderRegistryConsistency (line 121) | class TestProviderRegistryConsistency: method test_every_provider_has_non_empty_default_command (line 124) | def test_every_provider_has_non_empty_default_command(self): method test_every_provider_has_agent_name_patterns (line 128) | def test_every_provider_has_agent_name_patterns(self): method test_every_provider_has_non_empty_session_mode (line 134) | def test_every_provider_has_non_empty_session_mode(self): method test_session_modes_are_distinct (line 140) | def test_session_modes_are_distinct(self): method test_detect_returns_matching_provider_for_all_registered_patterns (line 144) | def test_detect_returns_matching_provider_for_all_registered_patterns(... class TestBuildSessionModelMeta (line 157) | class TestBuildSessionModelMeta: method test_empty_when_no_model (line 158) | def test_empty_when_no_model(self): method test_claude_uses_meta_key (line 162) | def test_claude_uses_meta_key(self): method test_codex_returns_empty (line 166) | def test_codex_returns_empty(self): method test_gemini_returns_empty (line 170) | def test_gemini_returns_empty(self): method test_unknown_agent_returns_empty (line 174) | def test_unknown_agent_returns_empty(self): FILE: tests/sdk/skills/test_agentskills_fields.py function test_skill_with_agentskills_fields (line 9) | def test_skill_with_agentskills_fields(tmp_path) -> None: function test_skill_allowed_tools_formats (line 40) | def test_skill_allowed_tools_formats(tmp_path) -> None: function test_skill_invalid_field_types (line 61) | def test_skill_invalid_field_types(tmp_path) -> None: function test_skill_backward_compatibility (line 82) | def test_skill_backward_compatibility(tmp_path) -> None: FILE: tests/sdk/skills/test_extensions_ref.py function _run_in_subprocess (line 11) | def _run_in_subprocess(test_code: str, env_extra: dict | None = None) ->... function test_extensions_ref_default (line 31) | def test_extensions_ref_default(): function test_extensions_ref_custom_branch (line 45) | def test_extensions_ref_custom_branch(): function test_extensions_ref_with_load_public_skills (line 56) | def test_extensions_ref_with_load_public_skills(): function test_extensions_ref_empty_string (line 82) | def test_extensions_ref_empty_string(): FILE: tests/sdk/skills/test_installed_skills.py function _create_skill_dir (line 30) | def _create_skill_dir( function installed_dir (line 44) | def installed_dir(tmp_path: Path) -> Path: function sample_skill_dir (line 51) | def sample_skill_dir(tmp_path: Path) -> Path: function test_get_installed_skills_dir_returns_default_path (line 60) | def test_get_installed_skills_dir_returns_default_path() -> None: function test_install_from_local_path (line 67) | def test_install_from_local_path(sample_skill_dir: Path, installed_dir: ... function test_install_already_exists_raises_error (line 76) | def test_install_already_exists_raises_error( function test_install_with_force_overwrites (line 84) | def test_install_with_force_overwrites( function test_uninstall_existing_skill (line 99) | def test_uninstall_existing_skill(sample_skill_dir: Path, installed_dir:... function test_list_installed_skills (line 105) | def test_list_installed_skills(sample_skill_dir: Path, installed_dir: Pa... function test_load_installed_skills (line 112) | def test_load_installed_skills(sample_skill_dir: Path, installed_dir: Pa... function test_disable_skill_filters_load (line 120) | def test_disable_skill_filters_load( function test_enable_skill_restores_load (line 132) | def test_enable_skill_restores_load( function test_get_installed_skill (line 144) | def test_get_installed_skill(sample_skill_dir: Path, installed_dir: Path... function test_get_nonexistent_skill (line 151) | def test_get_nonexistent_skill(installed_dir: Path) -> None: function test_update_skill_reinstalls_from_source (line 155) | def test_update_skill_reinstalls_from_source( function test_update_nonexistent_skill (line 174) | def test_update_nonexistent_skill(installed_dir: Path) -> None: function _create_marketplace (line 183) | def _create_marketplace( class TestInstallSkillsFromMarketplace (line 202) | class TestInstallSkillsFromMarketplace: method test_install_local_skills (line 203) | def test_install_local_skills(self, tmp_path: Path) -> None: method test_install_skills_force_overwrite (line 222) | def test_install_skills_force_overwrite(self, tmp_path: Path) -> None: method test_install_handles_missing_skill_source (line 254) | def test_install_handles_missing_skill_source(self, tmp_path: Path) ->... method test_install_skills_from_plugin_directories (line 267) | def test_install_skills_from_plugin_directories(self, tmp_path: Path) ... method test_install_both_standalone_and_plugin_skills (line 291) | def test_install_both_standalone_and_plugin_skills(self, tmp_path: Pat... FILE: tests/sdk/skills/test_load_project_skills.py function test_load_project_skills_no_directories (line 9) | def test_load_project_skills_no_directories(tmp_path): function test_load_project_skills_agents_md_without_skills_directory (line 15) | def test_load_project_skills_agents_md_without_skills_directory(tmp_path): function test_load_project_skills_agents_md_case_insensitive (line 32) | def test_load_project_skills_agents_md_case_insensitive(tmp_path): function test_load_project_skills_multiple_third_party_files (line 43) | def test_load_project_skills_multiple_third_party_files(tmp_path): function test_load_project_skills_third_party_with_skills_directory (line 58) | def test_load_project_skills_third_party_with_skills_directory(tmp_path): function test_load_project_skills_with_skills_directory (line 77) | def test_load_project_skills_with_skills_directory(tmp_path): function test_load_project_skills_with_agents_directory (line 96) | def test_load_project_skills_with_agents_directory(tmp_path): function test_load_project_skills_agents_directory_precedence (line 115) | def test_load_project_skills_agents_directory_precedence(tmp_path): function test_load_project_skills_merges_agents_and_openhands (line 140) | def test_load_project_skills_merges_agents_and_openhands(tmp_path): function test_load_project_skills_with_microagents_directory (line 160) | def test_load_project_skills_with_microagents_directory(tmp_path): function test_load_project_skills_priority_order (line 183) | def test_load_project_skills_priority_order(tmp_path): function test_load_project_skills_both_directories (line 207) | def test_load_project_skills_both_directories(tmp_path): function test_load_project_skills_handles_errors_gracefully (line 227) | def test_load_project_skills_handles_errors_gracefully(tmp_path): function test_load_project_skills_one_bad_skill_does_not_break_others (line 247) | def test_load_project_skills_one_bad_skill_does_not_break_others(tmp_path): function test_long_description_skill_does_not_break_other_skills (line 291) | def test_long_description_skill_does_not_break_other_skills(tmp_path): function test_load_project_skills_with_string_path (line 328) | def test_load_project_skills_with_string_path(tmp_path): function test_load_project_skills_loads_from_git_root_when_called_from_subdir (line 344) | def test_load_project_skills_loads_from_git_root_when_called_from_subdir... function test_load_project_skills_workdir_takes_precedence_over_git_root (line 356) | def test_load_project_skills_workdir_takes_precedence_over_git_root(tmp_... function test_load_project_skills_loads_skills_directories_from_git_root (line 371) | def test_load_project_skills_loads_skills_directories_from_git_root(tmp_... FILE: tests/sdk/skills/test_load_public_skills.py function _clear_public_skills_cache (line 23) | def _clear_public_skills_cache(): function mock_repo_dir (line 35) | def mock_repo_dir(tmp_path): function mock_repo_with_agentskills_references (line 80) | def mock_repo_with_agentskills_references(tmp_path): function test_load_public_skills_success (line 158) | def test_load_public_skills_success(mock_repo_dir, tmp_path): function test_load_public_skills_repo_update_fails (line 189) | def test_load_public_skills_repo_update_fails(tmp_path): function test_load_public_skills_no_skills_directory (line 209) | def test_load_public_skills_no_skills_directory(tmp_path): function test_load_public_skills_with_invalid_skill (line 232) | def test_load_public_skills_with_invalid_skill(tmp_path): function test_update_skills_repository_clone_new (line 268) | def test_update_skills_repository_clone_new(tmp_path): function test_update_skills_repository_update_existing (line 295) | def test_update_skills_repository_update_existing(tmp_path): function test_update_skills_repository_clone_timeout (line 331) | def test_update_skills_repository_clone_timeout(tmp_path): function test_update_skills_repository_update_fails_uses_cache (line 350) | def test_update_skills_repository_update_fails_uses_cache(tmp_path): function test_agent_context_loads_public_skills (line 381) | def test_agent_context_loads_public_skills(mock_repo_dir, tmp_path): function test_agent_context_uses_custom_marketplace_path (line 404) | def test_agent_context_uses_custom_marketplace_path( function test_agent_context_can_disable_public_skills_loading (line 431) | def test_agent_context_can_disable_public_skills_loading(): function test_agent_context_merges_explicit_and_public_skills (line 437) | def test_agent_context_merges_explicit_and_public_skills(mock_repo_dir, ... function test_agent_context_explicit_skill_takes_precedence (line 467) | def test_agent_context_explicit_skill_takes_precedence(mock_repo_dir, tm... function test_load_public_skills_custom_repo (line 498) | def test_load_public_skills_custom_repo(mock_repo_dir, tmp_path): function test_load_public_skills_custom_branch (line 521) | def test_load_public_skills_custom_branch(mock_repo_dir, tmp_path): function test_load_public_skills_excludes_reference_markdown_in_agentskills_folders (line 542) | def test_load_public_skills_excludes_reference_markdown_in_agentskills_f... function mock_repo_with_marketplace (line 617) | def mock_repo_with_marketplace(tmp_path): function test_load_marketplace_skill_names_returns_skill_names (line 692) | def test_load_marketplace_skill_names_returns_skill_names(mock_repo_with... function test_load_marketplace_skill_names_returns_none_when_file_missing (line 702) | def test_load_marketplace_skill_names_returns_none_when_file_missing(tmp... function test_load_marketplace_skill_names_returns_none_for_invalid_json (line 711) | def test_load_marketplace_skill_names_returns_none_for_invalid_json(tmp_... function test_load_marketplace_skill_names_returns_none_for_missing_plugins (line 723) | def test_load_marketplace_skill_names_returns_none_for_missing_plugins(t... function test_load_public_skills_filters_by_marketplace (line 735) | def test_load_public_skills_filters_by_marketplace( function test_load_public_skills_uses_custom_marketplace_path (line 761) | def test_load_public_skills_uses_custom_marketplace_path( function test_load_public_skills_returns_empty_for_invalid_custom_marketplace_path (line 784) | def test_load_public_skills_returns_empty_for_invalid_custom_marketplace... function test_load_public_skills_loads_all_when_no_marketplace (line 807) | def test_load_public_skills_loads_all_when_no_marketplace(tmp_path): function test_load_public_skills_handles_legacy_md_files_with_marketplace (line 845) | def test_load_public_skills_handles_legacy_md_files_with_marketplace(tmp... function test_load_public_skills_caches_result_within_ttl (line 899) | def test_load_public_skills_caches_result_within_ttl(mock_repo_dir, tmp_... function test_invalidate_public_skills_cache_forces_recompute (line 924) | def test_invalidate_public_skills_cache_forces_recompute(mock_repo_dir, ... function test_load_public_skills_does_not_cache_empty_results (line 944) | def test_load_public_skills_does_not_cache_empty_results(mock_repo_dir, ... FILE: tests/sdk/skills/test_load_user_skills.py function temp_user_skills_dir (line 20) | def temp_user_skills_dir(): function temp_microagents_dir (line 37) | def temp_microagents_dir(): function test_load_user_skills_no_directories (line 49) | def test_load_user_skills_no_directories(tmp_path): function test_load_user_skills_with_agents_directory (line 66) | def test_load_user_skills_with_agents_directory(temp_user_skills_dir): function test_load_user_skills_with_skills_directory (line 90) | def test_load_user_skills_with_skills_directory(temp_user_skills_dir): function test_load_user_skills_with_microagents_directory (line 114) | def test_load_user_skills_with_microagents_directory(temp_microagents_dir): function test_load_user_skills_priority_order (line 142) | def test_load_user_skills_priority_order(tmp_path): function test_load_user_skills_merges_all_directories (line 174) | def test_load_user_skills_merges_all_directories(tmp_path): function test_load_user_skills_handles_errors_gracefully (line 206) | def test_load_user_skills_handles_errors_gracefully(temp_user_skills_dir): function test_agent_context_loads_user_skills_by_default (line 231) | def test_agent_context_loads_user_skills_by_default(temp_user_skills_dir): function test_agent_context_can_disable_user_skills_loading (line 251) | def test_agent_context_can_disable_user_skills_loading(): function test_agent_context_merges_explicit_and_user_skills (line 257) | def test_agent_context_merges_explicit_and_user_skills(temp_user_skills_... function test_agent_context_explicit_skill_takes_precedence (line 286) | def test_agent_context_explicit_skill_takes_precedence(temp_user_skills_... function test_load_user_skills_includes_installed_skills (line 314) | def test_load_user_skills_includes_installed_skills(tmp_path, monkeypatch): function test_load_user_skills_user_skill_takes_precedence_over_installed (line 341) | def test_load_user_skills_user_skill_takes_precedence_over_installed( function test_load_user_skills_disabled_installed_skill_excluded (line 373) | def test_load_user_skills_disabled_installed_skill_excluded(tmp_path, mo... FILE: tests/sdk/skills/test_mcp_config_expansion.py class TestExpandMcpVariables (line 11) | class TestExpandMcpVariables: method test_expand_with_pydantic_mcp_server_objects (line 14) | def test_expand_with_pydantic_mcp_server_objects(self): method test_expand_basic_variables (line 56) | def test_expand_basic_variables(self): method test_expand_windows_path_variables_preserves_backslashes (line 74) | def test_expand_windows_path_variables_preserves_backslashes(self): method test_expand_variables_in_dictionary_keys (line 91) | def test_expand_variables_in_dictionary_keys(self): method test_expand_environment_variables (line 113) | def test_expand_environment_variables(self): method test_expand_secrets (line 132) | def test_expand_secrets(self): method test_variable_resolution_order (line 150) | def test_variable_resolution_order(self): method test_secrets_take_precedence_over_env (line 177) | def test_secrets_take_precedence_over_env(self): method test_default_values (line 199) | def test_default_values(self): method test_default_not_used_when_secret_exists (line 217) | def test_default_not_used_when_secret_exists(self): method test_unexpanded_variables_remain_unchanged (line 234) | def test_unexpanded_variables_remain_unchanged(self): method test_multiple_variables_in_same_string (line 251) | def test_multiple_variables_in_same_string(self): method test_no_get_secret_callback (line 269) | def test_no_get_secret_callback(self): class TestLoadMcpConfigWithSecrets (line 284) | class TestLoadMcpConfigWithSecrets: method test_load_mcp_config_with_secrets (line 287) | def test_load_mcp_config_with_secrets(self, tmp_path): method test_load_mcp_config_without_secrets (line 308) | def test_load_mcp_config_without_secrets(self, tmp_path): method test_load_mcp_config_skill_root_takes_precedence (line 325) | def test_load_mcp_config_skill_root_takes_precedence(self, tmp_path): method test_load_mcp_config_combined_variables_and_secrets (line 344) | def test_load_mcp_config_combined_variables_and_secrets(self, tmp_path): FILE: tests/sdk/skills/test_mcp_json.py function test_agentskills_loads_mcp_json (line 23) | def test_agentskills_loads_mcp_json(tmp_path: Path) -> None: function test_agentskills_ignores_frontmatter_mcp_tools (line 47) | def test_agentskills_ignores_frontmatter_mcp_tools(tmp_path: Path) -> None: function test_legacy_skill_loads_frontmatter_mcp_tools (line 60) | def test_legacy_skill_loads_frontmatter_mcp_tools(tmp_path: Path) -> None: function test_legacy_skill_ignores_mcp_json_in_directory (line 74) | def test_legacy_skill_ignores_mcp_json_in_directory(tmp_path: Path) -> N... function test_mcp_json_invalid_json_raises_error (line 87) | def test_mcp_json_invalid_json_raises_error(tmp_path: Path) -> None: function test_load_skills_from_dir_mcp_json_only_for_agentskills (line 98) | def test_load_skills_from_dir_mcp_json_only_for_agentskills(tmp_path: Pa... FILE: tests/sdk/skills/test_resource_directories.py function test_skill_resources_model (line 14) | def test_skill_resources_model(tmp_path: Path) -> None: function test_discover_skill_resources (line 33) | def test_discover_skill_resources(tmp_path: Path) -> None: function test_resource_directories_constant (line 58) | def test_resource_directories_constant() -> None: function test_skill_load_with_resources (line 63) | def test_skill_load_with_resources(tmp_path: Path) -> None: FILE: tests/sdk/skills/test_skill_commands.py function test_execute_inline_command (line 58) | def test_execute_inline_command(command, timeout, check_fn): function test_execute_inline_command_respects_working_dir (line 62) | def test_execute_inline_command_respects_working_dir(tmp_path: Path): function test_execute_inline_command_truncates_large_output (line 70) | def test_execute_inline_command_truncates_large_output(): function test_render_basic (line 95) | def test_render_basic(content, expected): function test_render_preserves_inline_code (line 104) | def test_render_preserves_inline_code(): function test_render_preserves_fenced_block (line 110) | def test_render_preserves_fenced_block(): function test_render_inline_code_next_to_command (line 118) | def test_render_inline_code_next_to_command(): function test_render_unclosed_fenced_blocks (line 152) | def test_render_unclosed_fenced_blocks(content, executed, preserved): function test_render_properly_closed_fences (line 159) | def test_render_properly_closed_fences(): function test_render_escaped_commands (line 191) | def test_render_escaped_commands(content, expected_literal, expected_exe... function test_render_escape_inside_fenced_block_untouched (line 198) | def test_render_escape_inside_fenced_block_untouched(): function test_skill_render_content (line 217) | def test_skill_render_content(content, expected): function test_skill_load_and_render (line 221) | def test_skill_load_and_render(tmp_path: Path): FILE: tests/sdk/skills/test_skill_info.py class TestSkillGetSkillType (line 16) | class TestSkillGetSkillType: method test_repo_skill_type (line 19) | def test_repo_skill_type(self): method test_knowledge_skill_type_with_keyword_trigger (line 28) | def test_knowledge_skill_type_with_keyword_trigger(self): method test_knowledge_skill_type_with_task_trigger (line 37) | def test_knowledge_skill_type_with_task_trigger(self): method test_agent_skill_type (line 46) | def test_agent_skill_type(self): method test_agent_skill_type_with_trigger (line 56) | def test_agent_skill_type_with_trigger(self): class TestSkillGetTriggers (line 68) | class TestSkillGetTriggers: method test_no_triggers (line 71) | def test_no_triggers(self): method test_keyword_triggers (line 80) | def test_keyword_triggers(self): method test_task_triggers (line 89) | def test_task_triggers(self): method test_empty_keyword_triggers (line 98) | def test_empty_keyword_triggers(self): class TestSkillToSkillInfo (line 108) | class TestSkillToSkillInfo: method test_repo_skill_to_info (line 111) | def test_repo_skill_to_info(self): method test_knowledge_skill_to_info (line 131) | def test_knowledge_skill_to_info(self): method test_agent_skill_to_info (line 150) | def test_agent_skill_to_info(self): method test_agent_skill_to_info_preserves_disable_model_invocation (line 172) | def test_agent_skill_to_info_preserves_disable_model_invocation(self): method test_task_skill_to_info (line 187) | def test_task_skill_to_info(self): method test_skill_info_with_none_values (line 205) | def test_skill_info_with_none_values(self): class TestSkillInfoDataclass (line 223) | class TestSkillInfoDataclass: method test_skill_info_creation (line 226) | def test_skill_info_creation(self): method test_skill_info_with_all_types (line 240) | def test_skill_info_with_all_types(self): method test_skill_info_equality (line 254) | def test_skill_info_equality(self): method test_skill_info_inequality (line 276) | def test_skill_info_inequality(self): FILE: tests/sdk/skills/test_skill_md_convention.py function test_find_skill_md (line 18) | def test_find_skill_md(tmp_path: Path) -> None: function test_validate_skill_name_valid (line 32) | def test_validate_skill_name_valid() -> None: function test_validate_skill_name_invalid_format (line 41) | def test_validate_skill_name_invalid_format() -> None: function test_validate_skill_name_length (line 60) | def test_validate_skill_name_length() -> None: function test_validate_skill_name_directory_mismatch (line 71) | def test_validate_skill_name_directory_mismatch() -> None: function test_skill_load_with_skill_md (line 77) | def test_skill_load_with_skill_md(tmp_path: Path) -> None: function test_skill_load_auto_validates_skill_md (line 90) | def test_skill_load_auto_validates_skill_md(tmp_path: Path) -> None: function test_load_skills_from_dir_with_skill_md (line 103) | def test_load_skills_from_dir_with_skill_md(tmp_path: Path) -> None: function test_skill_md_always_agent_skill (line 122) | def test_skill_md_always_agent_skill(tmp_path: Path) -> None: FILE: tests/sdk/skills/test_skill_no_header.py function test_load_markdown_without_frontmatter (line 4) | def test_load_markdown_without_frontmatter(tmp_path): function test_load_markdown_with_empty_frontmatter (line 18) | def test_load_markdown_with_empty_frontmatter(tmp_path): function test_load_markdown_with_partial_frontmatter (line 37) | def test_load_markdown_with_partial_frontmatter(tmp_path): function test_load_markdown_with_full_frontmatter (line 58) | def test_load_markdown_with_full_frontmatter(tmp_path): FILE: tests/sdk/skills/test_skill_serialization.py function test_repo_skill_serialization (line 16) | def test_repo_skill_serialization(): function test_knowledge_skill_serialization (line 46) | def test_knowledge_skill_serialization(): function test_task_skill_serialization (line 74) | def test_task_skill_serialization(): function test_skill_union_serialization_roundtrip (line 107) | def test_skill_union_serialization_roundtrip(): function test_skill_union_polymorphic_list (line 150) | def test_skill_union_polymorphic_list(): function test_discriminated_union_with_openhands_model (line 203) | def test_discriminated_union_with_openhands_model(): function test_discriminated_union_with_pydantic_model (line 253) | def test_discriminated_union_with_pydantic_model(): FILE: tests/sdk/skills/test_skill_utils.py function test_legacy_micro_agent_load (line 23) | def test_legacy_micro_agent_load(tmp_path): function temp_skills_dir (line 37) | def temp_skills_dir(): function test_knowledge_agent (line 74) | def test_knowledge_agent(): function test_load_skills (line 91) | def test_load_skills(temp_skills_dir): function test_load_skills_with_nested_dirs (line 109) | def test_load_skills_with_nested_dirs(temp_skills_dir): function test_load_skills_with_trailing_slashes (line 141) | def test_load_skills_with_trailing_slashes(temp_skills_dir): function test_invalid_skill_type (line 175) | def test_invalid_skill_type(temp_skills_dir, caplog): function test_cursorrules_file_load (line 211) | def test_cursorrules_file_load(tmp_path): function test_skill_version_as_integer (line 231) | def test_skill_version_as_integer(tmp_path): function test_skill_version_as_float (line 264) | def test_skill_version_as_float(tmp_path): function test_skill_version_as_string_unchanged (line 293) | def test_skill_version_as_string_unchanged(tmp_path): function temp_skills_dir_with_cursorrules (line 323) | def temp_skills_dir_with_cursorrules(): function test_load_skills_with_cursorrules (line 353) | def test_load_skills_with_cursorrules(temp_skills_dir_with_cursorrules): function temp_skills_dir_with_context_files (line 373) | def temp_skills_dir_with_context_files(): function test_load_skills_with_claude_gemini (line 410) | def test_load_skills_with_claude_gemini(temp_skills_dir_with_context_fil... function temp_skills_dir_with_uppercase_context_files (line 438) | def temp_skills_dir_with_uppercase_context_files(): function test_load_skills_with_uppercase_claude_gemini (line 475) | def test_load_skills_with_uppercase_claude_gemini( function temp_skills_dir_with_large_context_file (line 503) | def temp_skills_dir_with_large_context_file(): function test_repo_skill_with_mcp_tools (line 540) | def test_repo_skill_with_mcp_tools(tmp_path): function test_repo_skill_with_mcp_tools_dict_format (line 585) | def test_repo_skill_with_mcp_tools_dict_format(tmp_path): function test_repo_skill_without_mcp_tools (line 633) | def test_repo_skill_without_mcp_tools(tmp_path): function test_repo_skill_with_invalid_mcp_tools (line 661) | def test_repo_skill_with_invalid_mcp_tools(tmp_path): function test_malformed_yaml_frontmatter_does_not_block_siblings (line 689) | def test_malformed_yaml_frontmatter_does_not_block_siblings(temp_skills_... function test_malformed_yaml_regular_md_does_not_block_siblings (line 727) | def test_malformed_yaml_regular_md_does_not_block_siblings(temp_skills_d... function test_find_third_party_files_skips_symlink_duplicates (line 748) | def test_find_third_party_files_skips_symlink_duplicates(tmp_path): function test_load_project_skills_symlinked_claude_to_agents (line 761) | def test_load_project_skills_symlinked_claude_to_agents(tmp_path): function test_find_third_party_files_keeps_distinct_files (line 777) | def test_find_third_party_files_keeps_distinct_files(tmp_path): FILE: tests/sdk/skills/test_task_skill.py function test_task_skill_prompt_appending (line 5) | def test_task_skill_prompt_appending(): FILE: tests/sdk/skills/test_validation_improvements.py function test_description_at_limit (line 10) | def test_description_at_limit() -> None: function test_description_exceeds_limit_is_truncated (line 18) | def test_description_exceeds_limit_is_truncated() -> None: function test_description_truncation_includes_source_path (line 28) | def test_description_truncation_includes_source_path() -> None: FILE: tests/sdk/skills/test_validation_prompt.py function test_to_prompt_generates_xml (line 9) | def test_to_prompt_generates_xml() -> None: function test_to_prompt_never_emits_location (line 34) | def test_to_prompt_never_emits_location() -> None: function test_to_prompt_escapes_xml (line 48) | def test_to_prompt_escapes_xml() -> None: function test_to_prompt_uses_content_fallback (line 60) | def test_to_prompt_uses_content_fallback() -> None: function test_to_prompt_content_fallback_counts_remaining_as_truncated (line 68) | def test_to_prompt_content_fallback_counts_remaining_as_truncated() -> N... function test_to_prompt_truncates_long_descriptions (line 84) | def test_to_prompt_truncates_long_descriptions() -> None: function test_to_prompt_truncation_points_at_invoke_skill_not_source (line 97) | def test_to_prompt_truncation_points_at_invoke_skill_not_source() -> None: FILE: tests/sdk/subagent/test_subagent_loader.py function setup_function (line 15) | def setup_function() -> None: function teardown_function (line 19) | def teardown_function() -> None: function test_load_project_agents (line 23) | def test_load_project_agents(tmp_path: Path) -> None: function test_load_project_agents_skips_subdirs (line 56) | def test_load_project_agents_skips_subdirs(tmp_path: Path) -> None: function test_load_project_agents_empty (line 79) | def test_load_project_agents_empty(tmp_path: Path) -> None: function test_load_project_agents_skips_readme (line 85) | def test_load_project_agents_skips_readme(tmp_path: Path) -> None: function test_load_project_agents_from_openhands_dir (line 101) | def test_load_project_agents_from_openhands_dir(tmp_path: Path) -> None: function test_load_project_agents_agents_dir_wins_over_openhands (line 115) | def test_load_project_agents_agents_dir_wins_over_openhands(tmp_path: Pa... function test_load_project_agents_merges_both_dirs (line 142) | def test_load_project_agents_merges_both_dirs(tmp_path: Path) -> None: function test_load_user_agents (line 159) | def test_load_user_agents(tmp_path: Path) -> None: function test_load_user_agents_from_openhands_dir (line 175) | def test_load_user_agents_from_openhands_dir(tmp_path: Path) -> None: function test_load_user_agents_agents_dir_wins_over_openhands (line 191) | def test_load_user_agents_agents_dir_wins_over_openhands(tmp_path: Path)... FILE: tests/sdk/subagent/test_subagent_registry.py function setup_function (line 24) | def setup_function() -> None: function teardown_function (line 28) | def teardown_function() -> None: function _make_test_llm (line 32) | def _make_test_llm() -> LLM: function _create_skill_file (line 41) | def _create_skill_file(skills_dir: Path, name: str, content: str) -> None: function test_register_file_agents_project_priority (line 49) | def test_register_file_agents_project_priority(tmp_path: Path) -> None: function test_register_file_agents_skips_programmatic (line 76) | def test_register_file_agents_skips_programmatic(tmp_path: Path) -> None: function test_register_plugin_agents (line 108) | def test_register_plugin_agents(tmp_path: Path) -> None: function test_register_plugin_agents_skips_existing (line 125) | def test_register_plugin_agents_skips_existing(tmp_path: Path) -> None: function test_register_agent_if_absent_existing (line 152) | def test_register_agent_if_absent_existing() -> None: function test_agent_definition_to_factory_basic (line 175) | def test_agent_definition_to_factory_basic() -> None: function test_agent_definition_to_factory_model_inherit (line 197) | def test_agent_definition_to_factory_model_inherit() -> None: function test_agent_definition_to_factory_model_override (line 215) | def test_agent_definition_to_factory_model_override() -> None: function test_agent_definition_to_factory_no_system_prompt (line 232) | def test_agent_definition_to_factory_no_system_prompt() -> None: function test_agent_definition_to_factory_with_skills (line 248) | def test_agent_definition_to_factory_with_skills(tmp_path: Path) -> None: function test_agent_definition_to_factory_skills_only_no_prompt (line 275) | def test_agent_definition_to_factory_skills_only_no_prompt(tmp_path: Pat... function test_agent_definition_to_factory_no_skills_no_prompt (line 300) | def test_agent_definition_to_factory_no_skills_no_prompt() -> None: function test_agent_definition_to_factory_skill_not_found (line 318) | def test_agent_definition_to_factory_skill_not_found() -> None: function test_agent_definition_to_factory_skills_project_over_user (line 331) | def test_agent_definition_to_factory_skills_project_over_user(tmp_path: ... function test_factory_info (line 361) | def test_factory_info() -> None: function test_factory_info_mixed_tools_and_no_tools (line 384) | def test_factory_info_mixed_tools_and_no_tools() -> None: function test_factory_info_single_agent (line 410) | def test_factory_info_single_agent() -> None: function test_error_default_factory_empty (line 423) | def test_error_default_factory_empty(name: str | None) -> None: function test_register_and_retrieve_custom_agent_factory (line 429) | def test_register_and_retrieve_custom_agent_factory() -> None: function test_unknown_agent_type_raises_value_error (line 446) | def test_unknown_agent_type_raises_value_error() -> None: function test_register_agent_if_absent_new (line 454) | def test_register_agent_if_absent_new() -> None: function test_agent_definition_to_factory_model_profile (line 471) | def test_agent_definition_to_factory_model_profile(tmp_path: Path) -> None: function test_agent_definition_to_factory_model_profile_with_json_suffix (line 506) | def test_agent_definition_to_factory_model_profile_with_json_suffix( function test_agent_definition_to_factory_model_profile_not_found (line 539) | def test_agent_definition_to_factory_model_profile_not_found(tmp_path: P... function test_agent_definition_to_factory_model_profile_custom_store (line 561) | def test_agent_definition_to_factory_model_profile_custom_store(tmp_path... function test_agent_definition_to_factory_profile_store_dir (line 592) | def test_agent_definition_to_factory_profile_store_dir(tmp_path: Path) -... function test_agent_definition_to_factory_profile_store_dir_not_found (line 617) | def test_agent_definition_to_factory_profile_store_dir_not_found( function test_agent_definition_to_factory_profile_store_dir_none_uses_default (line 636) | def test_agent_definition_to_factory_profile_store_dir_none_uses_default( function test_register_agent_with_hook_config (line 667) | def test_register_agent_with_hook_config() -> None: function test_register_agent_hook_config_defaults_to_none (line 699) | def test_register_agent_hook_config_defaults_to_none() -> None: function test_register_file_agents_with_hooks (line 715) | def test_register_file_agents_with_hooks(tmp_path: Path) -> None: function test_register_plugin_agents_with_hooks (line 743) | def test_register_plugin_agents_with_hooks() -> None: function test_end_to_end_md_to_factory_to_registry (line 770) | def test_end_to_end_md_to_factory_to_registry(tmp_path: Path) -> None: function test_agent_definition_to_factory_mcp_servers (line 813) | def test_agent_definition_to_factory_mcp_servers() -> None: function test_agent_definition_to_factory_no_mcp_servers (line 835) | def test_agent_definition_to_factory_no_mcp_servers() -> None: function test_register_file_agents_passes_mcp_config_to_agent (line 851) | def test_register_file_agents_passes_mcp_config_to_agent(tmp_path: Path)... FILE: tests/sdk/subagent/test_subagent_schema.py class TestAgentDefinition (line 13) | class TestAgentDefinition: method test_load_agent_basic (line 16) | def test_load_agent_basic(self, tmp_path: Path): method test_load_agent_with_examples (line 41) | def test_load_agent_with_examples(self, tmp_path: Path): method test_load_agent_with_color (line 58) | def test_load_agent_with_color(self, tmp_path: Path): method test_load_agent_with_tools_as_string (line 74) | def test_load_agent_with_tools_as_string(self, tmp_path: Path): method test_load_agent_defaults (line 90) | def test_load_agent_defaults(self, tmp_path: Path): method test_load_agent_with_max_iteration_per_run (line 106) | def test_load_agent_with_max_iteration_per_run(self, tmp_path: Path): method test_load_agent_without_max_iteration_per_run (line 122) | def test_load_agent_without_max_iteration_per_run(self, tmp_path: Path): method test_max_iteration_per_run_not_in_metadata (line 137) | def test_max_iteration_per_run_not_in_metadata(self, tmp_path: Path): method test_max_iteration_per_run_zero_raises (line 155) | def test_max_iteration_per_run_zero_raises(self): method test_max_iteration_per_run_negative_raises (line 160) | def test_max_iteration_per_run_negative_raises(self): method test_load_agent_with_metadata (line 165) | def test_load_agent_with_metadata(self, tmp_path: Path): method test_load_agent_with_hooks (line 181) | def test_load_agent_with_hooks(self, tmp_path: Path): method test_load_agent_hooks_none_when_missing (line 216) | def test_load_agent_hooks_none_when_missing(self, tmp_path: Path): method test_skills_default_empty (line 231) | def test_skills_default_empty(self): method test_skills_as_list (line 236) | def test_skills_as_list(self): method test_load_skills_comma_separated (line 244) | def test_load_skills_comma_separated(self, tmp_path: Path): method test_load_skills_as_yaml_list (line 259) | def test_load_skills_as_yaml_list(self, tmp_path: Path): method test_load_skills_single_string (line 276) | def test_load_skills_single_string(self, tmp_path: Path): method test_load_skills_default_empty (line 291) | def test_load_skills_default_empty(self, tmp_path: Path): method test_load_skills_not_in_metadata (line 305) | def test_load_skills_not_in_metadata(self, tmp_path: Path): method test_load_agent_with_profile_store_dir (line 322) | def test_load_agent_with_profile_store_dir(self, tmp_path: Path): method test_load_agent_without_profile_store_dir (line 338) | def test_load_agent_without_profile_store_dir(self, tmp_path: Path): method test_profile_store_dir_not_in_metadata (line 353) | def test_profile_store_dir_not_in_metadata(self, tmp_path: Path): method test_profile_store_dir_default_none (line 371) | def test_profile_store_dir_default_none(self): method test_mcp_servers_default_none (line 376) | def test_mcp_servers_default_none(self): method test_mcp_servers_as_dict (line 381) | def test_mcp_servers_as_dict(self): method test_load_mcp_servers_from_frontmatter (line 387) | def test_load_mcp_servers_from_frontmatter(self, tmp_path: Path): method test_load_mcp_servers_not_in_metadata (line 416) | def test_load_mcp_servers_not_in_metadata(self, tmp_path: Path): method test_load_without_mcp_servers (line 437) | def test_load_without_mcp_servers(self, tmp_path: Path): method test_mcp_servers_env_vars_preserved_in_env_field (line 451) | def test_mcp_servers_env_vars_preserved_in_env_field(self, tmp_path: P... method test_mcp_servers_env_vars_preserved_in_command (line 475) | def test_mcp_servers_env_vars_preserved_in_command(self, tmp_path: Path): method test_mcp_servers_env_vars_preserved_in_url_and_headers (line 502) | def test_mcp_servers_env_vars_preserved_in_url_and_headers(self, tmp_p... method test_mcp_servers_placeholders_preserved (line 528) | def test_mcp_servers_placeholders_preserved(self, tmp_path: Path): method test_permission_mode_defaults_to_none (line 547) | def test_permission_mode_defaults_to_none(self): method test_permission_mode_valid_values (line 560) | def test_permission_mode_valid_values(self, mode: str): method test_load_permission_mode_from_frontmatter (line 565) | def test_load_permission_mode_from_frontmatter(self, tmp_path: Path): method test_load_permission_mode_none_when_omitted (line 580) | def test_load_permission_mode_none_when_omitted(self, tmp_path: Path): method test_load_permission_mode_not_in_metadata (line 594) | def test_load_permission_mode_not_in_metadata(self, tmp_path: Path): method test_get_confirmation_policy_none (line 611) | def test_get_confirmation_policy_none(self): method test_get_confirmation_policy_returns_instance (line 624) | def test_get_confirmation_policy_returns_instance( method test_load_permission_mode_invalid_raises (line 633) | def test_load_permission_mode_invalid_raises(self, tmp_path: Path): class TestExtractExamples (line 649) | class TestExtractExamples: method test_extract_single_example (line 652) | def test_extract_single_example(self): method test_extract_multiple_examples (line 658) | def test_extract_multiple_examples(self): method test_extract_no_examples (line 664) | def test_extract_no_examples(self): method test_extract_multiline_example (line 670) | def test_extract_multiline_example(self): class TestMcpServersPlaceholderPreservation (line 681) | class TestMcpServersPlaceholderPreservation: method test_mcp_servers_preserves_variable_placeholders (line 689) | def test_mcp_servers_preserves_variable_placeholders(self, tmp_path: P... method test_mcp_servers_preserves_complex_placeholders (line 714) | def test_mcp_servers_preserves_complex_placeholders(self, tmp_path: Pa... method test_mcp_servers_without_placeholders_unchanged (line 747) | def test_mcp_servers_without_placeholders_unchanged(self, tmp_path: Pa... FILE: tests/sdk/test_agent_step_bounded_scan.py class _LimitedIterEvents (line 16) | class _LimitedIterEvents(EventLog): method __init__ (line 17) | def __init__(self, events, max_iter: int): method __len__ (line 22) | def __len__(self) -> int: # type: ignore[override] method __getitem__ (line 25) | def __getitem__(self, idx): # type: ignore[override] method __iter__ (line 28) | def __iter__(self) -> Iterator: # type: ignore[override] method append (line 34) | def append(self, event) -> None: # type: ignore[override] class _FailingIterEvents (line 38) | class _FailingIterEvents(EventLog): method __init__ (line 39) | def __init__(self, events): method __len__ (line 42) | def __len__(self) -> int: # type: ignore[override] method __getitem__ (line 45) | def __getitem__(self, idx): # type: ignore[override] method __iter__ (line 48) | def __iter__(self) -> Iterator: # type: ignore[override] method append (line 51) | def append(self, event) -> None: # type: ignore[override] function test_agent_step_latest_user_message_scan_is_bounded (line 55) | def test_agent_step_latest_user_message_scan_is_bounded(tmp_path): function test_agent_step_uses_last_user_message_id (line 85) | def test_agent_step_uses_last_user_message_id(tmp_path): function test_agent_step_legacy_state_no_last_user_id (line 102) | def test_agent_step_legacy_state_no_last_user_id(tmp_path, caplog): FILE: tests/sdk/test_banner.py function reset_banner_state (line 9) | def reset_banner_state(monkeypatch): function test_banner_prints_to_stderr (line 22) | def test_banner_prints_to_stderr(reset_banner_state, capsys): function test_banner_prints_only_once (line 35) | def test_banner_prints_only_once(reset_banner_state, capsys): function test_banner_suppressed_by_env_var (line 45) | def test_banner_suppressed_by_env_var(monkeypatch, reset_banner_state, c... function test_banner_suppressed_by_env_var_true (line 55) | def test_banner_suppressed_by_env_var_true(monkeypatch, reset_banner_sta... FILE: tests/sdk/test_import_performance.py function _measure_import_time_seconds (line 21) | def _measure_import_time_seconds() -> float: function test_import_openhands_sdk_time (line 43) | def test_import_openhands_sdk_time(): FILE: tests/sdk/test_settings.py function test_llm_agent_settings_export_schema_groups_sections (line 47) | def test_llm_agent_settings_export_schema_groups_sections() -> None: function test_acp_agent_settings_export_schema_has_acp_section (line 125) | def test_acp_agent_settings_export_schema_has_acp_section() -> None: function test_conversation_settings_export_schema_groups_sections (line 151) | def test_conversation_settings_export_schema_groups_sections() -> None: function test_conversation_settings_model_dump_roundtrip (line 179) | def test_conversation_settings_model_dump_roundtrip() -> None: function test_conversation_settings_create_request (line 191) | def test_conversation_settings_create_request() -> None: function test_conversation_settings_create_request_with_acp_agent (line 226) | def test_conversation_settings_create_request_with_acp_agent() -> None: function test_export_agent_settings_schema_emits_variant_tagged_sections (line 253) | def test_export_agent_settings_schema_emits_variant_tagged_sections() ->... function test_default_agent_settings_returns_openhands_variant (line 311) | def test_default_agent_settings_returns_openhands_variant() -> None: function test_validate_agent_settings_defaults_to_openhands_when_discriminator_missing (line 317) | def test_validate_agent_settings_defaults_to_openhands_when_discriminato... function test_validate_agent_settings_dispatches_on_agent_kind (line 326) | def test_validate_agent_settings_dispatches_on_agent_kind() -> None: function test_validate_agent_settings_migrates_v0_llm_payload (line 351) | def test_validate_agent_settings_migrates_v0_llm_payload() -> None: function test_validate_agent_settings_dispatches_current_acp_payload (line 360) | def test_validate_agent_settings_dispatches_current_acp_payload() -> None: function test_validate_agent_settings_canonicalizes_legacy_llm_kind (line 376) | def test_validate_agent_settings_canonicalizes_legacy_llm_kind() -> None: function test_validate_agent_settings_drops_legacy_verification_fields (line 393) | def test_validate_agent_settings_drops_legacy_verification_fields() -> N... function test_validate_agent_settings_rejects_newer_schema_version (line 414) | def test_validate_agent_settings_rejects_newer_schema_version() -> None: function test_conversation_settings_from_persisted_migrates_v0_payload (line 419) | def test_conversation_settings_from_persisted_migrates_v0_payload() -> N... function test_conversation_settings_from_persisted_rejects_newer_schema_version (line 426) | def test_conversation_settings_from_persisted_rejects_newer_schema_versi... function test_llm_create_agent_uses_settings_llm_and_tools (line 436) | def test_llm_create_agent_uses_settings_llm_and_tools() -> None: function test_llm_agent_settings_validates_mcp_config_as_typed_model (line 446) | def test_llm_agent_settings_validates_mcp_config_as_typed_model() -> None: function test_llm_create_agent_serializes_typed_mcp_config_compactly (line 463) | def test_llm_create_agent_serializes_typed_mcp_config_compactly() -> None: function test_llm_create_agent_builds_condenser_when_enabled (line 476) | def test_llm_create_agent_builds_condenser_when_enabled() -> None: function test_llm_create_agent_no_condenser_when_disabled (line 485) | def test_llm_create_agent_no_condenser_when_disabled() -> None: function test_llm_create_agent_builds_critic_when_enabled (line 493) | def test_llm_create_agent_builds_critic_when_enabled() -> None: function test_llm_create_agent_no_critic_without_api_key (line 507) | def test_llm_create_agent_no_critic_without_api_key() -> None: function test_llm_create_agent_critic_with_iterative_refinement (line 516) | def test_llm_create_agent_critic_with_iterative_refinement() -> None: function test_llm_roundtrip_preserves_llm_model (line 534) | def test_llm_roundtrip_preserves_llm_model() -> None: function test_acp_create_agent_uses_server_default_command (line 546) | def test_acp_create_agent_uses_server_default_command() -> None: function test_acp_resolve_command_for_known_servers (line 559) | def test_acp_resolve_command_for_known_servers() -> None: function test_acp_create_agent_explicit_command_overrides_default (line 568) | def test_acp_create_agent_explicit_command_overrides_default() -> None: function test_acp_custom_server_requires_explicit_command (line 577) | def test_acp_custom_server_requires_explicit_command() -> None: function test_acp_custom_server_with_command_resolves (line 587) | def test_acp_custom_server_with_command_resolves() -> None: function test_acp_api_key_env_var_maps_known_servers (line 595) | def test_acp_api_key_env_var_maps_known_servers() -> None: function test_acp_resolve_provider_env_from_llm_credentials (line 607) | def test_acp_resolve_provider_env_from_llm_credentials() -> None: function test_acp_resolve_provider_env_custom_server_empty (line 623) | def test_acp_resolve_provider_env_custom_server_empty() -> None: function test_acp_resolve_acp_env_explicit_entries_override_provider_env (line 637) | def test_acp_resolve_acp_env_explicit_entries_override_provider_env() ->... function test_acp_create_agent_passes_resolved_env_and_agent_context (line 647) | def test_acp_create_agent_passes_resolved_env_and_agent_context() -> None: function test_legacy_agent_settings_still_instantiates_as_llm_variant (line 666) | def test_legacy_agent_settings_still_instantiates_as_llm_variant() -> None: function test_legacy_agent_settings_retains_all_v1_17_attributes (line 691) | def test_legacy_agent_settings_retains_all_v1_17_attributes() -> None: function test_llm_agent_settings_deprecated_alias_emits_warning (line 711) | def test_llm_agent_settings_deprecated_alias_emits_warning() -> None: function test_conversation_settings_create_request_for_llm_variant (line 737) | def test_conversation_settings_create_request_for_llm_variant() -> None: function test_conversation_settings_create_request_with_acp_agent_variant (line 759) | def test_conversation_settings_create_request_with_acp_agent_variant() -... function test_conversation_settings_agent_settings_field_accepts_both_variants (line 781) | def test_conversation_settings_agent_settings_field_accepts_both_variant... function test_acp_agent_settings_acp_env_redacted_by_default (line 799) | def test_acp_agent_settings_acp_env_redacted_by_default() -> None: function test_acp_agent_settings_acp_env_encrypts_with_cipher (line 815) | def test_acp_agent_settings_acp_env_encrypts_with_cipher() -> None: function test_openhands_agent_settings_mcp_config_redacts_env_and_headers (line 855) | def test_openhands_agent_settings_mcp_config_redacts_env_and_headers() -... function test_mcp_config_encrypts_env_and_headers_with_cipher (line 880) | def test_mcp_config_encrypts_env_and_headers_with_cipher() -> None: function test_openhands_agent_settings_mcp_config_decrypt_legacy_plaintext_on_disk (line 941) | def test_openhands_agent_settings_mcp_config_decrypt_legacy_plaintext_on... function test_openhands_agent_settings_mcp_config_expose_encrypted_requires_cipher (line 975) | def test_openhands_agent_settings_mcp_config_expose_encrypted_requires_c... function test_openhands_agent_settings_mcp_config_expose_plaintext_passes_through (line 1010) | def test_openhands_agent_settings_mcp_config_expose_plaintext_passes_thr... function test_openhands_agent_settings_create_agent_keeps_real_mcp_secrets (line 1042) | def test_openhands_agent_settings_create_agent_keeps_real_mcp_secrets() ... function test_agent_settings_base_is_parent_of_both_variants (line 1066) | def test_agent_settings_base_is_parent_of_both_variants() -> None: function test_agent_settings_base_schema_version_inherited (line 1071) | def test_agent_settings_base_schema_version_inherited() -> None: function test_agent_settings_base_export_schema_works_on_both_variants (line 1078) | def test_agent_settings_base_export_schema_works_on_both_variants() -> N... function test_agent_settings_base_create_agent_is_callable_via_interface (line 1085) | def test_agent_settings_base_create_agent_is_callable_via_interface() ->... function test_acp_settings_provider_info_returns_registry_entry (line 1103) | def test_acp_settings_provider_info_returns_registry_entry() -> None: function test_acp_settings_provider_info_returns_none_for_custom (line 1111) | def test_acp_settings_provider_info_returns_none_for_custom() -> None: function test_acp_settings_api_key_env_var_from_registry (line 1116) | def test_acp_settings_api_key_env_var_from_registry() -> None: function test_acp_settings_base_url_env_var_from_registry (line 1128) | def test_acp_settings_base_url_env_var_from_registry() -> None: function test_acp_resolve_command_uses_registry_defaults (line 1143) | def test_acp_resolve_command_uses_registry_defaults() -> None: function test_regular_agent_supports_all_capabilities (line 1157) | def test_regular_agent_supports_all_capabilities() -> None: function test_acp_agent_reports_no_openhands_capabilities (line 1165) | def test_acp_agent_reports_no_openhands_capabilities() -> None: FILE: tests/sdk/test_socks_proxy_support.py function test_socksio_is_installed (line 14) | def test_socksio_is_installed(): function test_httpx_socks_extra_available (line 19) | def test_httpx_socks_extra_available(): function test_import_with_socks_proxy_env (line 30) | def test_import_with_socks_proxy_env(): FILE: tests/sdk/tool/test_builtins.py function test_all_tools_property (line 4) | def test_all_tools_property(): FILE: tests/sdk/tool/test_invoke_skill.py function _make_skill (line 26) | def _make_skill( function _make_conv (line 44) | def _make_conv( function _tool (line 66) | def _tool() -> InvokeSkillTool: function _run (line 71) | def _run(name: str, conv: Any) -> InvokeSkillObservation: function test_not_in_default_builtins_but_resolvable_by_name (line 78) | def test_not_in_default_builtins_but_resolvable_by_name(): function test_name_auto_derived (line 86) | def test_name_auto_derived(): function test_create_rejects_params (line 90) | def test_create_rejects_params(): function test_annotations_are_read_only_safe (line 104) | def test_annotations_are_read_only_safe(attr: str, expected: bool): function test_invoke_renders_and_records (line 127) | def test_invoke_renders_and_records( function test_name_is_trimmed_before_lookup (line 148) | def test_name_is_trimmed_before_lookup(requested: str): function test_footer_uses_absolute_path_when_outside_working_dir (line 157) | def test_footer_uses_absolute_path_when_outside_working_dir(tmp_path): function test_footer_uses_relative_path_when_inside_working_dir (line 181) | def test_footer_uses_relative_path_when_inside_working_dir(tmp_path): function test_footer_omitted_when_skill_has_no_source (line 206) | def test_footer_omitted_when_skill_has_no_source(): function test_footer_omitted_when_source_is_not_a_real_path (line 224) | def test_footer_omitted_when_source_is_not_a_real_path(): function test_invoked_skills_dedupes (line 242) | def test_invoked_skills_dedupes(): function test_legacy_triggered_skill_is_invocable (line 251) | def test_legacy_triggered_skill_is_invocable(): function test_disable_model_invocation_rejects_direct_invocation (line 270) | def test_disable_model_invocation_rejects_direct_invocation(): function test_error_paths_do_not_mutate_state (line 309) | def test_error_paths_do_not_mutate_state( function test_declared_resources_keyed_on_skill_name (line 328) | def test_declared_resources_keyed_on_skill_name(skill_name: str): function _make_agent (line 335) | def _make_agent(skills: list[Skill]) -> Agent: function test_agent_auto_attaches_invoke_skill_tool (line 383) | def test_agent_auto_attaches_invoke_skill_tool( FILE: tests/sdk/tool/test_mcp_schema.py class MCPSchemaTestAction (line 12) | class MCPSchemaTestAction(Action): class MCPComplexAction (line 19) | class MCPComplexAction(Action): class MCPSchemaTestObservation (line 27) | class MCPSchemaTestObservation(Observation): method to_llm_content (line 33) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: function test_action_to_mcp_schema_excludes_kind (line 37) | def test_action_to_mcp_schema_excludes_kind(): function test_action_to_mcp_schema_includes_actual_fields (line 53) | def test_action_to_mcp_schema_includes_actual_fields(): function test_observation_to_mcp_schema_excludes_kind (line 69) | def test_observation_to_mcp_schema_excludes_kind(): function test_complex_action_to_mcp_schema_excludes_kind (line 85) | def test_complex_action_to_mcp_schema_excludes_kind(): function test_mcp_schema_structure (line 105) | def test_mcp_schema_structure(): function test_kind_field_works_for_discriminated_union (line 123) | def test_kind_field_works_for_discriminated_union(): class TestCircularSchemaHandling (line 144) | class TestCircularSchemaHandling: method test_circular_ref_returns_generic_object (line 154) | def test_circular_ref_returns_generic_object(self): method test_tree_schema_to_mcp_works (line 220) | def test_tree_schema_to_mcp_works(self): method test_deeply_nested_non_circular_schema_fully_resolved (line 259) | def test_deeply_nested_non_circular_schema_fully_resolved(self): method test_non_circular_ref_fully_resolved (line 301) | def test_non_circular_ref_fully_resolved(self): method test_circular_ref_does_not_raise_recursion_error (line 331) | def test_circular_ref_does_not_raise_recursion_error(self): method test_linked_list_schema_to_mcp_works (line 365) | def test_linked_list_schema_to_mcp_works(self): FILE: tests/sdk/tool/test_py_type.py class TestPyTypePrimitiveTypes (line 8) | class TestPyTypePrimitiveTypes: method test_string_type (line 11) | def test_string_type(self): method test_integer_type (line 22) | def test_integer_type(self): method test_number_type (line 33) | def test_number_type(self): method test_boolean_type (line 44) | def test_boolean_type(self): class TestPyTypeObjectType (line 56) | class TestPyTypeObjectType: method test_object_type (line 59) | def test_object_type(self): class TestPyTypeArrayType (line 71) | class TestPyTypeArrayType: method test_array_without_items (line 74) | def test_array_without_items(self): method test_array_with_dict_items (line 85) | def test_array_with_dict_items(self): method test_array_with_nested_array (line 96) | def test_array_with_nested_array(self): method test_array_with_non_dict_items (line 110) | def test_array_with_non_dict_items(self): class TestPyTypeUnionTypes (line 122) | class TestPyTypeUnionTypes: method test_union_list_with_single_non_null (line 125) | def test_union_list_with_single_non_null(self): method test_union_tuple_with_single_non_null (line 136) | def test_union_tuple_with_single_non_null(self): method test_union_set_with_single_non_null (line 147) | def test_union_set_with_single_non_null(self): method test_union_with_multiple_non_null_types (line 158) | def test_union_with_multiple_non_null_types(self): method test_union_with_only_null (line 169) | def test_union_with_only_null(self): method test_union_with_three_types_one_null (line 180) | def test_union_with_three_types_one_null(self): class TestPyTypeEdgeCases (line 192) | class TestPyTypeEdgeCases: method test_missing_type_key (line 195) | def test_missing_type_key(self): method test_unknown_type (line 206) | def test_unknown_type(self): method test_empty_dict (line 217) | def test_empty_dict(self): method test_type_none (line 228) | def test_type_none(self): method test_array_with_empty_items_dict (line 239) | def test_array_with_empty_items_dict(self): FILE: tests/sdk/tool/test_registry.py function _create_mock_conv_state (line 17) | def _create_mock_conv_state() -> ConversationState: class _HelloAction (line 25) | class _HelloAction(Action): class _HelloObservation (line 29) | class _HelloObservation(Observation): method to_llm_content (line 33) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class _HelloExec (line 37) | class _HelloExec(ToolExecutor[_HelloAction, _HelloObservation]): method __call__ (line 38) | def __call__(self, action: _HelloAction, conversation=None) -> _HelloO... class _ConfigurableHelloTool (line 42) | class _ConfigurableHelloTool(ToolDefinition): method create (line 44) | def create( class _SimpleHelloTool (line 72) | class _SimpleHelloTool(ToolDefinition[_HelloAction, _HelloObservation]): method create (line 76) | def create(cls, conv_state=None, **params) -> Sequence["_SimpleHelloTo... class _UnavailableHelloTool (line 87) | class _UnavailableHelloTool(_SimpleHelloTool): method is_usable (line 89) | def is_usable(cls) -> bool: function _hello_tool_factory (line 93) | def _hello_tool_factory(conv_state=None, **params) -> list[ToolDefinition]: function test_register_and_resolve_callable_factory (line 97) | def test_register_and_resolve_callable_factory(): function test_register_tool_type_respects_is_usable (line 108) | def test_register_tool_type_respects_is_usable(): function test_register_tool_instance_rejects_params (line 114) | def test_register_tool_instance_rejects_params(): function test_register_tool_instance_returns_same_object (line 124) | def test_register_tool_instance_returns_same_object(): function test_register_tool_type_uses_create_params (line 140) | def test_register_tool_type_uses_create_params(): FILE: tests/sdk/tool/test_schema_immutability.py class MockSchema (line 18) | class MockSchema(Schema): class SchemaImmutabilityMockAction (line 26) | class SchemaImmutabilityMockAction(Action): class MockMCPAction (line 34) | class MockMCPAction(MCPToolAction): class SchemaImmutabilityMockObservation (line 43) | class SchemaImmutabilityMockObservation(Observation): method to_llm_content (line 51) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class _SchemaImmutabilityCustomAction (line 56) | class _SchemaImmutabilityCustomAction(Action): class _SchemaImmutabilityCustomObservation (line 68) | class _SchemaImmutabilityCustomObservation(Observation): method to_llm_content (line 80) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: function test_schema_is_frozen (line 84) | def test_schema_is_frozen(): function test_action_base_is_frozen (line 99) | def test_action_base_is_frozen(): function test_mcp_action_base_is_frozen (line 114) | def test_mcp_action_base_is_frozen(): function test_observation_base_is_frozen (line 126) | def test_observation_base_is_frozen(): function test_schema_model_copy_creates_new_instance (line 143) | def test_schema_model_copy_creates_new_instance(): function test_action_model_copy_creates_new_instance (line 162) | def test_action_model_copy_creates_new_instance(): function test_mcp_action_model_copy_creates_new_instance (line 183) | def test_mcp_action_model_copy_creates_new_instance(): function test_observation_model_copy_creates_new_instance (line 204) | def test_observation_model_copy_creates_new_instance(): function test_schema_immutability_prevents_mutation_bugs (line 230) | def test_schema_immutability_prevents_mutation_bugs(): function test_all_schema_classes_are_frozen (line 279) | def test_all_schema_classes_are_frozen(): function test_schema_inheritance_preserves_immutability (line 302) | def test_schema_inheritance_preserves_immutability(): FILE: tests/sdk/tool/test_switch_llm.py function _make_llm (line 17) | def _make_llm(model: str, usage_id: str) -> LLM: function empty_profile_store (line 22) | def empty_profile_store( function profile_store (line 32) | def profile_store(empty_profile_store: LLMProfileStore) -> LLMProfileStore: function _make_conversation (line 38) | def _make_conversation() -> LocalConversation: function test_switch_llm_tool_description_lists_available_profiles (line 49) | def test_switch_llm_tool_description_lists_available_profiles(profile_st... function test_agent_settings_includes_switch_llm_tool_when_profiles_exist (line 57) | def test_agent_settings_includes_switch_llm_tool_when_profiles_exist(pro... function test_agent_settings_omits_switch_llm_tool_when_disabled (line 69) | def test_agent_settings_omits_switch_llm_tool_when_disabled(profile_store): function test_agent_settings_omits_switch_llm_tool_without_profiles (line 82) | def test_agent_settings_omits_switch_llm_tool_without_profiles(empty_pro... function test_switch_llm_tool_switches_conversation_profile (line 94) | def test_switch_llm_tool_switches_conversation_profile(profile_store): function test_switch_llm_tool_reports_missing_profile (line 114) | def test_switch_llm_tool_reports_missing_profile(profile_store): function test_switch_llm_tool_reports_unexpected_profile_load_error (line 132) | def test_switch_llm_tool_reports_unexpected_profile_load_error( FILE: tests/sdk/tool/test_to_responses_tool.py class A (line 7) | class A(Action): class Obs (line 11) | class Obs(Observation): method to_llm_content (line 12) | def to_llm_content(self): # type: ignore[override] class T (line 18) | class T(ToolDefinition[A, Obs]): method create (line 22) | def create(cls, *args, **kwargs): # pragma: no cover function test_to_responses_tool_includes_strict_and_params (line 26) | def test_to_responses_tool_includes_strict_and_params(): FILE: tests/sdk/tool/test_to_responses_tool_security.py class TRTSAction (line 9) | class TRTSAction(Action): class MockSecurityTool1 (line 13) | class MockSecurityTool1(ToolDefinition[TRTSAction, Observation]): method create (line 19) | def create(cls, conv_state=None, **params) -> Sequence["MockSecurityTo... class MockSecurityTool2 (line 23) | class MockSecurityTool2(ToolDefinition[TRTSAction, Observation]): method create (line 29) | def create(cls, conv_state=None, **params) -> Sequence["MockSecurityTo... class MockSecurityTool3 (line 33) | class MockSecurityTool3(ToolDefinition[TRTSAction, Observation]): method create (line 39) | def create(cls, conv_state=None, **params) -> Sequence["MockSecurityTo... function test_to_responses_tool_security_gating (line 43) | def test_to_responses_tool_security_gating(): FILE: tests/sdk/tool/test_to_responses_tool_summary.py class TSAction (line 16) | class TSAction(Action): class MockSummaryTool (line 20) | class MockSummaryTool(ToolDefinition[TSAction, Observation]): method create (line 26) | def create(cls, conv_state=None, **params) -> Sequence["MockSummaryToo... function tool (line 31) | def tool(): function test_to_responses_tool_summary_always_added (line 40) | def test_to_responses_tool_summary_always_added(tool): function test_to_openai_tool_summary_always_added (line 50) | def test_to_openai_tool_summary_always_added(tool): function test_mcp_tool_with_summary_param_preserves_original_description (line 62) | def test_mcp_tool_with_summary_param_preserves_original_description(): FILE: tests/sdk/tool/test_tool.py class _Bug2199Action (line 22) | class _Bug2199Action(Action, ABC): class _Bug2642ActionA (line 26) | class _Bug2642ActionA(Action, ABC): class _Bug2642ActionB (line 30) | class _Bug2642ActionB(Action, ABC): class _Bug2642ActionC (line 34) | class _Bug2642ActionC(Action, ABC): function test_tool_minimal (line 38) | def test_tool_minimal(): function test_tool_with_params (line 46) | def test_tool_with_params(): function test_tool_complex_params (line 55) | def test_tool_complex_params(): function test_tool_serialization (line 73) | def test_tool_serialization(): function test_tool_validation_requires_name (line 93) | def test_tool_validation_requires_name(): function test_tool_examples_from_docstring (line 99) | def test_tool_examples_from_docstring(): function test_tool_different_tool_types (line 115) | def test_tool_different_tool_types(): function test_tool_nested_params (line 137) | def test_tool_nested_params(): function test_tool_field_descriptions (line 158) | def test_tool_field_descriptions(): function test_tool_default_params (line 175) | def test_tool_default_params(): function test_tool_immutability (line 181) | def test_tool_immutability(): function test_tool_validation_edge_cases (line 191) | def test_tool_validation_edge_cases(): function test_tool_repr (line 202) | def test_tool_repr(): function test_issue_2199_1 (line 211) | def test_issue_2199_1(request): function test_issue_2199_2 (line 249) | def test_issue_2199_2(request): function test_issue_2642 (line 283) | def test_issue_2642(request): FILE: tests/sdk/tool/test_tool_call_output_coercion.py class OCAAction (line 10) | class OCAAction(Action): class OCAObs (line 14) | class OCAObs(Observation): method to_llm_content (line 18) | def to_llm_content(self): # type: ignore[override] class CoercionTestObs (line 27) | class CoercionTestObs(Observation): method to_llm_content (line 33) | def to_llm_content(self): # type: ignore[override] class MockCoercionTool (line 39) | class MockCoercionTool(ToolDefinition[OCAAction, OCAObs]): method create (line 43) | def create(cls, conv_state=None, **params) -> Sequence["MockCoercionTo... function test_tool_call_with_observation_none_result_shapes (line 47) | def test_tool_call_with_observation_none_result_shapes(): FILE: tests/sdk/tool/test_tool_definition.py class ToolMockAction (line 19) | class ToolMockAction(Action): class ComplexSchemaAction (line 31) | class ComplexSchemaAction(Action): class RequiredFieldAction (line 39) | class RequiredFieldAction(Action): class ComplexNestedAction (line 48) | class ComplexNestedAction(Action): class ToolMockObservation (line 65) | class ToolMockObservation(Observation): method to_llm_content (line 72) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class ComplexObservation (line 76) | class ComplexObservation(Observation): method to_llm_content (line 83) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class RequiredFieldsObservation (line 87) | class RequiredFieldsObservation(Observation): method to_llm_content (line 98) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class MockTestTool (line 102) | class MockTestTool(ToolDefinition[ToolMockAction, ToolMockObservation]): method create (line 106) | def create(cls, conv_state=None, **params) -> Sequence["MockTestTool"]: class TestTool (line 110) | class TestTool: method test_tool_creation_basic (line 113) | def test_tool_creation_basic(self): method test_tool_creation_with_executor (line 127) | def test_tool_creation_with_executor(self): method test_tool_creation_with_annotations (line 148) | def test_tool_creation_with_annotations(self): method test_to_mcp_tool_basic (line 169) | def test_to_mcp_tool_basic(self): method test_to_mcp_tool_with_annotations (line 192) | def test_to_mcp_tool_with_annotations(self): method test_call_without_executor (line 214) | def test_call_without_executor(self): method test_call_with_executor (line 228) | def test_call_with_executor(self): method test_schema_generation_complex_types (line 248) | def test_schema_generation_complex_types(self): method test_observation_type_validation (line 266) | def test_observation_type_validation(self): method test_observation_with_extra_fields (line 287) | def test_observation_with_extra_fields(self): method test_action_validation_with_nested_data (line 308) | def test_action_validation_with_nested_data(self): method test_schema_roundtrip_conversion (line 329) | def test_schema_roundtrip_conversion(self): method test_tool_with_no_observation_type (line 348) | def test_tool_with_no_observation_type(self): method test_executor_function_attachment (line 362) | def test_executor_function_attachment(self): method test_tool_name_validation (line 386) | def test_tool_name_validation(self): method test_complex_executor_return_types (line 396) | def test_complex_executor_return_types(self): method test_error_handling_in_executor (line 420) | def test_error_handling_in_executor(self): method test_executor_with_observation_validation (line 438) | def test_executor_with_observation_validation(self): method test_tool_equality_and_hashing (line 458) | def test_tool_equality_and_hashing(self): method test_mcp_tool_schema_required_fields (line 477) | def test_mcp_tool_schema_required_fields(self): method test_tool_with_meta_data (line 493) | def test_tool_with_meta_data(self): method test_to_mcp_tool_complex_nested_types (line 510) | def test_to_mcp_tool_complex_nested_types(self): method test_security_risk_only_added_for_non_readonly_tools (line 552) | def test_security_risk_only_added_for_non_readonly_tools(self): method test_security_risk_is_optional_field_in_schema (line 632) | def test_security_risk_is_optional_field_in_schema(self): method test_security_risk_precedes_content_params_in_schema (line 682) | def test_security_risk_precedes_content_params_in_schema(self): method test_as_executable_with_executor (line 710) | def test_as_executable_with_executor(self): method test_as_executable_without_executor (line 736) | def test_as_executable_without_executor(self): FILE: tests/sdk/tool/test_tool_immutability.py class ToolImmutabilityMockAction (line 19) | class ToolImmutabilityMockAction(Action): class ToolImmutabilityMockObservation (line 28) | class ToolImmutabilityMockObservation(Observation): method to_llm_content (line 35) | def to_llm_content(self) -> Sequence[TextContent | ImageContent]: class MockImmutableTool (line 39) | class MockImmutableTool( method create (line 45) | def create(cls, conv_state=None, **params) -> Sequence["MockImmutableT... class TestToolImmutability (line 49) | class TestToolImmutability: method test_tool_is_frozen (line 52) | def test_tool_is_frozen(self): method test_tool_set_executor_returns_new_instance (line 68) | def test_tool_set_executor_returns_new_instance(self): method test_tool_model_copy_creates_modified_instance (line 94) | def test_tool_model_copy_creates_modified_instance(self): method test_tool_meta_field_immutability (line 114) | def test_tool_meta_field_immutability(self): method test_tool_constructor_parameter_validation (line 137) | def test_tool_constructor_parameter_validation(self): method test_tool_annotations_immutability (line 156) | def test_tool_annotations_immutability(self): FILE: tests/sdk/tool/test_tool_serialization.py function test_tool_serialization_deserialization (line 12) | def test_tool_serialization_deserialization() -> None: function test_tool_supports_polymorphic_field_json_serialization (line 29) | def test_tool_supports_polymorphic_field_json_serialization() -> None: function test_tool_supports_nested_polymorphic_json_serialization (line 51) | def test_tool_supports_nested_polymorphic_json_serialization() -> None: function test_tool_model_validate_json_dict (line 78) | def test_tool_model_validate_json_dict() -> None: function test_tool_no_fallback_behavior_json (line 96) | def test_tool_no_fallback_behavior_json() -> None: function test_tool_type_annotation_works_json (line 114) | def test_tool_type_annotation_works_json() -> None: function test_tool_kind_field_json (line 137) | def test_tool_kind_field_json() -> None: FILE: tests/sdk/utils/test_async_utils.py class AsyncUtilsMockEvent (line 15) | class AsyncUtilsMockEvent(Event): function test_async_conversation_callback_type (line 22) | def test_async_conversation_callback_type(): function test_async_callback_wrapper_basic (line 33) | def test_async_callback_wrapper_basic(): function test_async_callback_wrapper_multiple_events (line 60) | def test_async_callback_wrapper_multiple_events(): function test_async_callback_wrapper_with_stopped_loop (line 87) | def test_async_callback_wrapper_with_stopped_loop(): function test_async_callback_wrapper_exception_handling (line 112) | def test_async_callback_wrapper_exception_handling(): function test_async_callback_wrapper_concurrent_execution (line 134) | def test_async_callback_wrapper_concurrent_execution(): function test_async_callback_wrapper_from_different_thread (line 176) | def test_async_callback_wrapper_from_different_thread(): function test_async_callback_wrapper_performance (line 213) | def test_async_callback_wrapper_performance(): FILE: tests/sdk/utils/test_cipher.py function test_cipher_encrypt_decrypt (line 11) | def test_cipher_encrypt_decrypt(): function test_cipher_encrypt_none (line 31) | def test_cipher_encrypt_none(): function test_cipher_decrypt_none (line 40) | def test_cipher_decrypt_none(): function test_cipher_decrypt_invalid_data (line 49) | def test_cipher_decrypt_invalid_data(): function test_cipher_decrypt_wrong_key (line 63) | def test_cipher_decrypt_wrong_key(): function test_cipher_fernet_caching (line 83) | def test_cipher_fernet_caching(): function test_cipher_with_real_fernet_key (line 97) | def test_cipher_with_real_fernet_key(): function test_cipher_multiple_encryptions_different (line 114) | def test_cipher_multiple_encryptions_different(): function test_cipher_empty_string (line 139) | def test_cipher_empty_string(): function test_cipher_unicode_content (line 155) | def test_cipher_unicode_content(): function test_cipher_long_content (line 169) | def test_cipher_long_content(): FILE: tests/sdk/utils/test_command.py function test_sanitized_env_returns_copy (line 9) | def test_sanitized_env_returns_copy(): function test_sanitized_env_defaults_to_os_environ (line 17) | def test_sanitized_env_defaults_to_os_environ(monkeypatch): function test_sanitized_env_accepts_mapping_types (line 24) | def test_sanitized_env_accepts_mapping_types(): function test_sanitized_env_ld_library_path (line 42) | def test_sanitized_env_ld_library_path(env: dict[str, str], expected_ld_... function test_sanitized_env_removes_ld_library_path_when_orig_empty (line 47) | def test_sanitized_env_removes_ld_library_path_when_orig_empty(): class TestExecuteCommandLoggingRedaction (line 58) | class TestExecuteCommandLoggingRedaction: method test_logs_command_without_errors (line 61) | def test_logs_command_without_errors(self, caplog): method test_redacts_api_key_from_string_command (line 81) | def test_redacts_api_key_from_string_command(self): method test_redacts_key_value_env_format (line 97) | def test_redacts_key_value_env_format(self): method test_preserves_non_sensitive_args (line 111) | def test_preserves_non_sensitive_args(self, caplog): FILE: tests/sdk/utils/test_deprecation.py function test_warn_deprecated_uses_project_versions (line 15) | def test_warn_deprecated_uses_project_versions() -> None: function test_deprecated_decorator_warns_and_preserves_call (line 30) | def test_deprecated_decorator_warns_and_preserves_call() -> None: function test_deprecated_decorator_allows_version_overrides (line 47) | def test_deprecated_decorator_allows_version_overrides( function test_warn_deprecated_allows_indefinite_removal (line 66) | def test_warn_deprecated_allows_indefinite_removal() -> None: function test_deprecated_decorator_supports_indefinite_removal (line 76) | def test_deprecated_decorator_supports_indefinite_removal() -> None: function test_warn_cleanup_with_version_deadline (line 89) | def test_warn_cleanup_with_version_deadline() -> None: function test_warn_cleanup_with_date_deadline (line 105) | def test_warn_cleanup_with_date_deadline() -> None: function test_warn_cleanup_before_deadline_no_warning (line 120) | def test_warn_cleanup_before_deadline_no_warning() -> None: function test_warn_cleanup_date_in_future_no_warning (line 134) | def test_warn_cleanup_date_in_future_no_warning() -> None: FILE: tests/sdk/utils/test_discriminated_union.py class Animal (line 20) | class Animal(DiscriminatedUnionMixin, ABC): class Cat (line 24) | class Cat(Animal): class Canine (line 28) | class Canine(Animal, ABC): class Dog (line 32) | class Dog(Canine): class Wolf (line 36) | class Wolf(Canine): method genus (line 39) | def genus(self) -> str: method _remove_genus (line 44) | def _remove_genus(cls, data): class AnimalPack (line 55) | class AnimalPack(BaseModel): method alpha (line 60) | def alpha(self) -> Animal | None: method num_animals (line 64) | def num_animals(self): method _remove_alpha (line 69) | def _remove_alpha(cls, data): class Mythical (line 80) | class Mythical(DiscriminatedUnionMixin, ABC): method get_description (line 84) | def get_description(self) -> str: class MythicalPack (line 88) | class MythicalPack(OpenHandsModel): class SomeBase (line 92) | class SomeBase(DiscriminatedUnionMixin, ABC): class SomeImpl (line 96) | class SomeImpl(SomeBase): function test_json_schema_expected (line 100) | def test_json_schema_expected() -> None: function test_json_schema (line 152) | def test_json_schema() -> None: function test_additional_field (line 157) | def test_additional_field() -> None: function test_property (line 166) | def test_property() -> None: function test_serialize_single_model (line 178) | def test_serialize_single_model() -> None: function test_serialize_single_model_with_type_adapter (line 188) | def test_serialize_single_model_with_type_adapter() -> None: function test_serialize_model_list (line 199) | def test_serialize_model_list() -> None: function test_model_containing_polymorphic_field (line 207) | def test_model_containing_polymorphic_field(): function test_duplicate_kind (line 230) | def test_duplicate_kind(): function test_enhanced_error_message_with_validation (line 250) | def test_enhanced_error_message_with_validation(): function test_dynamic_field_error (line 269) | def test_dynamic_field_error(): function test_enhanced_error_message_for_no_kinds (line 286) | def test_enhanced_error_message_for_no_kinds(): function test_enhanced_error_message_for_nested_no_kinds (line 300) | def test_enhanced_error_message_for_nested_no_kinds(): function test_enhanced_error_message_for_nested_no_kinds_type_adapter (line 314) | def test_enhanced_error_message_for_nested_no_kinds_type_adapter(): FILE: tests/sdk/utils/test_github.py function test_sanitize_basic_mention (line 6) | def test_sanitize_basic_mention(): function test_sanitize_case_insensitive (line 13) | def test_sanitize_case_insensitive(): function test_sanitize_multiple_mentions (line 25) | def test_sanitize_multiple_mentions(): function test_sanitize_with_punctuation (line 32) | def test_sanitize_with_punctuation(): function test_no_sanitize_partial_words (line 48) | def test_no_sanitize_partial_words(): function test_no_op_cases (line 61) | def test_no_op_cases(): function test_sanitize_at_line_boundaries (line 75) | def test_sanitize_at_line_boundaries(): function test_sanitize_multiline_text (line 86) | def test_sanitize_multiline_text(): function test_sanitize_with_urls (line 103) | def test_sanitize_with_urls(): function test_sanitize_preserves_whitespace (line 118) | def test_sanitize_preserves_whitespace(): function test_zwj_constant (line 125) | def test_zwj_constant(): FILE: tests/sdk/utils/test_model_prompt_spec.py function test_gpt5_variant_detection (line 30) | def test_gpt5_variant_detection( function test_other_families (line 52) | def test_other_families( FILE: tests/sdk/utils/test_paging.py class MockPage (line 12) | class MockPage: class MockSearchService (line 19) | class MockSearchService: method __init__ (line 22) | def __init__(self, all_items: list[Any], page_size: int = 2): method search (line 26) | async def search(self, page_id: str | None = None, **kwargs) -> MockPage: function test_page_iterator_empty_results (line 50) | async def test_page_iterator_empty_results(): function test_page_iterator_single_page (line 62) | async def test_page_iterator_single_page(): function test_page_iterator_multiple_pages (line 74) | async def test_page_iterator_multiple_pages(): function test_page_iterator_with_kwargs (line 88) | async def test_page_iterator_with_kwargs(): function test_page_iterator_with_args (line 111) | async def test_page_iterator_with_args(): function test_page_iterator_preserves_initial_page_id (line 130) | async def test_page_iterator_preserves_initial_page_id(): function test_page_iterator_removes_page_id_from_kwargs (line 143) | async def test_page_iterator_removes_page_id_from_kwargs(): function test_page_iterator_complex_objects (line 168) | async def test_page_iterator_complex_objects(): FILE: tests/sdk/utils/test_path.py function test_to_posix_path_normalizes_backslashes_without_resolving (line 13) | def test_to_posix_path_normalizes_backslashes_without_resolving(): function test_to_posix_path_accepts_path_objects (line 17) | def test_to_posix_path_accepts_path_objects(): function test_posix_path_name_handles_windows_separators (line 21) | def test_posix_path_name_handles_windows_separators(): function test_is_local_path_source_detects_windows_absolute_paths (line 25) | def test_is_local_path_source_detects_windows_absolute_paths(): function test_is_local_path_source_keeps_url_sources_remote (line 29) | def test_is_local_path_source_keeps_url_sources_remote(): function test_is_local_path_source_detects_backslash_path_syntax (line 33) | def test_is_local_path_source_detects_backslash_path_syntax(): function test_is_local_path_source_detects_dot_paths (line 38) | def test_is_local_path_source_detects_dot_paths(): function test_is_absolute_path_source_detects_posix_and_windows_paths (line 44) | def test_is_absolute_path_source_detects_posix_and_windows_paths(): function test_is_host_absolute_path_uses_current_platform_semantics (line 52) | def test_is_host_absolute_path_uses_current_platform_semantics(): FILE: tests/sdk/utils/test_pydantic_secrets.py function cipher (line 19) | def cipher(): function mock_info (line 26) | def mock_info(): function test_is_redacted_secret_with_redacted_string (line 40) | def test_is_redacted_secret_with_redacted_string(): function test_is_redacted_secret_with_redacted_secretstr (line 44) | def test_is_redacted_secret_with_redacted_secretstr(): function test_is_redacted_secret_with_normal_string (line 48) | def test_is_redacted_secret_with_normal_string(): function test_is_redacted_secret_with_normal_secretstr (line 52) | def test_is_redacted_secret_with_normal_secretstr(): function test_is_redacted_secret_with_none (line 56) | def test_is_redacted_secret_with_none(): function test_serialize_secret_none_returns_none (line 63) | def test_serialize_secret_none_returns_none(mock_info): function test_serialize_secret_no_context_returns_secretstr (line 68) | def test_serialize_secret_no_context_returns_secretstr(mock_info): function test_serialize_secret_empty_context_returns_secretstr (line 76) | def test_serialize_secret_empty_context_returns_secretstr(mock_info): function test_serialize_secret_plaintext_mode (line 83) | def test_serialize_secret_plaintext_mode(mock_info): function test_serialize_secret_plaintext_mode_bool_true (line 90) | def test_serialize_secret_plaintext_mode_bool_true(mock_info): function test_serialize_secret_encrypted_mode_with_cipher (line 97) | def test_serialize_secret_encrypted_mode_with_cipher(mock_info, cipher): function test_serialize_secret_encrypted_mode_without_cipher_raises_error (line 112) | def test_serialize_secret_encrypted_mode_without_cipher_raises_error( function test_serialize_secret_cipher_without_expose_mode_encrypts (line 121) | def test_serialize_secret_cipher_without_expose_mode_encrypts(mock_info,... function test_serialize_secret_cipher_with_plaintext_mode_returns_plaintext (line 131) | def test_serialize_secret_cipher_with_plaintext_mode_returns_plaintext( function test_serialize_secret_cipher_with_bool_true_returns_plaintext (line 142) | def test_serialize_secret_cipher_with_bool_true_returns_plaintext(mock_i... function test_validate_secret_none_returns_none (line 159) | def test_validate_secret_none_returns_none(mock_info): function test_validate_secret_invalid_type_int_raises_error (line 164) | def test_validate_secret_invalid_type_int_raises_error(mock_info): function test_validate_secret_invalid_type_dict_returns_none (line 174) | def test_validate_secret_invalid_type_dict_returns_none(mock_info): function test_validate_secret_invalid_type_list_returns_none (line 184) | def test_validate_secret_invalid_type_list_returns_none(mock_info): function test_validate_secret_nonempty_dict_raises_error (line 194) | def test_validate_secret_nonempty_dict_raises_error(mock_info): function test_validate_secret_nonempty_list_raises_error (line 200) | def test_validate_secret_nonempty_list_raises_error(mock_info): function test_validate_secret_string_returns_secretstr (line 206) | def test_validate_secret_string_returns_secretstr(mock_info): function test_validate_secret_secretstr_passthrough (line 212) | def test_validate_secret_secretstr_passthrough(mock_info): function test_validate_secret_empty_string_returns_none (line 219) | def test_validate_secret_empty_string_returns_none(mock_info): function test_validate_secret_whitespace_only_returns_none (line 224) | def test_validate_secret_whitespace_only_returns_none(mock_info): function test_validate_secret_redacted_value_returns_none (line 229) | def test_validate_secret_redacted_value_returns_none(mock_info): function test_validate_secret_with_cipher_decrypts (line 234) | def test_validate_secret_with_cipher_decrypts(mock_info, cipher): function test_validate_secret_with_cipher_invalid_data_returns_none (line 244) | def test_validate_secret_with_cipher_invalid_data_returns_none(mock_info... function test_validate_secret_with_cipher_wrong_key_returns_none (line 250) | def test_validate_secret_with_cipher_wrong_key_returns_none(mock_info, c... function test_roundtrip_encrypted_mode (line 267) | def test_roundtrip_encrypted_mode(mock_info, cipher): function test_roundtrip_plaintext_mode (line 283) | def test_roundtrip_plaintext_mode(mock_info): function test_real_pydantic_roundtrip_encrypted (line 300) | def test_real_pydantic_roundtrip_encrypted(cipher): function test_real_pydantic_roundtrip_plaintext (line 323) | def test_real_pydantic_roundtrip_plaintext(): function test_real_pydantic_redacted_mode (line 342) | def test_real_pydantic_redacted_mode(): function test_real_pydantic_nested_secrets_roundtrip (line 357) | def test_real_pydantic_nested_secrets_roundtrip(cipher): function test_real_pydantic_persisted_settings_roundtrip (line 394) | def test_real_pydantic_persisted_settings_roundtrip(cipher): FILE: tests/sdk/utils/test_redact.py class TestSensitiveUrlParams (line 14) | class TestSensitiveUrlParams: method test_is_frozenset (line 17) | def test_is_frozenset(self): method test_contains_expected_entries (line 20) | def test_contains_expected_entries(self): class TestRedactUrlParams (line 38) | class TestRedactUrlParams: method test_redacts_apikey_param (line 43) | def test_redacts_apikey_param(self): method test_redacts_api_key_param (line 50) | def test_redacts_api_key_param(self): method test_redacts_token_param (line 56) | def test_redacts_token_param(self): method test_redacts_access_token_param (line 62) | def test_redacts_access_token_param(self): method test_redacts_secret_param (line 67) | def test_redacts_secret_param(self): method test_redacts_key_param (line 73) | def test_redacts_key_param(self): method test_redacts_tavilyapikey_param (line 78) | def test_redacts_tavilyapikey_param(self): method test_case_insensitive_exact_match (line 86) | def test_case_insensitive_exact_match(self): method test_redacts_via_is_secret_key_pattern (line 96) | def test_redacts_via_is_secret_key_pattern(self): method test_redacts_x_api_key_via_pattern (line 104) | def test_redacts_x_api_key_via_pattern(self): method test_no_query_params (line 113) | def test_no_query_params(self): method test_empty_query_string (line 117) | def test_empty_query_string(self): method test_empty_string (line 123) | def test_empty_string(self): method test_non_url_string (line 126) | def test_non_url_string(self): method test_url_with_fragment (line 131) | def test_url_with_fragment(self): method test_url_with_port_and_path (line 137) | def test_url_with_port_and_path(self): method test_preserves_non_sensitive_params (line 144) | def test_preserves_non_sensitive_params(self): method test_multiple_sensitive_params (line 148) | def test_multiple_sensitive_params(self): method test_param_with_empty_value (line 156) | def test_param_with_empty_value(self): method test_param_with_multiple_values (line 162) | def test_param_with_multiple_values(self): method test_url_with_encoded_characters (line 171) | def test_url_with_encoded_characters(self): FILE: tests/sdk/utils/test_subclass_cache.py class _Base (line 23) | class _Base(DiscriminatedUnionMixin, ABC): class _ConcreteA (line 27) | class _ConcreteA(_Base): class _ConcreteB (line 31) | class _ConcreteB(_Base): class _CheckedBase (line 37) | class _CheckedBase(DiscriminatedUnionMixin, ABC): class _CheckedA (line 41) | class _CheckedA(_CheckedBase): function test_cache_hit (line 45) | def test_cache_hit(): function test_returns_tuple (line 52) | def test_returns_tuple(): function test_auto_invalidates_on_new_subclass (line 57) | def test_auto_invalidates_on_new_subclass(): function test_deep_hierarchy_invalidation (line 69) | def test_deep_hierarchy_invalidation(): function test_dynamic_type_invalidates_cache (line 90) | def test_dynamic_type_invalidates_cache(): function test_checked_cache_stays_in_sync (line 101) | def test_checked_cache_stays_in_sync(): function test_concurrent_subclass_creation (line 116) | def test_concurrent_subclass_creation(): FILE: tests/sdk/utils/test_truncate.py function test_maybe_truncate_no_limit (line 10) | def test_maybe_truncate_no_limit(): function test_maybe_truncate_under_limit (line 17) | def test_maybe_truncate_under_limit(): function test_maybe_truncate_over_limit (line 24) | def test_maybe_truncate_over_limit(): function test_maybe_truncate_custom_notice (line 42) | def test_maybe_truncate_custom_notice(): function test_maybe_truncate_exact_limit (line 63) | def test_maybe_truncate_exact_limit(): function test_default_limits (line 71) | def test_default_limits(): function test_maybe_truncate_empty_string (line 78) | def test_maybe_truncate_empty_string(): function test_maybe_truncate_zero_limit (line 84) | def test_maybe_truncate_zero_limit(): function test_maybe_truncate_head_and_tail (line 92) | def test_maybe_truncate_head_and_tail(): function test_maybe_truncate_notice_too_large (line 108) | def test_maybe_truncate_notice_too_large(): function test_maybe_truncate_file_deduplication (line 120) | def test_maybe_truncate_file_deduplication(tmp_path): function test_maybe_truncate_different_content_different_files (line 149) | def test_maybe_truncate_different_content_different_files(tmp_path): function test_maybe_truncate_same_content_different_prefix_different_files (line 183) | def test_maybe_truncate_same_content_different_prefix_different_files(tm... function test_maybe_truncate_hash_based_filename (line 215) | def test_maybe_truncate_hash_based_filename(tmp_path): function test_maybe_truncate_persist_notice_exceeds_limit (line 243) | def test_maybe_truncate_persist_notice_exceeds_limit(tmp_path): function test_maybe_truncate_persist_head_char_moves_since_remaining_less_than_proposed_head (line 261) | def test_maybe_truncate_persist_head_char_moves_since_remaining_less_tha... function test_maybe_truncate_persist_notice_leaves_minimal_room (line 283) | def test_maybe_truncate_persist_notice_leaves_minimal_room(tmp_path): function test_maybe_truncate_line_number_accuracy (line 303) | def test_maybe_truncate_line_number_accuracy(tmp_path): function test_maybe_truncate_short_content_with_persistence (line 326) | def test_maybe_truncate_short_content_with_persistence(tmp_path): function test_maybe_truncate_unicode_content_persistence (line 343) | def test_maybe_truncate_unicode_content_persistence(tmp_path): FILE: tests/sdk/utils/test_visualize.py function test_display_dict_with_dictionary (line 8) | def test_display_dict_with_dictionary(): function test_display_dict_with_nested_structures (line 23) | def test_display_dict_with_nested_structures(): function test_display_dict_with_list_now_works (line 41) | def test_display_dict_with_list_now_works(): function test_display_dict_with_string_now_works (line 54) | def test_display_dict_with_string_now_works(): function test_display_dict_with_number_now_works (line 64) | def test_display_dict_with_number_now_works(): function test_display_dict_with_boolean_now_works (line 74) | def test_display_dict_with_boolean_now_works(): function test_display_dict_with_none_now_works (line 84) | def test_display_dict_with_none_now_works(): function test_display_json_with_dictionary (line 97) | def test_display_json_with_dictionary(): function test_display_json_with_list (line 112) | def test_display_json_with_list(): function test_display_json_with_string (line 130) | def test_display_json_with_string(): function test_display_json_with_multiline_string (line 140) | def test_display_json_with_multiline_string(): function test_display_json_with_number (line 153) | def test_display_json_with_number(): function test_display_json_with_float (line 163) | def test_display_json_with_float(): function test_display_json_with_boolean (line 173) | def test_display_json_with_boolean(): function test_display_json_with_none (line 190) | def test_display_json_with_none(): function test_display_json_with_nested_structures (line 200) | def test_display_json_with_nested_structures(): function test_display_dict_backward_compatibility (line 218) | def test_display_dict_backward_compatibility(): FILE: tests/sdk/workspace/conftest.py function mock_httpx_client (line 14) | def mock_httpx_client(): function mock_httpx_async_client (line 20) | def mock_httpx_async_client(): function mock_httpx_response (line 26) | def mock_httpx_response(): function sample_command_result (line 36) | def sample_command_result(): function sample_file_operation_result (line 48) | def sample_file_operation_result(): function temp_file (line 60) | def temp_file(): function temp_dir (line 74) | def temp_dir(): FILE: tests/sdk/workspace/remote/test_async_remote_workspace.py function test_async_remote_workspace_initialization (line 14) | def test_async_remote_workspace_initialization(): function test_async_remote_workspace_initialization_without_api_key (line 24) | def test_async_remote_workspace_initialization_without_api_key(): function test_async_remote_workspace_host_normalization (line 34) | def test_async_remote_workspace_host_normalization(): function test_async_client_property_lazy_initialization (line 43) | def test_async_client_property_lazy_initialization(): function test_async_headers_property_with_api_key (line 61) | def test_async_headers_property_with_api_key(): function test_async_headers_property_without_api_key (line 71) | def test_async_headers_property_without_api_key(): function test_async_execute_method (line 82) | async def test_async_execute_method(): function test_async_execute_command (line 109) | async def test_async_execute_command(mock_execute): function test_async_file_upload (line 138) | async def test_async_file_upload(mock_execute): function test_async_file_download (line 166) | async def test_async_file_download(mock_execute): function test_async_execute_command_with_path_objects (line 191) | async def test_async_execute_command_with_path_objects(): function test_async_file_operations_with_path_objects (line 214) | async def test_async_file_operations_with_path_objects(): function test_async_inheritance (line 242) | def test_async_inheritance(): function test_async_execute_with_exception_handling (line 256) | async def test_async_execute_with_exception_handling(): function test_async_execute_generator_completion (line 279) | async def test_async_execute_generator_completion(): function test_async_execute_multiple_yields (line 308) | async def test_async_execute_multiple_yields(): function test_async_concurrent_operations (line 337) | async def test_async_concurrent_operations(): class MockHTTPResponse (line 382) | class MockHTTPResponse: method __init__ (line 385) | def __init__(self, status: int = 200): method __enter__ (line 388) | def __enter__(self): method __exit__ (line 391) | def __exit__(self, exc_type, exc_val, exc_tb): function test_async_alive_returns_true_on_successful_health_check (line 396) | def test_async_alive_returns_true_on_successful_health_check(mock_urlopen): function test_async_alive_returns_true_on_204_status (line 411) | def test_async_alive_returns_true_on_204_status(mock_urlopen): function test_async_alive_returns_false_on_server_error (line 425) | def test_async_alive_returns_false_on_server_error(mock_urlopen): function test_async_alive_returns_false_on_client_error (line 439) | def test_async_alive_returns_false_on_client_error(mock_urlopen): function test_async_alive_returns_false_on_connection_error (line 453) | def test_async_alive_returns_false_on_connection_error(mock_urlopen): function test_async_alive_returns_false_on_timeout (line 467) | def test_async_alive_returns_false_on_timeout(mock_urlopen): function test_async_alive_constructs_correct_health_url (line 483) | def test_async_alive_constructs_correct_health_url(mock_urlopen): function test_async_alive_with_normalized_host (line 499) | def test_async_alive_with_normalized_host(mock_urlopen): function test_async_alive_is_property (line 515) | def test_async_alive_is_property(): FILE: tests/sdk/workspace/remote/test_client_base_url.py function test_remote_workspace_client_has_base_url (line 15) | def test_remote_workspace_client_has_base_url(): function test_async_remote_workspace_client_has_base_url (line 25) | def test_async_remote_workspace_client_has_base_url(): FILE: tests/sdk/workspace/remote/test_multiple_commands_isolation.py class _RemoteWorkspaceMixinForTest (line 13) | class _RemoteWorkspaceMixinForTest(RemoteWorkspaceMixin): method __init__ (line 16) | def __init__(self, **kwargs): function test_multiple_commands_use_different_command_ids (line 20) | def test_multiple_commands_use_different_command_ids(): function test_command_id_filter_params_structure (line 81) | def test_command_id_filter_params_structure(): FILE: tests/sdk/workspace/remote/test_polling_duplicates_output.py class RemoteWorkspaceMixinHelper (line 29) | class RemoteWorkspaceMixinHelper(RemoteWorkspaceMixin): method __init__ (line 32) | def __init__(self, **kwargs): class TestPollingDeduplication (line 36) | class TestPollingDeduplication: method test_polling_should_not_duplicate_events_across_iterations (line 40) | def test_polling_should_not_duplicate_events_across_iterations(self, m... method test_base64_output_should_decode_correctly (line 128) | def test_base64_output_should_decode_correctly(self, mock_time): method test_base64_decode_succeeds_with_order_filtering (line 234) | def test_base64_decode_succeeds_with_order_filtering(self, mock_time): method test_assertion_fires_on_duplicate_events (line 343) | def test_assertion_fires_on_duplicate_events(self, mock_time): method test_single_poll_works_correctly (line 419) | def test_single_poll_works_correctly(self, mock_time): method test_mixed_event_types_with_kind_filtering (line 482) | def test_mixed_event_types_with_kind_filtering(self, mock_time): method test_bash_command_events_are_ignored (line 570) | def test_bash_command_events_are_ignored(self, mock_time): FILE: tests/sdk/workspace/remote/test_remote_workspace.py class MockHTTPResponse (line 13) | class MockHTTPResponse: method __init__ (line 16) | def __init__(self, status: int = 200): method __enter__ (line 19) | def __enter__(self): method __exit__ (line 22) | def __exit__(self, exc_type, exc_val, exc_tb): function test_remote_workspace_initialization (line 26) | def test_remote_workspace_initialization(): function test_remote_workspace_initialization_without_api_key (line 37) | def test_remote_workspace_initialization_without_api_key(): function test_remote_workspace_host_normalization (line 46) | def test_remote_workspace_host_normalization(): function test_client_property_lazy_initialization (line 53) | def test_client_property_lazy_initialization(): function test_headers_property_with_api_key (line 69) | def test_headers_property_with_api_key(): function test_headers_property_without_api_key (line 79) | def test_headers_property_without_api_key(): function test_execute_method (line 87) | def test_execute_method(): function test_execute_command (line 109) | def test_execute_command(mock_execute): function test_file_upload (line 133) | def test_file_upload(mock_execute): function test_file_download (line 156) | def test_file_download(mock_execute): function test_execute_command_with_path_objects (line 178) | def test_execute_command_with_path_objects(): function test_file_operations_with_path_objects (line 198) | def test_file_operations_with_path_objects(): function test_context_manager_protocol (line 224) | def test_context_manager_protocol(): function test_inheritance (line 237) | def test_inheritance(): function test_execute_with_exception_handling (line 250) | def test_execute_with_exception_handling(): function test_execute_generator_completion (line 270) | def test_execute_generator_completion(): function test_alive_returns_true_on_successful_health_check (line 297) | def test_alive_returns_true_on_successful_health_check(mock_urlopen): function test_alive_returns_true_on_204_status (line 310) | def test_alive_returns_true_on_204_status(mock_urlopen): function test_alive_returns_false_on_server_error (line 322) | def test_alive_returns_false_on_server_error(mock_urlopen): function test_alive_returns_false_on_client_error (line 334) | def test_alive_returns_false_on_client_error(mock_urlopen): function test_alive_returns_false_on_connection_error (line 346) | def test_alive_returns_false_on_connection_error(mock_urlopen): function test_alive_returns_false_on_timeout (line 358) | def test_alive_returns_false_on_timeout(mock_urlopen): function test_alive_constructs_correct_health_url (line 372) | def test_alive_constructs_correct_health_url(mock_urlopen): function test_alive_with_normalized_host (line 388) | def test_alive_with_normalized_host(mock_urlopen): function test_alive_is_property (line 402) | def test_alive_is_property(): function test_get_llm_returns_configured_llm (line 410) | def test_get_llm_returns_configured_llm(monkeypatch): function test_get_llm_with_kwargs_override (line 458) | def test_get_llm_with_kwargs_override(monkeypatch): function test_get_llm_raises_on_undefined_host (line 497) | def test_get_llm_raises_on_undefined_host(): function test_get_secrets_returns_lookup_secrets (line 505) | def test_get_secrets_returns_lookup_secrets(): function test_get_secrets_filters_by_names (line 539) | def test_get_secrets_filters_by_names(): function test_get_secrets_returns_empty_dict_when_no_secrets (line 567) | def test_get_secrets_returns_empty_dict_when_no_secrets(): function test_get_secrets_raises_on_undefined_host (line 583) | def test_get_secrets_raises_on_undefined_host(): function test_get_mcp_config_returns_config (line 591) | def test_get_mcp_config_returns_config(): function test_get_mcp_config_returns_empty_dict_when_no_config (line 628) | def test_get_mcp_config_returns_empty_dict_when_no_config(monkeypatch): function test_get_mcp_config_returns_empty_dict_when_mcp_config_is_none (line 649) | def test_get_mcp_config_returns_empty_dict_when_mcp_config_is_none(monke... function test_get_mcp_config_raises_on_undefined_host (line 670) | def test_get_mcp_config_raises_on_undefined_host(): function test_get_secret_value_returns_secret (line 681) | def test_get_secret_value_returns_secret(): function test_get_secret_value_returns_none_on_404 (line 703) | def test_get_secret_value_returns_none_on_404(): function test_get_secret_value_returns_none_when_host_undefined (line 722) | def test_get_secret_value_returns_none_when_host_undefined(): function test_get_secret_value_validates_secret_name (line 731) | def test_get_secret_value_validates_secret_name(): function test_clone_repos_calls_helper (line 745) | def test_clone_repos_calls_helper(): function test_clone_repos_normalizes_input_formats (line 777) | def test_clone_repos_normalizes_input_formats(): function test_clone_repos_uses_custom_target_dir (line 804) | def test_clone_repos_uses_custom_target_dir(): function test_get_repos_context_delegates_to_helper (line 824) | def test_get_repos_context_delegates_to_helper(): function test_get_repos_context_empty_mappings (line 848) | def test_get_repos_context_empty_mappings(): function test_load_skills_from_agent_server_raises_when_not_initialized (line 862) | def test_load_skills_from_agent_server_raises_when_not_initialized(): function test_load_skills_from_agent_server_calls_api (line 870) | def test_load_skills_from_agent_server_calls_api(): function test_load_skills_from_agent_server_falls_back_when_no_skills (line 903) | def test_load_skills_from_agent_server_falls_back_when_no_skills(): function test_load_skills_from_agent_server_with_project_dirs (line 920) | def test_load_skills_from_agent_server_with_project_dirs(): function test_register_conversation_stores_id (line 963) | def test_register_conversation_stores_id(): function test_conversation_id_property_returns_none_initially (line 973) | def test_conversation_id_property_returns_none_initially(): function test_send_completion_callback_on_success (line 980) | def test_send_completion_callback_on_success(monkeypatch): function test_send_completion_callback_on_failure (line 1011) | def test_send_completion_callback_on_failure(monkeypatch): function test_send_completion_callback_no_op_without_url (line 1037) | def test_send_completion_callback_no_op_without_url(monkeypatch): function test_send_completion_callback_swallows_errors (line 1048) | def test_send_completion_callback_swallows_errors(monkeypatch): function test_send_completion_callback_without_api_key (line 1065) | def test_send_completion_callback_without_api_key(monkeypatch): function test_send_completion_callback_includes_conversation_id (line 1088) | def test_send_completion_callback_includes_conversation_id(monkeypatch): function test_send_completion_callback_omits_conversation_id_when_not_registered (line 1114) | def test_send_completion_callback_omits_conversation_id_when_not_registe... FILE: tests/sdk/workspace/remote/test_remote_workspace_mixin.py class RemoteWorkspaceMixinHelper (line 12) | class RemoteWorkspaceMixinHelper(RemoteWorkspaceMixin): method __init__ (line 15) | def __init__(self, **kwargs): function test_remote_workspace_mixin_initialization (line 19) | def test_remote_workspace_mixin_initialization(): function test_remote_workspace_mixin_initialization_without_api_key (line 29) | def test_remote_workspace_mixin_initialization_without_api_key(): function test_host_normalization_in_post_init (line 39) | def test_host_normalization_in_post_init(): function test_headers_property_with_api_key (line 49) | def test_headers_property_with_api_key(): function test_headers_property_without_api_key (line 59) | def test_headers_property_without_api_key(): function test_execute_command_generator_basic_flow (line 69) | def test_execute_command_generator_basic_flow(): function test_execute_command_generator_without_cwd (line 118) | def test_execute_command_generator_without_cwd(): function test_execute_command_generator_with_path_cwd (line 131) | def test_execute_command_generator_with_path_cwd(): function test_execute_command_generator_polling_loop (line 146) | def test_execute_command_generator_polling_loop(mock_time, mock_sleep): function test_execute_command_generator_timeout (line 208) | def test_execute_command_generator_timeout(mock_time): function test_execute_command_generator_exception_handling (line 258) | def test_execute_command_generator_exception_handling(): function test_file_upload_generator_basic_flow (line 286) | def test_file_upload_generator_basic_flow(temp_file): function test_file_upload_generator_with_path_objects (line 321) | def test_file_upload_generator_with_path_objects(temp_file): function test_file_upload_generator_file_not_found (line 337) | def test_file_upload_generator_file_not_found(): function test_file_upload_generator_http_error (line 359) | def test_file_upload_generator_http_error(): function test_file_download_generator_basic_flow (line 386) | def test_file_download_generator_basic_flow(temp_dir): function test_file_download_generator_with_path_objects (line 424) | def test_file_download_generator_with_path_objects(temp_dir): function test_file_download_generator_creates_directories (line 442) | def test_file_download_generator_creates_directories(temp_dir): function test_file_download_generator_http_error (line 469) | def test_file_download_generator_http_error(): function test_multiple_bash_output_events (line 497) | def test_multiple_bash_output_events(): function test_non_bash_output_events_ignored (line 547) | def test_non_bash_output_events_ignored(): function test_start_bash_command_endpoint_used (line 591) | def test_start_bash_command_endpoint_used(): function test_git_changes_generator_uses_query_param_with_posix_paths (line 660) | def test_git_changes_generator_uses_query_param_with_posix_paths(): function test_git_diff_generator_uses_query_param_with_posix_paths (line 677) | def test_git_diff_generator_uses_query_param_with_posix_paths(): function test_git_changes_generator_preserves_absolute_paths (line 693) | def test_git_changes_generator_preserves_absolute_paths(): FILE: tests/tools/apply_patch/test_apply_patch_executor.py function tmp_ws (line 10) | def tmp_ws(tmp_path: Path) -> Path: function run_exec (line 15) | def run_exec(ws: Path, patch: str): function test_create_modify_delete (line 20) | def test_create_modify_delete(tmp_ws: Path): function test_reject_absolute_path (line 54) | def test_reject_absolute_path(tmp_ws: Path): function test_multi_hunk_success_single_file (line 67) | def test_multi_hunk_success_single_file(tmp_ws: Path): function test_multi_file_update_single_patch (line 90) | def test_multi_file_update_single_patch(tmp_ws: Path): function test_multi_file_add_update_delete_single_patch (line 117) | def test_multi_file_add_update_delete_single_patch(tmp_ws: Path): function test_multi_hunk_invalid_context_error (line 146) | def test_multi_hunk_invalid_context_error(tmp_ws: Path): function test_fuzz_matching_trailing_spaces (line 170) | def test_fuzz_matching_trailing_spaces(tmp_ws: Path): function test_delete_missing_file_expected_differror (line 191) | def test_delete_missing_file_expected_differror(tmp_ws: Path): function test_duplicate_add_file_error (line 206) | def test_duplicate_add_file_error(tmp_ws: Path): function test_path_escape_with_parent_directory (line 220) | def test_path_escape_with_parent_directory(tmp_ws: Path): FILE: tests/tools/browser_use/conftest.py function mock_browser_server (line 13) | def mock_browser_server(): function mock_browser_executor (line 23) | def mock_browser_executor(mock_browser_server): function create_mock_browser_response (line 35) | def create_mock_browser_response( function assert_browser_observation_success (line 48) | def assert_browser_observation_success( function assert_browser_observation_error (line 64) | def assert_browser_observation_error( FILE: tests/tools/browser_use/test_browser_cleanup.py class TestBrowserCleanup (line 10) | class TestBrowserCleanup: method mock_executor (line 14) | def mock_executor(self): method test_close_browser_when_initialized (line 39) | async def test_close_browser_when_initialized(self, mock_executor): method test_close_browser_when_not_initialized (line 50) | async def test_close_browser_when_not_initialized(self, mock_executor): method test_cleanup_calls_close_all_sessions (line 62) | async def test_cleanup_calls_close_all_sessions(self, mock_executor): method test_cleanup_falls_back_to_close_browser (line 70) | async def test_cleanup_falls_back_to_close_browser(self, mock_executor): method test_cleanup_with_close_all_sessions_exception (line 83) | async def test_cleanup_with_close_all_sessions_exception(self, mock_ex... method test_close_method_calls_cleanup (line 94) | def test_close_method_calls_cleanup(self, mock_executor): method test_close_method_handles_cleanup_exception (line 105) | def test_close_method_handles_cleanup_exception(self, mock_executor): method test_close_method_always_closes_async_executor (line 116) | def test_close_method_always_closes_async_executor(self, mock_executor): method test_del_method_calls_close (line 127) | def test_del_method_calls_close(self, mock_executor): method test_del_method_handles_close_exception (line 133) | def test_del_method_handles_close_exception(self, mock_executor): method test_close_method_timeout_configuration (line 141) | def test_close_method_timeout_configuration(self, mock_executor): method test_cleanup_not_initialized_browser (line 152) | async def test_cleanup_not_initialized_browser(self, mock_executor): FILE: tests/tools/browser_use/test_browser_executor.py class _ThreadedSlowServer (line 33) | class _ThreadedSlowServer(ThreadingHTTPServer): class SlowServiceBrowserExecutor (line 37) | class SlowServiceBrowserExecutor(BrowserToolExecutor): method __init__ (line 40) | def __init__(self, action_timeout_seconds: float): method navigate (line 50) | async def navigate(self, url: str, new_tab: bool = False) -> str: method close (line 54) | def close(self) -> None: method _fetch_url (line 58) | def _fetch_url(url: str) -> str: function slow_service (line 64) | def slow_service(): function test_browser_executor_initialization (line 97) | def test_browser_executor_initialization(): function test_browser_executor_config_passing (line 114) | def test_browser_executor_config_passing(): function test_browser_executor_rejects_non_positive_action_timeout (line 135) | def test_browser_executor_rejects_non_positive_action_timeout(): function test_browser_executor_action_routing_navigate (line 149) | async def test_browser_executor_action_routing_navigate( function test_browser_executor_action_routing_click (line 163) | async def test_browser_executor_action_routing_click(mock_click, mock_br... function test_browser_executor_action_routing_get_state (line 175) | async def test_browser_executor_action_routing_get_state( function test_browser_executor_unsupported_action_handling (line 191) | async def test_browser_executor_unsupported_action_handling(mock_browser... function test_browser_executor_error_wrapping (line 204) | async def test_browser_executor_error_wrapping(mock_navigate, mock_brows... function test_browser_executor_async_execution (line 215) | def test_browser_executor_async_execution(mock_browser_executor): function test_browser_executor_timeout_wrapping_live_service (line 230) | def test_browser_executor_timeout_wrapping_live_service(slow_service): function test_browser_executor_timeout_wrapping (line 245) | def test_browser_executor_timeout_wrapping(mock_browser_executor): function test_issue_2412_consecutive_failures_reset_session (line 261) | def test_issue_2412_consecutive_failures_reset_session(mock_browser_exec... function test_issue_2412_success_resets_failure_counter (line 299) | def test_issue_2412_success_resets_failure_counter(mock_browser_executor): function test_issue_2412_action_errors_do_not_trigger_reset (line 331) | def test_issue_2412_action_errors_do_not_trigger_reset(mock_browser_exec... function test_issue_2412_degraded_timeout_after_failures (line 358) | def test_issue_2412_degraded_timeout_after_failures(mock_browser_executor): function test_browser_executor_initialization_lazy (line 405) | async def test_browser_executor_initialization_lazy(mock_browser_executor): function test_browser_executor_initialization_idempotent (line 415) | async def test_browser_executor_initialization_idempotent(mock_browser_e... function test_start_recording_initializes_session (line 424) | async def test_start_recording_initializes_session(mock_browser_executor): function test_stop_recording_returns_summary_with_event_counts (line 467) | async def test_stop_recording_returns_summary_with_event_counts(): function test_stop_recording_without_active_session_returns_error (line 526) | async def test_stop_recording_without_active_session_returns_error(): FILE: tests/tools/browser_use/test_browser_executor_e2e.py function _has_chromium_for_e2e (line 111) | def _has_chromium_for_e2e() -> bool: function _get_free_port (line 122) | def _get_free_port() -> int: function _wait_for_test_server (line 128) | def _wait_for_test_server( function test_server (line 144) | def test_server() -> Generator[str]: function browser_executor (line 192) | def browser_executor() -> Generator[BrowserToolExecutor]: class TestBrowserExecutorE2E (line 214) | class TestBrowserExecutorE2E: method test_navigate_action (line 217) | def test_navigate_action( method test_get_state_action (line 229) | def test_get_state_action( method test_get_state_with_screenshot (line 252) | def test_get_state_with_screenshot( method test_click_action (line 269) | def test_click_action( method test_type_action (line 292) | def test_type_action(self, browser_executor: BrowserToolExecutor, test... method test_scroll_action (line 314) | def test_scroll_action( method test_get_content_action (line 336) | def test_get_content_action( method test_navigate_new_tab (line 362) | def test_navigate_new_tab( method test_list_tabs_action (line 373) | def test_list_tabs_action( method test_go_back_action (line 390) | def test_go_back_action( method test_switch_tab_action (line 410) | def test_switch_tab_action( method test_close_tab_action (line 438) | def test_close_tab_action( method test_error_handling (line 459) | def test_error_handling(self, browser_executor: BrowserToolExecutor): method test_executor_initialization_and_cleanup (line 469) | def test_executor_initialization_and_cleanup(self): method test_concurrent_actions (line 482) | def test_concurrent_actions( method test_get_storage_action (line 510) | def test_get_storage_action( method test_set_storage_action (line 577) | def test_set_storage_action( method test_save_screenshot (line 657) | def test_save_screenshot(self, test_server: str): method test_start_recording (line 709) | def test_start_recording( method test_stop_recording_without_start (line 724) | def test_stop_recording_without_start( method test_recording_captures_events (line 743) | def test_recording_captures_events( method test_recording_save_to_file (line 778) | def test_recording_save_to_file(self, test_server: str): FILE: tests/tools/browser_use/test_browser_initialization.py class TestBrowserInitialization (line 11) | class TestBrowserInitialization: method test_initialization_timeout_handling (line 14) | def test_initialization_timeout_handling(self): method test_initialization_custom_timeout (line 34) | def test_initialization_custom_timeout(self): method test_initialization_default_timeout (line 56) | def test_initialization_default_timeout(self): method test_initialization_config_passed_to_server (line 78) | def test_initialization_config_passed_to_server(self): method test_initialization_server_creation_with_timeout (line 115) | def test_initialization_server_creation_with_timeout(self): method test_initialization_async_executor_created (line 134) | def test_initialization_async_executor_created(self): method test_initialization_chromium_not_available (line 159) | def test_initialization_chromium_not_available(self): method test_call_method_delegates_to_async_executor (line 174) | def test_call_method_delegates_to_async_executor(self): method test_call_method_timeout_configuration (line 208) | def test_call_method_timeout_configuration(self): FILE: tests/tools/browser_use/test_browser_observation.py function test_browser_observation_basic_output (line 7) | def test_browser_observation_basic_output(): function test_browser_observation_with_error (line 16) | def test_browser_observation_with_error(): function test_browser_observation_with_screenshot (line 25) | def test_browser_observation_with_screenshot(): function test_browser_observation_to_llm_content_text_only (line 37) | def test_browser_observation_to_llm_content_text_only(): function test_browser_observation_to_llm_content_with_screenshot (line 47) | def test_browser_observation_to_llm_content_with_screenshot(): function test_browser_observation_to_llm_content_with_error (line 64) | def test_browser_observation_to_llm_content_with_error(): function test_browser_observation_output_truncation (line 76) | def test_browser_observation_output_truncation(): function test_browser_observation_screenshot_data_url_conversion (line 91) | def test_browser_observation_screenshot_data_url_conversion(): function test_browser_observation_empty_screenshot_handling (line 106) | def test_browser_observation_empty_screenshot_handling(): function test_browser_observation_mime_type_detection (line 117) | def test_browser_observation_mime_type_detection(): FILE: tests/tools/browser_use/test_browser_toolset.py function _reset_shared_executor (line 20) | def _reset_shared_executor(): function _mock_browser_executor_init (line 30) | def _mock_browser_executor_init(): function _create_test_conv_state (line 51) | def _create_test_conv_state(temp_dir: str) -> ConversationState: function test_browser_toolset_create_returns_list (line 62) | def test_browser_toolset_create_returns_list(): function test_browser_toolset_create_includes_all_browser_tools (line 76) | def test_browser_toolset_create_includes_all_browser_tools(): function test_browser_toolset_create_tools_have_shared_executor (line 111) | def test_browser_toolset_create_tools_have_shared_executor(): function test_browser_toolset_create_tools_are_properly_configured (line 127) | def test_browser_toolset_create_tools_are_properly_configured(): function test_browser_toolset_create_multiple_calls_share_executor (line 147) | def test_browser_toolset_create_multiple_calls_share_executor(): function test_browser_toolset_shared_executor_survives_multiple_subagents (line 168) | def test_browser_toolset_shared_executor_survives_multiple_subagents(): function test_browser_toolset_shared_executor_reset (line 185) | def test_browser_toolset_shared_executor_reset(): function test_browser_toolset_warns_when_config_ignored (line 202) | def test_browser_toolset_warns_when_config_ignored(caplog): function test_browser_toolset_no_warning_when_no_config (line 222) | def test_browser_toolset_no_warning_when_no_config(caplog): function test_browser_toolset_create_tools_can_generate_mcp_schema (line 239) | def test_browser_toolset_create_tools_can_generate_mcp_schema(): function test_browser_toolset_create_no_parameters (line 261) | def test_browser_toolset_create_no_parameters(): function test_browser_toolset_inheritance (line 270) | def test_browser_toolset_inheritance(): FILE: tests/tools/browser_use/test_chromium_detection.py function clear_chromium_detection_cache (line 13) | def clear_chromium_detection_cache(): class TestChromiumDetection (line 19) | class TestChromiumDetection: method test_check_chromium_available_system_binary (line 22) | def test_check_chromium_available_system_binary(self): method test_check_chromium_available_is_cached (line 32) | def test_check_chromium_available_is_cached(self): method test_check_chromium_available_multiple_binaries (line 44) | def test_check_chromium_available_multiple_binaries(self): method test_check_chromium_available_chrome_binary (line 61) | def test_check_chromium_available_chrome_binary(self): method test_check_chromium_available_standard_linux_path (line 78) | def test_check_chromium_available_standard_linux_path(self): method test_check_chromium_available_standard_macos_path (line 94) | def test_check_chromium_available_standard_macos_path(self): method test_check_chromium_available_standard_windows_edge_path (line 112) | def test_check_chromium_available_standard_windows_edge_path(self): method test_check_chromium_available_playwright_linux (line 138) | def test_check_chromium_available_playwright_linux(self): method test_check_chromium_available_playwright_macos (line 160) | def test_check_chromium_available_playwright_macos(self): method test_check_chromium_available_playwright_windows (line 189) | def test_check_chromium_available_playwright_windows(self): method test_check_chromium_available_not_found (line 217) | def test_check_chromium_available_not_found(self): method test_check_chromium_available_playwright_cache_not_found (line 229) | def test_check_chromium_available_playwright_cache_not_found(self): class TestChromiumInstallation (line 242) | class TestChromiumInstallation: method test_install_chromium_success (line 245) | def test_install_chromium_success(self): method test_install_chromium_uvx_not_found (line 257) | def test_install_chromium_uvx_not_found(self): method test_install_chromium_subprocess_failure (line 263) | def test_install_chromium_subprocess_failure(self): method test_install_chromium_timeout (line 276) | def test_install_chromium_timeout(self): method test_install_chromium_file_not_found (line 285) | def test_install_chromium_file_not_found(self): method test_install_chromium_generic_exception (line 294) | def test_install_chromium_generic_exception(self): class TestEnsureChromiumAvailable (line 304) | class TestEnsureChromiumAvailable: method test_ensure_chromium_available_already_available (line 307) | def test_ensure_chromium_available_already_available(self): method test_ensure_chromium_available_not_found_raises_error (line 316) | def test_ensure_chromium_available_not_found_raises_error(self): FILE: tests/tools/browser_use/test_recording_flush.py function mock_cdp_session (line 28) | def mock_cdp_session(): function mock_browser_session (line 40) | def mock_browser_session(mock_cdp_session): function server_with_mock_browser (line 48) | def server_with_mock_browser(mock_browser_session): function recording_session_with_mock_browser (line 56) | def recording_session_with_mock_browser(mock_browser_session): function create_mock_events (line 61) | def create_mock_events(count: int, size_per_event: int = 100) -> list[di... class TestEventStorage (line 77) | class TestEventStorage: method test_save_events_creates_file (line 80) | def test_save_events_creates_file(self): method test_save_events_updates_counters (line 95) | def test_save_events_updates_counters(self): method test_save_events_returns_none_without_session_dir (line 109) | def test_save_events_returns_none_without_session_dir(self): method test_save_events_returns_none_for_empty_events (line 115) | def test_save_events_returns_none_for_empty_events(self): method test_reset_clears_state (line 123) | def test_reset_clears_state(self): class TestPeriodicFlush (line 140) | class TestPeriodicFlush: method test_periodic_flush_creates_new_file_chunks (line 144) | async def test_periodic_flush_creates_new_file_chunks( method test_periodic_flush_interval_is_configurable (line 216) | async def test_periodic_flush_interval_is_configurable(self): class TestConcurrentFlushSafety (line 222) | class TestConcurrentFlushSafety: method test_concurrent_flushes_do_not_corrupt_event_buffer (line 226) | async def test_concurrent_flushes_do_not_corrupt_event_buffer( method test_periodic_flush_creates_timestamped_files (line 260) | async def test_periodic_flush_creates_timestamped_files( class TestRecordingIsolation (line 315) | class TestRecordingIsolation: method test_multiple_recordings_create_separate_subfolders (line 319) | async def test_multiple_recordings_create_separate_subfolders( class TestFileCountAccuracy (line 402) | class TestFileCountAccuracy: method test_file_count_accurate_with_existing_files (line 406) | async def test_file_count_accurate_with_existing_files(self): method test_file_count_zero_when_no_events (line 434) | async def test_file_count_zero_when_no_events(self): method test_file_count_matches_actual_files_written (line 445) | async def test_file_count_matches_actual_files_written(self): FILE: tests/tools/browser_use/test_vnc_integration.py function _mock_browser_available (line 12) | def _mock_browser_available(): class TestVNCIntegration (line 21) | class TestVNCIntegration: method test_vnc_disabled_headless_mode_preserved (line 24) | def test_vnc_disabled_headless_mode_preserved(self): method test_vnc_disabled_non_headless_mode_preserved (line 30) | def test_vnc_disabled_non_headless_mode_preserved(self): method test_vnc_enabled_forces_non_headless_mode_from_true (line 36) | def test_vnc_enabled_forces_non_headless_mode_from_true(self): method test_vnc_enabled_preserves_non_headless_mode_from_false (line 42) | def test_vnc_enabled_preserves_non_headless_mode_from_false(self): method test_vnc_enabled_various_true_values (line 51) | def test_vnc_enabled_various_true_values(self, env_value): method test_vnc_disabled_various_false_values (line 60) | def test_vnc_disabled_various_false_values(self, env_value): method test_vnc_not_set_defaults_to_disabled (line 66) | def test_vnc_not_set_defaults_to_disabled(self): method test_vnc_enabled_logs_message (line 77) | def test_vnc_enabled_logs_message(self): method test_vnc_disabled_no_log_message (line 88) | def test_vnc_disabled_no_log_message(self): method test_vnc_config_with_other_parameters (line 103) | def test_vnc_config_with_other_parameters(self): method test_vnc_environment_variable_case_insensitive (line 117) | def test_vnc_environment_variable_case_insensitive(self): FILE: tests/tools/delegate/test_delegation.py function create_test_executor_and_parent (line 30) | def create_test_executor_and_parent(): function create_mock_conversation (line 51) | def create_mock_conversation(): function test_delegate_action_creation (line 59) | def test_delegate_action_creation(): function test_delegate_observation_creation (line 80) | def test_delegate_observation_creation(): function test_delegate_executor_delegate (line 114) | def test_delegate_executor_delegate(): function test_delegate_executor_missing_task (line 150) | def test_delegate_executor_missing_task(): function test_delegation_manager_init (line 170) | def test_delegation_manager_init(): function test_spawn_disables_streaming_for_sub_agents (line 185) | def test_spawn_disables_streaming_for_sub_agents(): function test_spawn_gives_sub_agents_independent_metrics (line 228) | def test_spawn_gives_sub_agents_independent_metrics(): function test_delegate_merges_metrics_into_parent (line 264) | def test_delegate_merges_metrics_into_parent(): function test_repeated_delegation_does_not_double_count (line 343) | def test_repeated_delegation_does_not_double_count(): function test_issue_2216 (line 400) | def test_issue_2216(): function test_spawn_passes_hook_config_to_sub_conversation (line 433) | def test_spawn_passes_hook_config_to_sub_conversation(): function test_spawn_inherits_persistence_dir_from_parent (line 495) | def test_spawn_inherits_persistence_dir_from_parent(): function test_spawn_no_persistence_when_parent_has_none (line 530) | def test_spawn_no_persistence_when_parent_has_none(): function test_delegate_tool_create_emits_deprecation_warning (line 556) | def test_delegate_tool_create_emits_deprecation_warning(): FILE: tests/tools/delegate/test_visualizer.py class MockDelegateAction (line 13) | class MockDelegateAction(Action): class MockDelegateObservation (line 19) | class MockDelegateObservation(Observation): function create_tool_call (line 25) | def create_tool_call( function test_delegation_visualizer_user_message_without_sender (line 37) | def test_delegation_visualizer_user_message_without_sender(): function test_delegation_visualizer_user_message_with_sender (line 54) | def test_delegation_visualizer_user_message_with_sender(): function test_delegation_visualizer_agent_response_to_user (line 77) | def test_delegation_visualizer_agent_response_to_user(): function test_delegation_visualizer_agent_response_to_delegator (line 96) | def test_delegation_visualizer_agent_response_to_delegator(): function test_delegation_visualizer_formats_agent_names (line 126) | def test_delegation_visualizer_formats_agent_names(): function test_delegation_visualizer_action_event (line 164) | def test_delegation_visualizer_action_event(): function test_delegation_visualizer_observation_event (line 191) | def test_delegation_visualizer_observation_event(): function test_delegation_visualizer_create_sub_visualizer (line 216) | def test_delegation_visualizer_create_sub_visualizer(): function test_delegation_visualizer_create_sub_visualizer_with_defaults (line 236) | def test_delegation_visualizer_create_sub_visualizer_with_defaults(): FILE: tests/tools/file_editor/conftest.py function temp_file (line 14) | def temp_file(): function temp_dir (line 29) | def temp_dir(): function editor (line 36) | def editor(): function editor_with_test_file (line 42) | def editor_with_test_file(tmp_path): function editor_python_file_with_tabs (line 51) | def editor_python_file_with_tabs(tmp_path): function assert_successful_result (line 59) | def assert_successful_result( function assert_error_result (line 69) | def assert_error_result( function create_test_file (line 84) | def create_test_file(path: Path, content: str): FILE: tests/tools/file_editor/test_basic_operations.py function editor (line 29) | def editor(tmp_path): function editor_python_file_with_tabs (line 38) | def editor_python_file_with_tabs(tmp_path): function test_file_editor_happy_path (line 46) | def test_file_editor_happy_path(temp_file): function test_file_editor_view_operation (line 87) | def test_file_editor_view_operation(temp_file): function test_successful_operations (line 121) | def test_successful_operations(temp_file): function test_tab_expansion (line 171) | def test_tab_expansion(temp_file): function test_create_operation (line 219) | def test_create_operation(temp_file): function test_view_operation_truncation (line 243) | def test_view_operation_truncation(temp_file): function test_view_file (line 277) | def test_view_file(editor): function test_view_directory (line 287) | def test_view_directory(editor): function test_view_with_a_specific_range (line 300) | def test_view_with_a_specific_range(editor): function test_create_file (line 327) | def test_create_file(editor): function test_create_with_empty_string (line 336) | def test_create_with_empty_string(editor): function test_create_with_none_file_text (line 350) | def test_create_with_none_file_text(editor): function test_str_replace_no_linting (line 358) | def test_str_replace_no_linting(editor): function test_str_replace_multi_line_no_linting (line 381) | def test_str_replace_multi_line_no_linting(editor): function test_str_replace_multi_line_with_tabs_no_linting (line 401) | def test_str_replace_multi_line_with_tabs_no_linting(editor_python_file_... function test_str_replace_error_multiple_occurrences (line 420) | def test_str_replace_error_multiple_occurrences(editor): function test_str_replace_error_multiple_multiline_occurrences (line 430) | def test_str_replace_error_multiple_multiline_occurrences(editor): function test_str_replace_nonexistent_string (line 451) | def test_str_replace_nonexistent_string(editor): function test_str_replace_with_empty_new_str (line 466) | def test_str_replace_with_empty_new_str(editor): function test_str_replace_with_empty_old_str (line 479) | def test_str_replace_with_empty_old_str(editor): function test_str_replace_with_none_old_str (line 495) | def test_str_replace_with_none_old_str(editor): function test_insert_no_linting (line 507) | def test_insert_no_linting(editor): function test_insert_invalid_line (line 524) | def test_insert_invalid_line(editor): function test_insert_with_empty_string (line 539) | def test_insert_with_empty_string(editor): function test_insert_chinese_text_into_english_file (line 553) | def test_insert_chinese_text_into_english_file(editor): function test_insert_with_none_new_str (line 573) | def test_insert_with_none_new_str(editor): function test_undo_edit (line 585) | def test_undo_edit(editor): function test_multiple_undo_edits (line 601) | def test_multiple_undo_edits(editor): function test_validate_path_invalid (line 630) | def test_validate_path_invalid(editor): function test_create_existing_file_error (line 637) | def test_create_existing_file_error(editor): function test_str_replace_missing_old_str (line 643) | def test_str_replace_missing_old_str(editor): function test_str_replace_new_str_and_old_str_same (line 649) | def test_str_replace_new_str_and_old_str_same(editor): function test_insert_missing_line_param (line 664) | def test_insert_missing_line_param(editor): function test_undo_edit_no_history_error (line 670) | def test_undo_edit_no_history_error(editor): function test_view_directory_with_hidden_files (line 678) | def test_view_directory_with_hidden_files(tmp_path): function test_view_symlinked_directory (line 714) | def test_view_symlinked_directory(tmp_path): function test_view_large_directory_with_truncation (line 744) | def test_view_large_directory_with_truncation(editor, tmp_path): function test_view_directory_on_hidden_path (line 757) | def test_view_directory_on_hidden_path(tmp_path): function test_view_large_file_with_truncation (line 815) | def test_view_large_file_with_truncation(editor, tmp_path): function test_validate_path_suggests_absolute_path (line 827) | def test_validate_path_suggests_absolute_path(editor, tmp_path): function test_str_replace_and_insert_snippet_output_on_a_large_file (line 853) | def test_str_replace_and_insert_snippet_output_on_a_large_file(editor): FILE: tests/tools/file_editor/test_error_handling.py function test_validation_error_formatting (line 16) | def test_validation_error_formatting(tmp_path): function test_create_rejects_foreign_platform_absolute_paths (line 38) | def test_create_rejects_foreign_platform_absolute_paths(tmp_path, monkey... function test_str_replace_error_handling (line 48) | def test_str_replace_error_handling(temp_file): function test_view_range_validation (line 80) | def test_view_range_validation(temp_file): function test_insert_validation (line 119) | def test_insert_validation(temp_file): function test_undo_validation (line 147) | def test_undo_validation(temp_file): function test_view_directory_permission_error_returns_error_observation (line 163) | def test_view_directory_permission_error_returns_error_observation(): function test_view_subdirectory_permission_error_skips_inaccessible_dir (line 178) | def test_view_subdirectory_permission_error_skips_inaccessible_dir(): FILE: tests/tools/file_editor/test_exceptions.py function test_tool_error (line 10) | def test_tool_error(): function test_editor_tool_parameter_missing_error (line 17) | def test_editor_tool_parameter_missing_error(): function test_editor_tool_parameter_invalid_error_with_hint (line 31) | def test_editor_tool_parameter_invalid_error_with_hint(): function test_editor_tool_parameter_invalid_error_without_hint (line 43) | def test_editor_tool_parameter_invalid_error_without_hint(): FILE: tests/tools/file_editor/test_file_editor_tool.py function _create_test_conv_state (line 23) | def _create_test_conv_state(temp_dir: str) -> ConversationState: function test_file_editor_tool_initialization (line 34) | def test_file_editor_tool_initialization(): function test_file_editor_tool_create_file (line 47) | def test_file_editor_tool_create_file(): function test_file_editor_tool_view_file (line 78) | def test_file_editor_tool_view_file(): function test_file_editor_tool_str_replace (line 106) | def test_file_editor_tool_str_replace(): function test_file_editor_tool_to_openai_tool (line 141) | def test_file_editor_tool_to_openai_tool(): function test_file_editor_tool_view_directory (line 158) | def test_file_editor_tool_view_directory(): function test_file_editor_tool_includes_working_directory_in_description (line 188) | def test_file_editor_tool_includes_working_directory_in_description(): function test_file_editor_tool_openai_format_includes_working_directory (line 209) | def test_file_editor_tool_openai_format_includes_working_directory(): function test_declared_resources_locks_on_file_path (line 233) | def test_declared_resources_locks_on_file_path(command): function test_declared_resources_different_paths_produce_different_keys (line 244) | def test_declared_resources_different_paths_produce_different_keys(): function test_declared_resources_same_path_same_key_across_commands (line 256) | def test_declared_resources_same_path_same_key_across_commands(): function test_declared_resources_normalizes_dotdot_paths (line 266) | def test_declared_resources_normalizes_dotdot_paths(): function test_declared_resources_normalizes_dot_paths (line 277) | def test_declared_resources_normalizes_dot_paths(): function test_declared_resources_normalizes_relative_paths (line 286) | def test_declared_resources_normalizes_relative_paths(): function test_file_editor_tool_image_viewing_line_with_vision_enabled (line 295) | def test_file_editor_tool_image_viewing_line_with_vision_enabled(): function test_file_editor_tool_image_viewing_line_with_vision_disabled (line 320) | def test_file_editor_tool_image_viewing_line_with_vision_disabled(): FILE: tests/tools/file_editor/test_file_validation.py function test_validate_large_file (line 13) | def test_validate_large_file(tmp_path): function test_validate_binary_file (line 29) | def test_validate_binary_file(tmp_path): function test_validate_text_file (line 43) | def test_validate_text_file(tmp_path): function test_validate_directory (line 56) | def test_validate_directory(): function test_validate_nonexistent_file (line 63) | def test_validate_nonexistent_file(): function test_validate_pdf_file (line 71) | def test_validate_pdf_file(tmp_path): function test_validate_image_file (line 88) | def test_validate_image_file(tmp_path): function test_view_image_file_returns_image_content (line 104) | def test_view_image_file_returns_image_content(tmp_path): FILE: tests/tools/file_editor/test_memory_usage.py function isolate_memory_usage_tests (line 28) | def isolate_memory_usage_tests(): function test_file_read_memory_usage (line 35) | def test_file_read_memory_usage(temp_file): function test_file_editor_memory_leak (line 113) | def test_file_editor_memory_leak(temp_file): FILE: tests/tools/file_editor/test_schema.py function test_to_mcp_tool_detailed_type_validation_editor (line 4) | def test_to_mcp_tool_detailed_type_validation_editor(mock_conversation_s... FILE: tests/tools/file_editor/test_view_supported_binary_files.py function test_view_simple_pdf_file (line 10) | def test_view_simple_pdf_file(): function test_view_binary_pdf_file_returns_error (line 88) | def test_view_binary_pdf_file_returns_error(): FILE: tests/tools/file_editor/test_visualize_diff.py function test_visualize_diff_simple_replacement (line 12) | def test_visualize_diff_simple_replacement(): function test_visualize_diff_no_changes (line 46) | def test_visualize_diff_no_changes(): function test_visualize_diff_multiple_changes (line 73) | def test_visualize_diff_multiple_changes(): function test_visualize_diff_attempted_edit (line 118) | def test_visualize_diff_attempted_edit(): function test_visualize_diff_caching (line 146) | def test_visualize_diff_caching(): function test_visualize_diff_custom_context_lines (line 174) | def test_visualize_diff_custom_context_lines(): function test_get_edit_groups (line 224) | def test_get_edit_groups(): function test_get_edit_groups_no_content (line 256) | def test_get_edit_groups_no_content(): function test_visualize_diff_none_content (line 280) | def test_visualize_diff_none_content(): FILE: tests/tools/file_editor/test_workspace_root.py function test_workspace_root_as_cwd (line 11) | def test_workspace_root_as_cwd(tmp_path): function test_relative_workspace_root_do_not_raises_error (line 49) | def test_relative_workspace_root_do_not_raises_error(tmp_path, monkeypat... function test_suggestion_when_no_workspace_root (line 63) | def test_suggestion_when_no_workspace_root(tmp_path, monkeypatch): FILE: tests/tools/file_editor/utils/test_encoding.py function temp_file (line 20) | def temp_file(): function encoding_manager (line 32) | def encoding_manager(): function test_init (line 37) | def test_init(encoding_manager): function test_detect_encoding_nonexistent_file (line 45) | def test_detect_encoding_nonexistent_file(encoding_manager): function test_detect_encoding_utf8 (line 52) | def test_detect_encoding_utf8(encoding_manager, temp_file): function test_detect_encoding_utf8_with_icon (line 62) | def test_detect_encoding_utf8_with_icon(encoding_manager, temp_file): function test_detect_encoding_cp1251 (line 72) | def test_detect_encoding_cp1251(encoding_manager, temp_file): function test_detect_encoding_low_confidence (line 82) | def test_detect_encoding_low_confidence(encoding_manager, temp_file): function test_detect_encoding_none_result (line 97) | def test_detect_encoding_none_result(encoding_manager, temp_file): function test_get_encoding_cache_hit (line 110) | def test_get_encoding_cache_hit(encoding_manager, temp_file): function test_get_encoding_cache_invalidation (line 133) | def test_get_encoding_cache_invalidation(encoding_manager, temp_file): function test_with_encoding_decorator (line 159) | def test_with_encoding_decorator(): function test_with_encoding_respects_provided_encoding (line 201) | def test_with_encoding_respects_provided_encoding(): function test_cache_size_limit (line 229) | def test_cache_size_limit(encoding_manager, temp_file): function temp_non_utf8_file (line 261) | def temp_non_utf8_file(): function test_view_non_utf8_file (line 278) | def test_view_non_utf8_file(temp_non_utf8_file): function test_view_range_non_utf8_file (line 295) | def test_view_range_non_utf8_file(temp_non_utf8_file): function test_str_replace_non_utf8_file (line 315) | def test_str_replace_non_utf8_file(temp_non_utf8_file): function test_insert_non_utf8_file (line 343) | def test_insert_non_utf8_file(temp_non_utf8_file): function test_create_non_utf8_file (line 370) | def test_create_non_utf8_file(): function test_undo_edit_non_utf8_file (line 414) | def test_undo_edit_non_utf8_file(temp_non_utf8_file): function test_complex_workflow_non_utf8_file (line 448) | def test_complex_workflow_non_utf8_file(temp_non_utf8_file): function test_mixed_encoding_workflow (line 508) | def test_mixed_encoding_workflow(): FILE: tests/tools/file_editor/utils/test_file_cache.py function file_cache (line 11) | def file_cache(): function test_init (line 18) | def test_init(file_cache): function test_set_and_get (line 24) | def test_set_and_get(file_cache): function test_get_nonexistent_key (line 29) | def test_get_nonexistent_key(file_cache): function test_set_nested_key (line 34) | def test_set_nested_key(file_cache): function test_set_overwrite (line 39) | def test_set_overwrite(file_cache): function test_delete (line 45) | def test_delete(file_cache): function test_delete_nonexistent_key (line 51) | def test_delete_nonexistent_key(file_cache): function test_delete_nested_key (line 55) | def test_delete_nested_key(file_cache): function test_clear (line 61) | def test_clear(file_cache): function test_contains (line 72) | def test_contains(file_cache): function test_len (line 78) | def test_len(file_cache): function test_iter (line 87) | def test_iter(file_cache): function test_large_value (line 99) | def test_large_value(file_cache): function test_many_items (line 105) | def test_many_items(file_cache): function test_nested_structure (line 114) | def test_nested_structure(file_cache): function test_clear_nested_structure (line 125) | def test_clear_nested_structure(file_cache): function test_delete_removes_empty_directories (line 136) | def test_delete_removes_empty_directories(file_cache): function test_size_limit (line 144) | def test_size_limit(): function test_file_permissions (line 164) | def test_file_permissions(file_cache): function test_unicode_keys_and_values (line 173) | def test_unicode_keys_and_values(file_cache): function test_empty_string_as_key_and_value (line 180) | def test_empty_string_as_key_and_value(file_cache): function test_none_as_value (line 185) | def test_none_as_value(file_cache): function test_special_characters_in_key (line 190) | def test_special_characters_in_key(file_cache): function test_size_limit_with_empty_key (line 196) | def test_size_limit_with_empty_key(): FILE: tests/tools/file_editor/utils/test_history.py function test_default_history_limit (line 11) | def test_default_history_limit(): function test_history_keys_are_unique (line 29) | def test_history_keys_are_unique(): function test_history_counter_persists (line 59) | def test_history_counter_persists(): function test_clear_history_resets_counter (line 83) | def test_clear_history_resets_counter(): function test_pop_last_history_removes_entry (line 107) | def test_pop_last_history_removes_entry(): FILE: tests/tools/file_editor/utils/test_shell_utils.py function test_run_shell_cmd_success (line 18) | def test_run_shell_cmd_success(): function test_run_shell_cmd_timeout (line 29) | def test_run_shell_cmd_timeout(mock_popen): function test_run_shell_cmd_truncation (line 42) | def test_run_shell_cmd_truncation(mock_popen): function test_check_tool_installed_python (line 57) | def test_check_tool_installed_python(): function test_check_tool_installed_nonexistent_tool (line 63) | def test_check_tool_installed_nonexistent_tool(): FILE: tests/tools/gemini/conftest.py function fake_conv_state (line 9) | def fake_conv_state(tmp_path): FILE: tests/tools/gemini/edit/test_edit.py function test_edit_basic_replacement (line 9) | def test_edit_basic_replacement(tmp_path): function test_edit_multiple_replacements (line 25) | def test_edit_multiple_replacements(tmp_path): function test_edit_mismatch_expected_count (line 44) | def test_edit_mismatch_expected_count(tmp_path): function test_edit_create_new_file (line 63) | def test_edit_create_new_file(tmp_path): function test_edit_create_existing_file_error (line 81) | def test_edit_create_existing_file_error(tmp_path): function test_edit_string_not_found (line 97) | def test_edit_string_not_found(tmp_path): function test_edit_identical_strings (line 113) | def test_edit_identical_strings(tmp_path): function test_edit_file_not_found (line 127) | def test_edit_file_not_found(tmp_path): function test_edit_multiline_replacement (line 137) | def test_edit_multiline_replacement(tmp_path): function test_declared_resources_locks_on_file_path (line 155) | def test_declared_resources_locks_on_file_path(fake_conv_state): function test_declared_resources_different_files_different_keys (line 166) | def test_declared_resources_different_files_different_keys(fake_conv_sta... function test_declared_resources_relative_path_resolves_against_workspace (line 178) | def test_declared_resources_relative_path_resolves_against_workspace(fak... FILE: tests/tools/gemini/list_directory/test_list_directory.py function test_list_directory_basic (line 16) | def test_list_directory_basic(tmp_path): function test_list_directory_empty (line 42) | def test_list_directory_empty(tmp_path): function test_list_directory_recursive (line 56) | def test_list_directory_recursive(tmp_path): function test_list_directory_not_found (line 84) | def test_list_directory_not_found(tmp_path): function test_list_directory_not_a_directory (line 94) | def test_list_directory_not_a_directory(tmp_path): function test_list_directory_file_metadata (line 107) | def test_list_directory_file_metadata(tmp_path): function test_list_directory_absolute_path (line 127) | def test_list_directory_absolute_path(tmp_path): function test_list_directory_declared_resources (line 155) | def test_list_directory_declared_resources(tmp_path, dir_path, recursive): function test_list_directory_executor_concurrent (line 173) | def test_list_directory_executor_concurrent(tmp_path): FILE: tests/tools/gemini/read_file/test_read_file.py function test_read_file_basic (line 9) | def test_read_file_basic(tmp_path): function test_read_file_with_offset (line 28) | def test_read_file_with_offset(tmp_path): function test_read_file_truncation (line 47) | def test_read_file_truncation(tmp_path): function test_read_file_not_found (line 65) | def test_read_file_not_found(tmp_path): function test_read_file_directory (line 75) | def test_read_file_directory(tmp_path): function test_read_file_absolute_path (line 89) | def test_read_file_absolute_path(tmp_path): function test_read_file_offset_beyond_length (line 102) | def test_read_file_offset_beyond_length(tmp_path): function test_declared_resources_locks_on_file_path (line 115) | def test_declared_resources_locks_on_file_path(fake_conv_state): function test_declared_resources_different_files_different_keys (line 126) | def test_declared_resources_different_files_different_keys(fake_conv_sta... function test_declared_resources_relative_path_resolves_against_workspace (line 134) | def test_declared_resources_relative_path_resolves_against_workspace(fak... FILE: tests/tools/gemini/test_cross_tool_locking.py function test_gemini_and_file_editor_produce_same_key (line 14) | def test_gemini_and_file_editor_produce_same_key(fake_conv_state): FILE: tests/tools/gemini/write_file/test_write_file.py function test_write_file_create_new (line 9) | def test_write_file_create_new(tmp_path): function test_write_file_overwrite_existing (line 26) | def test_write_file_overwrite_existing(tmp_path): function test_write_file_create_directories (line 45) | def test_write_file_create_directories(tmp_path): function test_write_file_directory_error (line 59) | def test_write_file_directory_error(tmp_path): function test_write_file_absolute_path (line 73) | def test_write_file_absolute_path(tmp_path): function test_write_file_empty_content (line 86) | def test_write_file_empty_content(tmp_path): function test_declared_resources_locks_on_file_path (line 98) | def test_declared_resources_locks_on_file_path(fake_conv_state): function test_declared_resources_different_files_different_keys (line 109) | def test_declared_resources_different_files_different_keys(fake_conv_sta... function test_declared_resources_relative_path_resolves_against_workspace (line 117) | def test_declared_resources_relative_path_resolves_against_workspace(fak... FILE: tests/tools/glob/test_consistency.py class TestGlobConsistency (line 17) | class TestGlobConsistency: method temp_dir_with_files (line 21) | def temp_dir_with_files(self): method test_basic_pattern_consistency (line 104) | def test_basic_pattern_consistency(self, temp_dir_with_files): method test_recursive_pattern_consistency (line 129) | def test_recursive_pattern_consistency(self, temp_dir_with_files): method test_no_matches_consistency (line 154) | def test_no_matches_consistency(self, temp_dir_with_files): method test_hidden_files_consistency (line 174) | def test_hidden_files_consistency(self, temp_dir_with_files): method test_multiple_extensions_consistency (line 199) | def test_multiple_extensions_consistency(self, temp_dir_with_files): method test_deep_nesting_consistency (line 224) | def test_deep_nesting_consistency(self, temp_dir_with_files): method test_wildcard_directory_consistency (line 249) | def test_wildcard_directory_consistency(self, temp_dir_with_files): method test_config_files_consistency (line 274) | def test_config_files_consistency(self, temp_dir_with_files): method test_special_characters_consistency (line 302) | def test_special_characters_consistency(self, temp_dir_with_files): method test_case_sensitivity_consistency (line 329) | def test_case_sensitivity_consistency(self, temp_dir_with_files): FILE: tests/tools/glob/test_glob_executor.py function test_glob_executor_initialization (line 14) | def test_glob_executor_initialization(): function test_glob_executor_basic_pattern (line 21) | def test_glob_executor_basic_pattern(): function test_glob_executor_recursive_pattern (line 40) | def test_glob_executor_recursive_pattern(): function test_glob_executor_custom_path (line 61) | def test_glob_executor_custom_path(): function test_glob_executor_invalid_path (line 83) | def test_glob_executor_invalid_path(): function test_glob_executor_no_matches (line 95) | def test_glob_executor_no_matches(): function test_glob_executor_directories_excluded (line 111) | def test_glob_executor_directories_excluded(): function test_glob_executor_sorting (line 129) | def test_glob_executor_sorting(): function test_glob_executor_truncation (line 158) | def test_glob_executor_truncation(): function test_glob_executor_complex_patterns (line 174) | def test_glob_executor_complex_patterns(): function test_glob_executor_exception_handling (line 202) | def test_glob_executor_exception_handling(): function test_glob_executor_absolute_paths (line 217) | def test_glob_executor_absolute_paths(): function test_glob_executor_preserves_symlink_paths (line 236) | def test_glob_executor_preserves_symlink_paths(): function test_glob_executor_empty_directory (line 262) | def test_glob_executor_empty_directory(): function test_extract_search_path_from_pattern_absolute_with_recursive (line 274) | def test_extract_search_path_from_pattern_absolute_with_recursive(): function test_extract_search_path_from_pattern_absolute_without_recursive (line 284) | def test_extract_search_path_from_pattern_absolute_without_recursive(): function test_extract_search_path_from_pattern_relative (line 294) | def test_extract_search_path_from_pattern_relative(): function test_extract_search_path_from_pattern_relative_simple (line 302) | def test_extract_search_path_from_pattern_relative_simple(): function test_extract_search_path_from_pattern_empty (line 310) | def test_extract_search_path_from_pattern_empty(): function test_extract_search_path_from_pattern_home_directory (line 318) | def test_extract_search_path_from_pattern_home_directory(): function test_extract_search_path_from_pattern_root_glob (line 329) | def test_extract_search_path_from_pattern_root_glob(): function test_extract_search_path_from_pattern_nested_glob (line 337) | def test_extract_search_path_from_pattern_nested_glob(): function test_extract_search_path_from_pattern_deep_nesting (line 347) | def test_extract_search_path_from_pattern_deep_nesting(): function test_glob_executor_concurrent_with_ripgrep (line 357) | def test_glob_executor_concurrent_with_ripgrep(): FILE: tests/tools/glob/test_glob_tool.py function _create_test_conv_state (line 20) | def _create_test_conv_state(temp_dir: str) -> ConversationState: function test_glob_tool_initialization (line 31) | def test_glob_tool_initialization(): function test_glob_tool_invalid_working_dir (line 45) | def test_glob_tool_invalid_working_dir(): function test_glob_tool_find_files (line 62) | def test_glob_tool_find_files(): function test_glob_tool_specific_directory (line 103) | def test_glob_tool_specific_directory(): function test_glob_tool_no_matches (line 134) | def test_glob_tool_no_matches(): function test_glob_tool_invalid_directory (line 155) | def test_glob_tool_invalid_directory(): function test_glob_tool_complex_patterns (line 172) | def test_glob_tool_complex_patterns(): function test_glob_tool_directories_excluded (line 206) | def test_glob_tool_directories_excluded(): function test_glob_tool_to_llm_content (line 236) | def test_glob_tool_to_llm_content(): function test_glob_tool_to_llm_content_no_matches (line 261) | def test_glob_tool_to_llm_content_no_matches(): function test_glob_tool_to_llm_content_error (line 280) | def test_glob_tool_to_llm_content_error(): function test_glob_tool_declared_resources_with_ripgrep (line 314) | def test_glob_tool_declared_resources_with_ripgrep(pattern, path): function test_glob_tool_declared_resources_without_ripgrep (line 348) | def test_glob_tool_declared_resources_without_ripgrep(pattern, path): function test_glob_tool_truncation (line 366) | def test_glob_tool_truncation(): FILE: tests/tools/grep/test_consistency.py class TestGrepConsistency (line 20) | class TestGrepConsistency: method temp_dir_with_content (line 24) | def temp_dir_with_content(self): method test_basic_search_consistency (line 103) | def test_basic_search_consistency(self, temp_dir_with_content): method test_case_insensitive_consistency (line 132) | def test_case_insensitive_consistency(self, temp_dir_with_content): method test_include_pattern_consistency (line 161) | def test_include_pattern_consistency(self, temp_dir_with_content): method test_no_matches_consistency (line 194) | def test_no_matches_consistency(self, temp_dir_with_content): method test_regex_pattern_consistency (line 218) | def test_regex_pattern_consistency(self, temp_dir_with_content): method test_todo_comments_consistency (line 247) | def test_todo_comments_consistency(self, temp_dir_with_content): method test_error_patterns_consistency (line 276) | def test_error_patterns_consistency(self, temp_dir_with_content): method test_import_statements_consistency (line 305) | def test_import_statements_consistency(self, temp_dir_with_content): method test_class_definitions_consistency (line 334) | def test_class_definitions_consistency(self, temp_dir_with_content): method test_deep_nested_search_consistency (line 363) | def test_deep_nested_search_consistency(self, temp_dir_with_content): method test_config_file_search_consistency (line 392) | def test_config_file_search_consistency(self, temp_dir_with_content): method test_hidden_files_search_consistency (line 428) | def test_hidden_files_search_consistency(self, temp_dir_with_content): FILE: tests/tools/grep/test_grep_executor.py function test_grep_executor_initialization (line 21) | def test_grep_executor_initialization(): function test_grep_executor_prefers_ripgrep_backend (line 28) | def test_grep_executor_prefers_ripgrep_backend(monkeypatch): function test_grep_executor_falls_back_to_system_grep (line 38) | def test_grep_executor_falls_back_to_system_grep(monkeypatch): function test_grep_executor_falls_back_to_python_when_no_binary_exists (line 48) | def test_grep_executor_falls_back_to_python_when_no_binary_exists(monkey... function test_grep_executor_basic_search (line 58) | def test_grep_executor_basic_search(): function test_grep_executor_case_insensitive (line 83) | def test_grep_executor_case_insensitive(): function test_grep_executor_include_filter (line 98) | def test_grep_executor_include_filter(): function test_grep_executor_custom_path (line 114) | def test_grep_executor_custom_path(): function test_grep_executor_invalid_path (line 132) | def test_grep_executor_invalid_path(): function test_grep_executor_no_matches (line 143) | def test_grep_executor_no_matches(): function test_grep_executor_hidden_files_excluded (line 156) | def test_grep_executor_hidden_files_excluded(): function test_grep_executor_include_filter_still_skips_hidden_directories (line 171) | def test_grep_executor_include_filter_still_skips_hidden_directories(): function test_grep_executor_system_grep_matches_python_fallback_for_hidden_include (line 189) | def test_grep_executor_system_grep_matches_python_fallback_for_hidden_in... function test_grep_executor_sorting (line 212) | def test_grep_executor_sorting(): function test_grep_executor_truncation (line 233) | def test_grep_executor_truncation(): function test_grep_executor_invalid_regex (line 249) | def test_grep_executor_invalid_regex(): function test_grep_executor_concurrent (line 260) | def test_grep_executor_concurrent(): FILE: tests/tools/grep/test_grep_tool.py function _create_test_conv_state (line 19) | def _create_test_conv_state(temp_dir: str) -> ConversationState: function test_grep_tool_initialization (line 30) | def test_grep_tool_initialization(): function test_grep_tool_invalid_working_dir (line 42) | def test_grep_tool_invalid_working_dir(): function test_grep_tool_basic_search (line 52) | def test_grep_tool_basic_search(): function test_grep_tool_case_insensitive (line 81) | def test_grep_tool_case_insensitive(): function test_grep_tool_include_filter (line 98) | def test_grep_tool_include_filter(): function test_grep_tool_specific_directory (line 117) | def test_grep_tool_specific_directory(): function test_grep_tool_no_matches (line 139) | def test_grep_tool_no_matches(): function test_grep_tool_invalid_regex (line 157) | def test_grep_tool_invalid_regex(): function test_grep_tool_invalid_directory (line 172) | def test_grep_tool_invalid_directory(): function test_grep_tool_hidden_files_excluded (line 187) | def test_grep_tool_hidden_files_excluded(): function test_grep_tool_to_llm_content (line 206) | def test_grep_tool_to_llm_content(): function test_grep_tool_to_llm_content_with_include (line 226) | def test_grep_tool_to_llm_content_with_include(): function test_grep_tool_to_llm_content_no_matches (line 244) | def test_grep_tool_to_llm_content_no_matches(): function test_grep_tool_to_llm_content_error (line 262) | def test_grep_tool_to_llm_content_error(): function test_grep_tool_declared_resources (line 295) | def test_grep_tool_declared_resources(pattern, path, include): function test_grep_tool_truncation (line 310) | def test_grep_tool_truncation(): FILE: tests/tools/planning_file_editor/test_planning_file_editor_tool.py function _create_conv_state (line 18) | def _create_conv_state(working_dir: str) -> ConversationState: function test_create_without_plan_path_uses_agents_tmp_directory (line 29) | def test_create_without_plan_path_uses_agents_tmp_directory(): function test_create_with_plan_path_uses_given_path (line 49) | def test_create_with_plan_path_uses_given_path(): function test_create_with_plan_path_creates_parent_directory (line 65) | def test_create_with_plan_path_creates_parent_directory(): function test_create_without_plan_path_uses_legacy_location_if_exists (line 81) | def test_create_without_plan_path_uses_legacy_location_if_exists(): function test_create_with_relative_path_raises_value_error (line 103) | def test_create_with_relative_path_raises_value_error(): FILE: tests/tools/task/test_task_manager.py function _make_llm (line 24) | def _make_llm() -> LLM: function _make_parent_conversation (line 32) | def _make_parent_conversation( function _manager_with_parent (line 48) | def _manager_with_parent( class TestTaskStatusEnum (line 59) | class TestTaskStatusEnum: method test_all_values (line 60) | def test_all_values(self): method test_is_str_enum (line 65) | def test_is_str_enum(self): class TestTaskState (line 70) | class TestTaskState: method test_initial_state (line 73) | def test_initial_state(self): method test_set_completed (line 86) | def test_set_completed(self, result): method test_set_error (line 99) | def test_set_error(self): class TestTaskManager (line 113) | class TestTaskManager: method setup_method (line 116) | def setup_method(self): method teardown_method (line 119) | def teardown_method(self): method test_init_defaults (line 122) | def test_init_defaults(self): method test_persistence_dir_none_at_init (line 128) | def test_persistence_dir_none_at_init(self): method test_generate_task_id (line 132) | def test_generate_task_id(self): method test_parent_conversation_raises_before_set (line 150) | def test_parent_conversation_raises_before_set(self): method test_ensure_parent_sets_once (line 156) | def test_ensure_parent_sets_once(self): method test_returns_running_task_state (line 169) | def test_returns_running_task_state(self, tmp_path): method test_registers_uuid (line 184) | def test_registers_uuid(self, tmp_path): method test_create_task_uses_parent_max_iteration_when_factory_is_none (line 192) | def test_create_task_uses_parent_max_iteration_when_factory_is_none(se... method test_create_task_prefers_factory_max_iteration_over_parent (line 211) | def test_create_task_prefers_factory_max_iteration_over_parent(self, t... method test_resume_unknown_task_raises (line 246) | def test_resume_unknown_task_raises(self, tmp_path): method test_resume_after_evict (line 253) | def test_resume_after_evict(self, tmp_path): method test_default_agent_type (line 275) | def test_default_agent_type(self, tmp_path): method test_registered_agent_type (line 283) | def test_registered_agent_type(self, tmp_path): method test_unknown_agent_type_raises (line 303) | def test_unknown_agent_type_raises(self, tmp_path): method test_close (line 308) | def test_close(self, tmp_path): method test_returns_local_conversation (line 324) | def test_returns_local_conversation(self, tmp_path): method test_persistence_dir_is_tmp_dir (line 340) | def test_persistence_dir_is_tmp_dir(self, tmp_path): method test_no_visualizer_when_parent_has_none (line 359) | def test_no_visualizer_when_parent_has_none(self, tmp_path): method test_sub_agents_inherit_parent_prompt_cache_key (line 374) | def test_sub_agents_inherit_parent_prompt_cache_key(self, tmp_path): function _make_task_with_mock_conv (line 396) | def _make_task_with_mock_conv(task_id: str, **conv_kwargs) -> Task: class TestRunTask (line 409) | class TestRunTask: method setup_method (line 412) | def setup_method(self): method teardown_method (line 415) | def teardown_method(self): method test_raises_when_conversation_is_none (line 418) | def test_raises_when_conversation_is_none(self, tmp_path): method test_successful_run_sets_result (line 434) | def test_successful_run_sets_result(self, mock_get_response, tmp_path): method test_run_evicts_conversation_after_success (line 457) | def test_run_evicts_conversation_after_success(self, mock_get_response... method test_run_sets_error_on_exception (line 473) | def test_run_sets_error_on_exception(self, tmp_path): method test_run_evicts_conversation_after_error (line 489) | def test_run_evicts_conversation_after_error(self, tmp_path): method test_run_passes_parent_visualizer_name_as_sender (line 510) | def test_run_passes_parent_visualizer_name_as_sender( class TestStartTask (line 532) | class TestStartTask: method setup_method (line 535) | def setup_method(self): method teardown_method (line 538) | def teardown_method(self): method _fake_run_task (line 541) | def _fake_run_task(self, task: Task, prompt: str) -> Task: method test_start_new_task_creates_and_runs (line 546) | def test_start_new_task_creates_and_runs(self, tmp_path): method test_start_task_sets_parent_conversation (line 563) | def test_start_task_sets_parent_conversation(self, tmp_path): method test_start_task_with_resume (line 580) | def test_start_task_with_resume(self, tmp_path): method test_start_task_resume_unknown_raises (line 602) | def test_start_task_resume_unknown_raises(self, tmp_path): class TestTaskMetrics (line 616) | class TestTaskMetrics: method setup_method (line 619) | def setup_method(self): method teardown_method (line 622) | def teardown_method(self): method test_sub_agent_has_independent_metrics (line 625) | def test_sub_agent_has_independent_metrics(self, tmp_path): method test_run_task_merges_metrics_into_parent (line 639) | def test_run_task_merges_metrics_into_parent(self, tmp_path): method test_multiple_tasks_have_separate_metrics (line 685) | def test_multiple_tasks_have_separate_metrics(self, tmp_path): function _register_hooked_agent (line 722) | def _register_hooked_agent(name: str, hook_config: HookConfig) -> None: class TestTaskManagerHooks (line 738) | class TestTaskManagerHooks: method setup_method (line 741) | def setup_method(self): method teardown_method (line 744) | def teardown_method(self): method test_create_task_passes_hook_config (line 747) | def test_create_task_passes_hook_config(self, tmp_path): method test_create_task_no_hooks_passes_none (line 771) | def test_create_task_no_hooks_passes_none(self, tmp_path): method test_resume_task_passes_hook_config (line 785) | def test_resume_task_passes_hook_config(self, tmp_path): method test_get_conversation_passes_hook_config (line 817) | def test_get_conversation_passes_hook_config(self, tmp_path): method test_get_conversation_without_hook_config (line 847) | def test_get_conversation_without_hook_config(self, tmp_path): class TestTaskManagerPersistence (line 866) | class TestTaskManagerPersistence: method setup_method (line 869) | def setup_method(self): method teardown_method (line 872) | def teardown_method(self): method test_no_persistence_uses_tmp_dir (line 875) | def test_no_persistence_uses_tmp_dir(self, tmp_path): method test_no_persistence_close_deletes_tmp_dir (line 883) | def test_no_persistence_close_deletes_tmp_dir(self, tmp_path): method test_with_persistence_creates_subagents_dir (line 894) | def test_with_persistence_creates_subagents_dir(self, tmp_path): method test_with_persistence_close_preserves_subagents_dir (line 910) | def test_with_persistence_close_preserves_subagents_dir(self, tmp_path): method test_with_persistence_subagent_conv_stored_under_subagents (line 924) | def test_with_persistence_subagent_conv_stored_under_subagents(self, t... FILE: tests/tools/task/test_task_manager_thread_safety.py function _make_llm (line 33) | def _make_llm() -> LLM: function _make_parent_conversation (line 41) | def _make_parent_conversation(tmp_path: Path) -> LocalConversation: function _make_action_event (line 52) | def _make_action_event(call_id: str) -> Any: function _register_agents (line 62) | def _register_agents(): function _run_concurrent_create_tasks (line 72) | def _run_concurrent_create_tasks( function test_concurrent_task_ids_are_unique (line 130) | def test_concurrent_task_ids_are_unique(tmp_path: Path): function test_concurrent_tasks_all_preserved_in_dict (line 145) | def test_concurrent_tasks_all_preserved_in_dict(tmp_path: Path): FILE: tests/tools/task/test_task_tool_set.py function _task_tool_call (line 14) | def _task_tool_call( function _text_message (line 45) | def _text_message(text: str) -> Message: function _register_simple_agent (line 50) | def _register_simple_agent(name: str, sub_llm: TestLLM) -> None: function _get_task_observations (line 59) | def _get_task_observations(conversation: LocalConversation) -> list[Task... class TestTaskToolSetIntegration (line 70) | class TestTaskToolSetIntegration: method setup_method (line 73) | def setup_method(self): method teardown_method (line 76) | def teardown_method(self): method test_basic_task_delegation_and_result (line 79) | def test_basic_task_delegation_and_result(self, tmp_path): method test_two_sequential_tasks (line 122) | def test_two_sequential_tasks(self, tmp_path): method test_task_resume_across_turns (line 155) | def test_task_resume_across_turns(self, tmp_path): method test_unknown_agent_type_returns_error_observation (line 212) | def test_unknown_agent_type_returns_error_observation(self, tmp_path): method test_sub_agent_exception_returns_error_observation (line 242) | def test_sub_agent_exception_returns_error_observation(self, tmp_path): method test_task_ids_are_unique_and_sequential (line 277) | def test_task_ids_are_unique_and_sequential(self, tmp_path): method test_resume_nonexistent_task_returns_error (line 308) | def test_resume_nonexistent_task_returns_error(self, tmp_path): class TestTaskToolExamples (line 341) | class TestTaskToolExamples: method setup_method (line 345) | def setup_method(self): method teardown_method (line 348) | def teardown_method(self): method test_matching_agent_example_included (line 351) | def test_matching_agent_example_included(self, tmp_path): method test_no_matching_agent_example_excluded (line 372) | def test_no_matching_agent_example_excluded(self, tmp_path): method test_only_registered_examples_included (line 390) | def test_only_registered_examples_included(self, tmp_path): FILE: tests/tools/terminal/conftest.py function pytest_collection_modifyitems (line 31) | def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: function get_no_change_timeout_suffix (line 49) | def get_no_change_timeout_suffix(timeout_seconds): function create_test_bash_session (line 57) | def create_test_bash_session(work_dir=None): function cleanup_bash_session (line 64) | def cleanup_bash_session(session): FILE: tests/tools/terminal/test_conversation_cleanup.py function test_conversation_close_calls_executor_close (line 16) | def test_conversation_close_calls_executor_close(mock_llm): function test_conversation_close_calls_executor_close_without_delete (line 51) | def test_conversation_close_calls_executor_close_without_delete(mock_llm): function test_conversation_del_calls_close (line 79) | def test_conversation_del_calls_close(mock_llm): function test_conversation_close_handles_executor_exceptions (line 114) | def test_conversation_close_handles_executor_exceptions(mock_llm): function test_conversation_close_skips_none_executors (line 145) | def test_conversation_close_skips_none_executors(mock_llm): function test_terminal_executor_close_calls_session_close (line 169) | def test_terminal_executor_close_calls_session_close(): function test_terminal_executor_close_handles_missing_session (line 187) | def test_terminal_executor_close_handles_missing_session(): FILE: tests/tools/terminal/test_escape_filter.py class TestFilterTerminalQueries (line 18) | class TestFilterTerminalQueries: method test_dsr_query_removed (line 21) | def test_dsr_query_removed(self): method test_osc_11_background_query_removed (line 28) | def test_osc_11_background_query_removed(self): method test_osc_10_foreground_query_removed (line 35) | def test_osc_10_foreground_query_removed(self): method test_osc_4_palette_query_removed (line 41) | def test_osc_4_palette_query_removed(self): method test_osc_4_palette_with_index_query_removed (line 47) | def test_osc_4_palette_with_index_query_removed(self): method test_osc_12_cursor_color_query_removed (line 53) | def test_osc_12_cursor_color_query_removed(self): method test_osc_17_highlight_query_removed (line 59) | def test_osc_17_highlight_query_removed(self): method test_osc_set_title_preserved (line 65) | def test_osc_set_title_preserved(self): method test_osc_hyperlink_preserved (line 71) | def test_osc_hyperlink_preserved(self): method test_osc_with_st_terminator_removed (line 77) | def test_osc_with_st_terminator_removed(self): method test_da_primary_query_removed (line 84) | def test_da_primary_query_removed(self): method test_da2_secondary_query_removed (line 95) | def test_da2_secondary_query_removed(self): method test_decrqss_query_removed (line 106) | def test_decrqss_query_removed(self): method test_colors_preserved (line 113) | def test_colors_preserved(self): method test_cursor_movement_preserved (line 120) | def test_cursor_movement_preserved(self): method test_multiple_queries_removed (line 127) | def test_multiple_queries_removed(self): method test_mixed_queries_and_formatting (line 133) | def test_mixed_queries_and_formatting(self): method test_empty_string (line 140) | def test_empty_string(self): method test_no_escape_sequences (line 144) | def test_no_escape_sequences(self): method test_unicode_preserved (line 149) | def test_unicode_preserved(self): class TestTerminalQueryFilter (line 156) | class TestTerminalQueryFilter: method test_single_chunk_complete_query (line 159) | def test_single_chunk_complete_query(self): method test_split_dsr_query_across_chunks (line 166) | def test_split_dsr_query_across_chunks(self): method test_split_osc_query_across_chunks (line 177) | def test_split_osc_query_across_chunks(self): method test_split_esc_alone_at_end (line 187) | def test_split_esc_alone_at_end(self): method test_incomplete_sequence_flushed_on_complete (line 200) | def test_incomplete_sequence_flushed_on_complete(self): method test_reset_clears_pending (line 210) | def test_reset_clears_pending(self): method test_multiple_commands_with_reset (line 222) | def test_multiple_commands_with_reset(self): method test_incremental_output_simulated (line 236) | def test_incremental_output_simulated(self): method test_decrqss_split_across_chunks (line 252) | def test_decrqss_split_across_chunks(self): method test_decrqss_split_at_st_terminator (line 261) | def test_decrqss_split_at_st_terminator(self): method test_formatting_preserved_across_chunks (line 277) | def test_formatting_preserved_across_chunks(self): method test_mixed_queries_and_formatting_across_chunks (line 286) | def test_mixed_queries_and_formatting_across_chunks(self): function test_session_filters_osc_background_query (line 317) | def test_session_filters_osc_background_query(terminal_type): function test_session_filters_dsr_cursor_query (line 339) | def test_session_filters_dsr_cursor_query(terminal_type): function test_session_filters_multiple_query_types (line 360) | def test_session_filters_multiple_query_types(terminal_type): function test_session_preserves_ansi_colors (line 378) | def test_session_preserves_ansi_colors(): function test_session_filters_query_but_preserves_colors (line 397) | def test_session_filters_query_but_preserves_colors(): FILE: tests/tools/terminal/test_heredoc_chunked_send.py function terminal (line 24) | def terminal(): function create_heredoc_command (line 35) | def create_heredoc_command(num_lines: int) -> str: function test_short_heredoc_works (line 45) | def test_short_heredoc_works(terminal: SubprocessTerminal): function test_long_heredoc_works (line 63) | def test_long_heredoc_works(terminal: SubprocessTerminal): function test_very_long_heredoc_works (line 81) | def test_very_long_heredoc_works(terminal: SubprocessTerminal): function test_multiline_threshold_boundary (line 99) | def test_multiline_threshold_boundary(terminal: SubprocessTerminal): function test_special_keys_not_affected_by_chunking (line 130) | def test_special_keys_not_affected_by_chunking(): FILE: tests/tools/terminal/test_large_environment.py function test_large_environment_variables (line 19) | def test_large_environment_variables(terminal_type): function test_environment_variable_access (line 65) | def test_environment_variable_access(terminal_type): function test_very_large_environment (line 92) | def test_very_large_environment(terminal_type): FILE: tests/tools/terminal/test_observation_truncation.py function test_terminal_observation_truncation_under_limit (line 9) | def test_terminal_observation_truncation_under_limit(): function test_terminal_observation_truncation_over_limit (line 40) | def test_terminal_observation_truncation_over_limit(): function test_terminal_observation_truncation_with_error (line 77) | def test_terminal_observation_truncation_with_error(): function test_terminal_observation_truncation_exact_limit (line 117) | def test_terminal_observation_truncation_exact_limit(): function test_terminal_observation_truncation_with_prefix_suffix (line 153) | def test_terminal_observation_truncation_with_prefix_suffix(): FILE: tests/tools/terminal/test_pool_integration.py function pool_executor (line 24) | def pool_executor(): class TestDeclaredResources (line 36) | class TestDeclaredResources: method test_pool_mode_opts_out_of_framework_locking (line 37) | def test_pool_mode_opts_out_of_framework_locking(self, pool_executor): method test_subprocess_mode_serializes (line 50) | def test_subprocess_mode_serializes(self): class TestConcurrentExecution (line 72) | class TestConcurrentExecution: method test_parallel_calls_execute_concurrently (line 73) | def test_parallel_calls_execute_concurrently(self, pool_executor): class TestTmuxPoolRecovery (line 114) | class TestTmuxPoolRecovery: method test_shell_exit_returns_actionable_error_and_rebuilds_pool (line 115) | def test_shell_exit_returns_actionable_error_and_rebuilds_pool(self, p... method test_reset_after_shell_exit_uses_rebuilt_pool (line 130) | def test_reset_after_shell_exit_uses_rebuilt_pool(self, pool_executor): FILE: tests/tools/terminal/test_ps1_corruption.py class TestPS1Corruption (line 19) | class TestPS1Corruption: method test_regex_skips_corrupted_first_block (line 109) | def test_regex_skips_corrupted_first_block(self): method test_corrupted_ps1_recovery (line 132) | def test_corrupted_ps1_recovery(self): method test_handle_completed_command_graceful_fallback_with_corrupted_output (line 148) | def test_handle_completed_command_graceful_fallback_with_corrupted_out... method test_pager_output_causes_zero_ps1_matches (line 207) | def test_pager_output_causes_zero_ps1_matches(self): method test_partial_ps1_block_not_matched (line 225) | def test_partial_ps1_block_not_matched(self): method test_ps1_block_with_embedded_special_chars (line 248) | def test_ps1_block_with_embedded_special_chars(self): method test_interleaved_output_between_ps1_markers (line 270) | def test_interleaved_output_between_ps1_markers(self): class TestPS1CorruptionIntegration (line 295) | class TestPS1CorruptionIntegration: method test_terminal_session_handles_corrupted_output_gracefully (line 298) | def test_terminal_session_handles_corrupted_output_gracefully(self): class TestPS1ParserRobustness (line 333) | class TestPS1ParserRobustness: method test_regex_handles_multiline_json (line 336) | def test_regex_handles_multiline_json(self): method test_multiple_valid_ps1_blocks (line 353) | def test_multiple_valid_ps1_blocks(self): function test_regex_handles_nested_markers (line 384) | def test_regex_handles_nested_markers(): FILE: tests/tools/terminal/test_schema.py function test_to_mcp_tool_detailed_type_validation_bash (line 4) | def test_to_mcp_tool_detailed_type_validation_bash(mock_conversation_sta... FILE: tests/tools/terminal/test_secrets_masking.py function test_terminal_executor_without_conversation (line 16) | def test_terminal_executor_without_conversation(): function test_terminal_executor_with_conversation_secrets (line 35) | def test_terminal_executor_with_conversation_secrets(): FILE: tests/tools/terminal/test_send_keys.py function test_parse_ctrl_key_valid (line 30) | def test_parse_ctrl_key_valid(text: str, expected: str) -> None: function test_parse_ctrl_key_invalid (line 45) | def test_parse_ctrl_key_invalid(text: str) -> None: function test_supported_special_keys_contains_essentials (line 52) | def test_supported_special_keys_contains_essentials() -> None: function test_subprocess_specials_match_contract (line 61) | def test_subprocess_specials_match_contract() -> None: function test_tmux_specials_match_contract (line 70) | def test_tmux_specials_match_contract() -> None: function subprocess_terminal (line 82) | def subprocess_terminal(): function test_subprocess_send_keys_ctrl_c (line 98) | def test_subprocess_send_keys_ctrl_c(subprocess_terminal) -> None: function test_subprocess_send_keys_named_special (line 103) | def test_subprocess_send_keys_named_special(subprocess_terminal) -> None: function test_subprocess_send_keys_ctrl_variants (line 108) | def test_subprocess_send_keys_ctrl_variants(subprocess_terminal) -> None: function test_subprocess_send_keys_echo (line 114) | def test_subprocess_send_keys_echo(subprocess_terminal) -> None: function tmux_terminal (line 126) | def tmux_terminal(): function test_tmux_send_keys_ctrl_c (line 142) | def test_tmux_send_keys_ctrl_c(tmux_terminal) -> None: function test_tmux_send_keys_named_special (line 146) | def test_tmux_send_keys_named_special(tmux_terminal) -> None: function test_tmux_send_keys_ctrl_variants (line 152) | def test_tmux_send_keys_ctrl_variants(tmux_terminal) -> None: function test_tmux_send_keys_plain_text (line 157) | def test_tmux_send_keys_plain_text(tmux_terminal) -> None: FILE: tests/tools/terminal/test_session_factory.py function test_tmux_detection (line 28) | def test_tmux_detection(): function test_forced_terminal_types (line 35) | def test_forced_terminal_types(): function test_invalid_terminal_type (line 52) | def test_invalid_terminal_type(): function test_unavailable_terminal_type (line 59) | def test_unavailable_terminal_type(): function test_auto_detection_unix (line 72) | def test_auto_detection_unix(mock_system): function test_warning_when_tmux_not_available (line 99) | def test_warning_when_tmux_not_available(mock_system): function test_session_parameters_passed (line 118) | def test_session_parameters_passed(): FILE: tests/tools/terminal/test_shell_path_configuration.py function test_shell_path_explicit_parameter (line 22) | def test_shell_path_explicit_parameter(): function test_shell_path_auto_detection (line 41) | def test_shell_path_auto_detection(): function test_shell_path_validation_not_exists (line 58) | def test_shell_path_validation_not_exists(): function test_shell_path_validation_not_executable (line 73) | def test_shell_path_validation_not_executable(): function test_shell_path_auto_detection_failure (line 94) | def test_shell_path_auto_detection_failure(): function test_shell_path_with_tmux_terminal (line 110) | def test_shell_path_with_tmux_terminal(): function test_shell_path_reset_preserves_config (line 132) | def test_shell_path_reset_preserves_config(): function test_shell_path_precedence_explicit_over_auto (line 159) | def test_shell_path_precedence_explicit_over_auto(): function test_terminal_tool_shell_path_parameter (line 178) | def test_terminal_tool_shell_path_parameter(): FILE: tests/tools/terminal/test_shutdown_handling.py function test_tmux_terminal_close_normal_operation (line 12) | def test_tmux_terminal_close_normal_operation(): function test_tmux_terminal_close_during_shutdown (line 27) | def test_tmux_terminal_close_during_shutdown(): function test_tmux_terminal_close_multiple_calls (line 46) | def test_tmux_terminal_close_multiple_calls(): function test_tmux_terminal_close_when_session_already_dead (line 63) | def test_tmux_terminal_close_when_session_already_dead(): FILE: tests/tools/terminal/test_terminal_exit_code_top_level.py function test_exit_code_top_level_completed (line 10) | def test_exit_code_top_level_completed(terminal_type): function test_exit_code_top_level_soft_timeout (line 23) | def test_exit_code_top_level_soft_timeout(terminal_type): function test_exit_code_top_level_hard_timeout (line 39) | def test_exit_code_top_level_hard_timeout(terminal_type): FILE: tests/tools/terminal/test_terminal_parsing.py function test_split_commands_util (line 9) | def test_split_commands_util(): function test_single_commands (line 90) | def test_single_commands(input_command, expected_output): function test_heredoc (line 94) | def test_heredoc(): function test_backslash_continuation (line 106) | def test_backslash_continuation(): function test_comments (line 120) | def test_comments(): function test_complex_quoting (line 133) | def test_complex_quoting(): function test_invalid_syntax (line 147) | def test_invalid_syntax(): function test_unclosed_backtick (line 158) | def test_unclosed_backtick(): function test_over_escaped_command (line 190) | def test_over_escaped_command(): function sample_commands (line 214) | def sample_commands(): function test_split_single_commands (line 229) | def test_split_single_commands(sample_commands): function test_split_commands_with_heredoc (line 235) | def test_split_commands_with_heredoc(): function test_split_commands_with_backslash_continuation (line 248) | def test_split_commands_with_backslash_continuation(): function test_split_commands_with_empty_lines (line 263) | def test_split_commands_with_empty_lines(): function test_split_commands_with_comments (line 276) | def test_split_commands_with_comments(): function test_split_commands_with_complex_quoting (line 290) | def test_split_commands_with_complex_quoting(): function test_split_commands_with_invalid_input (line 306) | def test_split_commands_with_invalid_input(): function test_escape_bash_special_chars (line 317) | def test_escape_bash_special_chars(): function test_escape_bash_special_chars_with_invalid_syntax (line 351) | def test_escape_bash_special_chars_with_invalid_syntax(): function test_escape_bash_special_chars_with_heredoc (line 363) | def test_escape_bash_special_chars_with_heredoc(): function test_escape_bash_special_chars_with_parameter_expansion (line 376) | def test_escape_bash_special_chars_with_parameter_expansion(): function test_escape_bash_special_chars_with_command_substitution (line 400) | def test_escape_bash_special_chars_with_command_substitution(): function test_escape_bash_special_chars_mixed_nodes (line 424) | def test_escape_bash_special_chars_mixed_nodes(): function test_escape_bash_special_chars_with_chained_commands (line 457) | def test_escape_bash_special_chars_with_chained_commands(): FILE: tests/tools/terminal/test_terminal_ps1_metadata.py function test_ps1_metadata_format (line 18) | def test_ps1_metadata_format(): function test_ps1_metadata_json_structure (line 26) | def test_ps1_metadata_json_structure(): function test_ps1_metadata_parsing (line 49) | def test_ps1_metadata_parsing(): function test_ps1_metadata_parsing_string (line 73) | def test_ps1_metadata_parsing_string(): function test_ps1_metadata_parsing_string_real_example (line 95) | def test_ps1_metadata_parsing_string_real_example(): function test_ps1_metadata_parsing_additional_prefix (line 122) | def test_ps1_metadata_parsing_additional_prefix(): function test_ps1_metadata_parsing_invalid (line 150) | def test_ps1_metadata_parsing_invalid(): function test_ps1_metadata_missing_fields (line 194) | def test_ps1_metadata_missing_fields(): function test_ps1_metadata_multiple_blocks (line 226) | def test_ps1_metadata_multiple_blocks(): function test_ps1_metadata_regex_pattern (line 253) | def test_ps1_metadata_regex_pattern(): function test_cmd_output_observation_properties (line 274) | def test_cmd_output_observation_properties(): function test_ps1_metadata_empty_fields (line 315) | def test_ps1_metadata_empty_fields(): function test_issue_2416_missing_ps1_metadata_graceful_fallback (line 363) | def test_issue_2416_missing_ps1_metadata_graceful_fallback(): FILE: tests/tools/terminal/test_terminal_reset.py function _create_conv_state (line 20) | def _create_conv_state(working_dir: str) -> ConversationState: function test_bash_reset_basic (line 30) | def test_bash_reset_basic(): function test_bash_reset_with_command (line 63) | def test_bash_reset_with_command(): function test_bash_reset_working_directory (line 92) | def test_bash_reset_working_directory(): function test_bash_reset_multiple_times (line 128) | def test_bash_reset_multiple_times(): function test_bash_reset_with_timeout (line 159) | def test_bash_reset_with_timeout(): function test_bash_reset_with_is_input_validation (line 173) | def test_bash_reset_with_is_input_validation(): function test_bash_reset_only_with_empty_command (line 189) | def test_bash_reset_only_with_empty_command(): FILE: tests/tools/terminal/test_terminal_session.py function test_session_initialization (line 40) | def test_session_initialization(terminal_type): function test_cwd_property (line 62) | def test_cwd_property(tmp_path, terminal_type): function test_basic_command (line 83) | def test_basic_command(terminal_type): function test_session_truncates_large_command_output (line 120) | def test_session_truncates_large_command_output(monkeypatch, terminal_ty... function test_session_truncates_multiline_output (line 144) | def test_session_truncates_multiline_output(monkeypatch, terminal_type): function test_truncation_preserves_metadata_in_llm_content (line 181) | def test_truncation_preserves_metadata_in_llm_content(monkeypatch, termi... function test_environment_variable_persistence (line 220) | def test_environment_variable_persistence(terminal_type): function test_environment_variable_inheritance_from_parent (line 238) | def test_environment_variable_inheritance_from_parent(terminal_type): function test_long_running_command_follow_by_execute (line 273) | def test_long_running_command_follow_by_execute(): function test_interactive_command (line 320) | def test_interactive_command(terminal_type): function test_ctrl_c (line 382) | def test_ctrl_c(terminal_type): function test_empty_command_error (line 416) | def test_empty_command_error(terminal_type): function test_command_output_continuation (line 443) | def test_command_output_continuation(terminal_type): function test_history_expansion_disabled (line 521) | def test_history_expansion_disabled(terminal_type): function test_long_output (line 533) | def test_long_output(terminal_type): function test_long_output_exceed_history_limit (line 552) | def test_long_output_exceed_history_limit(terminal_type): function test_multiline_command (line 570) | def test_multiline_command(): function test_python_interactive_input (line 592) | def test_python_interactive_input(terminal_type): function _run_bash_action (line 629) | def _run_bash_action(session, command: str, **kwargs): function test_bash_server (line 641) | def test_bash_server(terminal_type): function test_bash_background_server (line 678) | def test_bash_background_server(terminal_type): function test_multiline_commands (line 709) | def test_multiline_commands(terminal_type): function test_complex_commands (line 737) | def test_complex_commands(terminal_type): function test_no_ps2_in_output (line 760) | def test_no_ps2_in_output(terminal_type): function test_multiline_command_loop (line 778) | def test_multiline_command_loop(terminal_type): function test_multiple_multiline_commands (line 812) | def test_multiple_multiline_commands(terminal_type): function test_cmd_run (line 862) | def test_cmd_run(terminal_type): function test_run_as_user_correct_home_dir (line 900) | def test_run_as_user_correct_home_dir(terminal_type): function test_multi_cmd_run_in_single_line (line 918) | def test_multi_cmd_run_in_single_line(terminal_type): function test_stateful_cmd (line 934) | def test_stateful_cmd(terminal_type): function test_failed_cmd (line 957) | def test_failed_cmd(terminal_type): function test_python_version (line 972) | def test_python_version(terminal_type): function test_pwd_property (line 988) | def test_pwd_property(terminal_type): function test_long_output_from_nested_directories (line 1009) | def test_long_output_from_nested_directories(terminal_type): function test_command_backslash (line 1040) | def test_command_backslash(terminal_type): function test_bash_remove_prefix (line 1074) | def test_bash_remove_prefix(terminal_type): FILE: tests/tools/terminal/test_terminal_tool.py function _create_test_conv_state (line 19) | def _create_test_conv_state(temp_dir: str) -> ConversationState: function test_bash_tool_initialization (line 30) | def test_bash_tool_initialization(): function test_bash_tool_with_username (line 43) | def test_bash_tool_with_username(): function test_bash_tool_execution (line 56) | def test_bash_tool_execution(): function test_bash_tool_working_directory (line 75) | def test_bash_tool_working_directory(): function test_bash_tool_to_openai_tool (line 93) | def test_bash_tool_to_openai_tool(): FILE: tests/tools/terminal/test_terminal_tool_auto_detection.py function _create_conv_state (line 31) | def _create_conv_state(working_dir: str) -> ConversationState: function test_default_auto_detection (line 42) | def test_default_auto_detection(): function test_forced_terminal_types (line 69) | def test_forced_terminal_types(): function test_unix_auto_detection (line 90) | def test_unix_auto_detection(mock_system): function test_session_parameters (line 128) | def test_session_parameters(): function test_backward_compatibility (line 148) | def test_backward_compatibility(): function test_tool_metadata (line 162) | def test_tool_metadata(): function test_session_lifecycle (line 174) | def test_session_lifecycle(): FILE: tests/tools/terminal/test_tmux_pane_pool.py function pool (line 13) | def pool(): function test_rejects_invalid_max_panes (line 26) | def test_rejects_invalid_max_panes(max_panes): function test_initialize_idempotent (line 31) | def test_initialize_idempotent(): function test_checkout_returns_initialized_terminal (line 42) | def test_checkout_returns_initialized_terminal(pool): function test_checkout_creates_panes_lazily (line 49) | def test_checkout_creates_panes_lazily(pool): function test_checkin_reuses_panes (line 59) | def test_checkin_reuses_panes(pool): function test_checkout_blocks_when_full (line 67) | def test_checkout_blocks_when_full(pool): function test_checkout_unblocks_after_checkin (line 78) | def test_checkout_unblocks_after_checkin(pool): function test_replace_returns_new_terminal (line 100) | def test_replace_returns_new_terminal(pool): function test_replace_preserves_semaphore (line 108) | def test_replace_preserves_semaphore(pool): function test_replace_closes_old_pane (line 124) | def test_replace_closes_old_pane(pool): function test_replace_does_not_affect_other_panes (line 130) | def test_replace_does_not_affect_other_panes(pool): function test_replace_fresh_pane_runs_commands (line 145) | def test_replace_fresh_pane_runs_commands(pool, cmd): function test_parallel_commands (line 166) | def test_parallel_commands(pool, labels_and_cmds): function test_concurrent_replace_does_not_corrupt_pool (line 195) | def test_concurrent_replace_does_not_corrupt_pool(pool): function test_initial_window_killed_after_first_pane (line 221) | def test_initial_window_killed_after_first_pane(pool): function test_close_idempotent (line 232) | def test_close_idempotent(pool): function test_checkout_after_close_raises (line 237) | def test_checkout_after_close_raises(pool): function test_checkin_foreign_pane_is_ignored (line 243) | def test_checkin_foreign_pane_is_ignored(pool): FILE: tests/tools/terminal/test_windows_ctrl_c.py function _powershell_process_exists (line 19) | def _powershell_process_exists(pid: int) -> bool: function _stop_powershell_process (line 38) | def _stop_powershell_process(pid: int) -> None: function test_windows_ctrl_c_interrupt_kills_child_process_tree (line 54) | def test_windows_ctrl_c_interrupt_kills_child_process_tree(tmp_path) -> ... FILE: tests/tools/terminal/test_windows_terminal.py function temp_dir (line 31) | def temp_dir() -> Generator[str]: function windows_session (line 37) | def windows_session(temp_dir: str) -> Generator[TerminalSession]: function conversation (line 47) | def conversation(temp_dir: str) -> Generator[LocalConversation]: function terminal_executor (line 60) | def terminal_executor(conversation: LocalConversation) -> TerminalExecutor: function _normalize_path (line 65) | def _normalize_path(path: str) -> str: function test_factory_auto_detects_windows_terminal (line 69) | def test_factory_auto_detects_windows_terminal(temp_dir: str) -> None: function test_forced_windows_backend_uses_powershell (line 78) | def test_forced_windows_backend_uses_powershell(temp_dir: str) -> None: function test_basic_command_execution (line 87) | def test_basic_command_execution(windows_session) -> None: function test_working_directory_updates_and_persists (line 96) | def test_working_directory_updates_and_persists(windows_session, temp_di... function test_failed_powershell_command_reports_failure (line 108) | def test_failed_powershell_command_reports_failure(windows_session) -> N... function test_native_exit_code_does_not_leak_to_next_command (line 114) | def test_native_exit_code_does_not_leak_to_next_command(windows_session)... function test_terminal_executor_exports_conversation_secrets_in_powershell (line 125) | def test_terminal_executor_exports_conversation_secrets_in_powershell( function test_terminal_tool_uses_windows_description (line 140) | def test_terminal_tool_uses_windows_description(temp_dir: str) -> None: FILE: tests/tools/test_builtin_agents.py function _clean_registry (line 26) | def _clean_registry() -> Iterator[None]: function _make_test_llm (line 33) | def _make_test_llm() -> LLM: function test_builtins_contains_expected_agents (line 37) | def test_builtins_contains_expected_agents() -> None: function test_load_all_builtins (line 44) | def test_load_all_builtins() -> None: function test_register_builtins_agents_registers_expected_factories (line 69) | def test_register_builtins_agents_registers_expected_factories( function test_general_purpose_has_no_browser_tools (line 98) | def test_general_purpose_has_no_browser_tools() -> None: function test_register_builtins_agents_skips_web_researcher_without_browser (line 107) | def test_register_builtins_agents_skips_web_researcher_without_browser()... function test_deprecated_agent_names_still_work (line 123) | def test_deprecated_agent_names_still_work( FILE: tests/tools/test_init.py function test_submodule_imports_work (line 4) | def test_submodule_imports_work(): function test_tools_module_has_expected_top_level_exports (line 17) | def test_tools_module_has_expected_top_level_exports(): function test_from_import_works (line 36) | def test_from_import_works(): FILE: tests/tools/test_planning_preset.py function test_get_planning_tools_without_plan_path_has_empty_params (line 7) | def test_get_planning_tools_without_plan_path_has_empty_params(): function test_get_planning_tools_with_plan_path_passes_params (line 17) | def test_get_planning_tools_with_plan_path_passes_params(): FILE: tests/tools/test_tool_name_consistency.py function test_tool_name_attributes_exist (line 12) | def test_tool_name_attributes_exist(): function test_tool_name_consistency (line 42) | def test_tool_name_consistency(): function test_tool_name_accessible_at_class_level (line 60) | def test_tool_name_accessible_at_class_level(): FILE: tests/tools/test_tool_registration_check.py function test_browser_definition_special_case_handles_platform_path_separator (line 6) | def test_browser_definition_special_case_handles_platform_path_separator(): FILE: tests/tools/test_working_dir_standardization.py function _create_test_conv_state (line 31) | def _create_test_conv_state(temp_dir: str) -> ConversationState: function test_terminal_and_file_editor_use_same_working_dir (line 42) | def test_terminal_and_file_editor_use_same_working_dir(): function test_tools_do_not_require_params_for_working_dir (line 87) | def test_tools_do_not_require_params_for_working_dir(): FILE: tests/tools/tom_consult/test_tom_consult_tool.py function test_consult_tom_declared_resources (line 25) | def test_consult_tom_declared_resources(action): FILE: tests/workspace/test_api_remote_workspace.py function test_api_timeout_is_used_in_client (line 9) | def test_api_timeout_is_used_in_client(): function test_api_timeout_default_value (line 47) | def test_api_timeout_default_value(): function test_different_timeout_values (line 77) | def test_different_timeout_values(): function test_startup_wait_timeout_default_and_override (line 111) | def test_startup_wait_timeout_default_and_override(): function test_forward_env_default_is_empty (line 139) | def test_forward_env_default_is_empty(): function test_forward_env_is_included_in_start_runtime_payload (line 158) | def test_forward_env_is_included_in_start_runtime_payload(): function test_forward_env_empty_list_results_in_empty_environment (line 211) | def test_forward_env_empty_list_results_in_empty_environment(): function test_start_runtime_logs_environment_keys_without_values (line 246) | def test_start_runtime_logs_environment_keys_without_values(caplog): function _make_workspace (line 295) | def _make_workspace(): function test_api_remote_workspace_exit_sends_callback (line 309) | def test_api_remote_workspace_exit_sends_callback(monkeypatch): FILE: tests/workspace/test_apptainer_workspace.py function mock_apptainer_workspace (line 9) | def mock_apptainer_workspace(tmp_path): function test_apptainer_workspace_import (line 42) | def test_apptainer_workspace_import(): function test_apptainer_workspace_inheritance (line 50) | def test_apptainer_workspace_inheritance(): function test_apptainer_workspace_has_gpu_field (line 58) | def test_apptainer_workspace_has_gpu_field(): function test_apptainer_workspace_gpu_passthrough_flag (line 66) | def test_apptainer_workspace_gpu_passthrough_flag( FILE: tests/workspace/test_cloud_workspace.py function test_api_timeout_is_used_in_client (line 8) | def test_api_timeout_is_used_in_client(): function test_api_timeout_default_value (line 39) | def test_api_timeout_default_value(): function test_api_headers_uses_bearer_token (line 64) | def test_api_headers_uses_bearer_token(): function test_get_agent_server_url_extracts_correct_url (line 82) | def test_get_agent_server_url_extracts_correct_url(): function test_get_agent_server_url_returns_none_when_not_found (line 105) | def test_get_agent_server_url_returns_none_when_not_found(): function test_get_agent_server_url_returns_none_when_empty (line 127) | def test_get_agent_server_url_returns_none_when_empty(): function test_cleanup_deletes_sandbox (line 147) | def test_cleanup_deletes_sandbox(): function test_cleanup_keeps_sandbox_alive_when_configured (line 175) | def test_cleanup_keeps_sandbox_alive_when_configured(): function test_cleanup_handles_missing_sandbox_id (line 197) | def test_cleanup_handles_missing_sandbox_id(): function test_send_api_request_includes_bearer_token (line 218) | def test_send_api_request_includes_bearer_token(): function test_context_manager_calls_cleanup (line 249) | def test_context_manager_calls_cleanup(): function test_cloud_api_url_trailing_slash_removed (line 271) | def test_cloud_api_url_trailing_slash_removed(): function test_sandbox_id_field_is_public (line 288) | def test_sandbox_id_field_is_public(): function test_sandbox_id_triggers_resume_instead_of_create (line 306) | def test_sandbox_id_triggers_resume_instead_of_create(): function test_no_sandbox_id_creates_new_sandbox (line 338) | def test_no_sandbox_id_creates_new_sandbox(): function test_resume_existing_sandbox_sets_internal_id (line 368) | def test_resume_existing_sandbox_sets_internal_id(): function _make_local_workspace (line 395) | def _make_local_workspace(**overrides): function test_local_agent_server_mode_skips_sandbox_creation (line 408) | def test_local_agent_server_mode_skips_sandbox_creation(): function test_local_agent_server_mode_sandbox_id_from_constructor (line 420) | def test_local_agent_server_mode_sandbox_id_from_constructor(): function test_local_agent_server_mode_sandbox_id_from_env (line 428) | def test_local_agent_server_mode_sandbox_id_from_env(monkeypatch): function test_local_agent_server_mode_session_key_from_env (line 437) | def test_local_agent_server_mode_session_key_from_env(monkeypatch): function test_local_agent_server_mode_session_key_fallback (line 448) | def test_local_agent_server_mode_session_key_fallback(monkeypatch): function test_local_agent_server_mode_custom_port (line 459) | def test_local_agent_server_mode_custom_port(): function test_local_agent_server_mode_port_from_env (line 467) | def test_local_agent_server_mode_port_from_env(monkeypatch): function test_local_agent_server_mode_cloud_credentials_available (line 476) | def test_local_agent_server_mode_cloud_credentials_available(): function test_local_agent_server_mode_cleanup_does_not_delete_sandbox (line 488) | def test_local_agent_server_mode_cleanup_does_not_delete_sandbox(): function test_local_agent_server_mode_context_manager (line 497) | def test_local_agent_server_mode_context_manager(): function test_callback_on_successful_exit (line 506) | def test_callback_on_successful_exit(monkeypatch): function test_callback_on_exception_exit (line 533) | def test_callback_on_exception_exit(monkeypatch): function test_no_callback_when_url_not_set (line 558) | def test_no_callback_when_url_not_set(): function test_callback_failure_does_not_raise (line 568) | def test_callback_failure_does_not_raise(monkeypatch): function test_register_conversation_sets_conversation_id (line 587) | def test_register_conversation_sets_conversation_id(): function test_conversation_id_property_returns_none_initially (line 597) | def test_conversation_id_property_returns_none_initially(): function test_callback_includes_conversation_id_when_registered (line 604) | def test_callback_includes_conversation_id_when_registered(monkeypatch): function test_callback_omits_conversation_id_when_not_registered (line 633) | def test_callback_omits_conversation_id_when_not_registered(monkeypatch): FILE: tests/workspace/test_cloud_workspace_automation_tags.py class TestDefaultConversationTags (line 10) | class TestDefaultConversationTags: method workspace (line 14) | def workspace(self): method test_empty_tags_when_no_env_vars (line 31) | def test_empty_tags_when_no_env_vars(self, workspace): method test_parses_trigger_from_payload (line 42) | def test_parses_trigger_from_payload(self, workspace): method test_parses_automation_id_from_payload (line 49) | def test_parses_automation_id_from_payload(self, workspace): method test_parses_automation_name_from_payload (line 56) | def test_parses_automation_name_from_payload(self, workspace): method test_parses_run_id_from_env_var (line 63) | def test_parses_run_id_from_env_var(self, workspace): method test_prefers_env_var_run_id_over_private_attr (line 70) | def test_prefers_env_var_run_id_over_private_attr(self, workspace): method test_uses_private_attr_run_id_when_no_env_var (line 77) | def test_uses_private_attr_run_id_when_no_env_var(self, workspace): method test_handles_invalid_json_payload (line 85) | def test_handles_invalid_json_payload(self, workspace): method test_handles_non_dict_json_payload (line 92) | def test_handles_non_dict_json_payload(self, workspace): method test_parses_full_payload (line 100) | def test_parses_full_payload(self, workspace): class TestConversationTagMerging (line 123) | class TestConversationTagMerging: method test_merges_default_tags_with_user_tags (line 126) | def test_merges_default_tags_with_user_tags(self): method test_uses_only_default_tags_when_no_user_tags (line 166) | def test_uses_only_default_tags_when_no_user_tags(self): method test_no_merge_when_workspace_returns_none_for_default_tags (line 196) | def test_no_merge_when_workspace_returns_none_for_default_tags(self): method test_no_merge_when_default_tags_empty (line 225) | def test_no_merge_when_default_tags_empty(self): class TestPluginSourceUrl (line 252) | class TestPluginSourceUrl: method test_github_shorthand_basic (line 255) | def test_github_shorthand_basic(self): method test_github_shorthand_with_ref (line 262) | def test_github_shorthand_with_ref(self): method test_github_shorthand_with_repo_path (line 269) | def test_github_shorthand_with_repo_path(self): method test_github_shorthand_with_ref_and_path (line 281) | def test_github_shorthand_with_ref_and_path(self): method test_urls_returned_as_is (line 295) | def test_urls_returned_as_is(self): method test_local_path_returns_none (line 328) | def test_local_path_returns_none(self): class TestPluginsTagInConversation (line 337) | class TestPluginsTagInConversation: method test_plugins_added_as_urls_in_tags (line 340) | def test_plugins_added_as_urls_in_tags(self): method test_local_plugins_not_included_in_tags (line 378) | def test_local_plugins_not_included_in_tags(self): method test_plugins_tag_merges_with_other_tags (line 411) | def test_plugins_tag_merges_with_other_tags(self): FILE: tests/workspace/test_cloud_workspace_repos.py class TestRepoSource (line 26) | class TestRepoSource: method test_short_url_with_provider (line 31) | def test_short_url_with_provider(self): method test_short_url_with_ref_and_provider (line 38) | def test_short_url_with_ref_and_provider(self): method test_short_url_without_provider_rejected (line 45) | def test_short_url_without_provider_rejected(self): method test_short_url_string_without_provider_rejected (line 50) | def test_short_url_string_without_provider_rejected(self): method test_short_url_dict_without_provider_rejected (line 55) | def test_short_url_dict_without_provider_rejected(self): method test_full_https_url_github (line 62) | def test_full_https_url_github(self): method test_full_https_url_gitlab (line 69) | def test_full_https_url_gitlab(self): method test_full_https_url_bitbucket (line 75) | def test_full_https_url_bitbucket(self): method test_git_ssh_url (line 81) | def test_git_ssh_url(self): method test_provider_explicit_overrides_detection (line 89) | def test_provider_explicit_overrides_detection(self): method test_provider_github_token_name (line 96) | def test_provider_github_token_name(self): method test_provider_gitlab_token_name (line 101) | def test_provider_gitlab_token_name(self): method test_provider_bitbucket_token_name (line 106) | def test_provider_bitbucket_token_name(self): method test_invalid_url_rejected (line 113) | def test_invalid_url_rejected(self): method test_url_with_dots_allowed (line 118) | def test_url_with_dots_allowed(self): method test_url_with_dashes_allowed (line 123) | def test_url_with_dashes_allowed(self): class TestProviderDetection (line 129) | class TestProviderDetection: method test_detect_github (line 132) | def test_detect_github(self): method test_detect_gitlab (line 135) | def test_detect_gitlab(self): method test_detect_bitbucket (line 138) | def test_detect_bitbucket(self): method test_detect_unknown (line 144) | def test_detect_unknown(self): class TestHelperFunctions (line 150) | class TestHelperFunctions: method test_is_commit_sha_valid (line 153) | def test_is_commit_sha_valid(self): method test_is_commit_sha_invalid (line 161) | def test_is_commit_sha_invalid(self): method test_extract_repo_name_owner_repo (line 169) | def test_extract_repo_name_owner_repo(self): method test_extract_repo_name_https_url (line 174) | def test_extract_repo_name_https_url(self): method test_extract_repo_name_windows_file_url (line 180) | def test_extract_repo_name_windows_file_url(self): method test_extract_repo_name_ssh_url (line 184) | def test_extract_repo_name_ssh_url(self): method test_sanitize_dir_name (line 189) | def test_sanitize_dir_name(self): method test_get_unique_dir_name (line 198) | def test_get_unique_dir_name(self): method test_build_clone_url_github_owner_repo_no_token (line 209) | def test_build_clone_url_github_owner_repo_no_token(self): method test_build_clone_url_github_owner_repo_with_token (line 214) | def test_build_clone_url_github_owner_repo_with_token(self): method test_build_clone_url_github_https_with_token (line 219) | def test_build_clone_url_github_https_with_token(self): method test_build_clone_url_gitlab_owner_repo_with_token (line 226) | def test_build_clone_url_gitlab_owner_repo_with_token(self): method test_build_clone_url_gitlab_https_with_token (line 231) | def test_build_clone_url_gitlab_https_with_token(self): method test_build_clone_url_bitbucket_with_token (line 238) | def test_build_clone_url_bitbucket_with_token(self): method test_build_clone_url_no_token_passthrough (line 243) | def test_build_clone_url_no_token_passthrough(self): class TestGetReposContext (line 251) | class TestGetReposContext: method test_empty_mappings (line 254) | def test_empty_mappings(self): method test_single_repo (line 258) | def test_single_repo(self): method test_repo_with_ref (line 273) | def test_repo_with_ref(self): method test_multiple_repos (line 286) | def test_multiple_repos(self): class TestCloneRepos (line 308) | class TestCloneRepos: method test_empty_repos_list (line 311) | def test_empty_repos_list(self): method test_successful_clone (line 320) | def test_successful_clone(self, mock_run): method test_successful_clone_full_url (line 334) | def test_successful_clone_full_url(self, mock_run): method test_clone_with_sha_ref (line 346) | def test_clone_with_sha_ref(self, mock_run): method test_clone_failure (line 358) | def test_clone_failure(self, mock_run): method test_clone_with_token_fetcher (line 371) | def test_clone_with_token_fetcher(self, mock_run): method test_clone_with_provider_specific_token (line 393) | def test_clone_with_provider_specific_token(self, mock_run): method test_directory_name_collision (line 415) | def test_directory_name_collision(self, mock_run): class TestCloudWorkspaceRepoMethods (line 432) | class TestCloudWorkspaceRepoMethods: method test_clone_repos_full_url_list (line 443) | def test_clone_repos_full_url_list(self, mock_secret, mock_clone): method test_clone_repos_dict_list (line 483) | def test_clone_repos_dict_list(self, mock_secret, mock_clone): method test_get_repos_context_from_mappings (line 514) | def test_get_repos_context_from_mappings(self): class TestCloneReposIntegration (line 542) | class TestCloneReposIntegration: method local_git_repo (line 550) | def local_git_repo(self, tmp_path): method test_clone_local_repo (line 601) | def test_clone_local_repo(self, local_git_repo, tmp_path): method test_clone_with_tag_ref (line 619) | def test_clone_with_tag_ref(self, local_git_repo, tmp_path): method test_clone_with_sha_ref (line 642) | def test_clone_with_sha_ref(self, local_git_repo, tmp_path): method test_clone_invalid_url_fails (line 666) | def test_clone_invalid_url_fails(self, tmp_path): method test_clone_duplicate_urls_deduplicated (line 676) | def test_clone_duplicate_urls_deduplicated(self, local_git_repo, tmp_p... FILE: tests/workspace/test_cloud_workspace_sdk_settings.py function mock_workspace (line 27) | def mock_workspace(): class TestGetLLM (line 43) | class TestGetLLM: method test_get_llm_returns_usable_llm (line 46) | def test_get_llm_returns_usable_llm(self, mock_workspace): method test_get_llm_allows_overrides (line 73) | def test_get_llm_allows_overrides(self, mock_workspace): method test_get_llm_no_api_key_still_works (line 92) | def test_get_llm_no_api_key_still_works(self, mock_workspace): method test_get_llm_raises_when_no_sandbox (line 110) | def test_get_llm_raises_when_no_sandbox(self, mock_workspace): class TestGetSecrets (line 117) | class TestGetSecrets: method test_get_all_secrets_returns_lookup_secrets (line 120) | def test_get_all_secrets_returns_lookup_secrets(self, mock_workspace): method test_get_secrets_filters_by_name (line 153) | def test_get_secrets_filters_by_name(self, mock_workspace): method test_get_secrets_empty (line 173) | def test_get_secrets_empty(self, mock_workspace): method test_get_secrets_raises_when_no_sandbox (line 186) | def test_get_secrets_raises_when_no_sandbox(self, mock_workspace): class TestGetMcpConfig (line 193) | class TestGetMcpConfig: method test_get_mcp_config_returns_empty_when_no_config (line 196) | def test_get_mcp_config_returns_empty_when_no_config(self, mock_worksp... method test_get_mcp_config_transforms_sse_servers (line 212) | def test_get_mcp_config_transforms_sse_servers(self, mock_workspace): method test_get_mcp_config_transforms_shttp_servers (line 252) | def test_get_mcp_config_transforms_shttp_servers(self, mock_workspace): method test_get_mcp_config_transforms_stdio_servers (line 283) | def test_get_mcp_config_transforms_stdio_servers(self, mock_workspace): method test_get_mcp_config_mixed_server_types (line 316) | def test_get_mcp_config_mixed_server_types(self, mock_workspace): method test_get_mcp_config_raises_when_no_sandbox (line 345) | def test_get_mcp_config_raises_when_no_sandbox(self, mock_workspace): method test_get_mcp_config_returns_empty_when_all_lists_empty (line 351) | def test_get_mcp_config_returns_empty_when_all_lists_empty(self, mock_... method test_get_mcp_config_is_mcpconfig_compatible (line 370) | def test_get_mcp_config_is_mcpconfig_compatible(self, mock_workspace): class TestRetry (line 403) | class TestRetry: method test_get_llm_retries_on_server_error (line 406) | def test_get_llm_retries_on_server_error(self, mock_workspace): method test_get_llm_no_retry_on_client_error (line 435) | def test_get_llm_no_retry_on_client_error(self, mock_workspace): method test_get_secrets_retries_on_server_error (line 453) | def test_get_secrets_retries_on_server_error(self, mock_workspace): FILE: tests/workspace/test_docker_workspace.py function mock_docker_workspace (line 20) | def mock_docker_workspace(): function test_docker_workspace_import (line 47) | def test_docker_workspace_import(): function test_docker_workspace_inheritance (line 54) | def test_docker_workspace_inheritance(): function test_docker_dev_workspace_import (line 61) | def test_docker_dev_workspace_import(): function test_docker_dev_workspace_inheritance (line 68) | def test_docker_dev_workspace_inheritance(): function test_docker_workspace_no_build_import (line 74) | def test_docker_workspace_no_build_import(): function test_docker_dev_workspace_has_build_fields (line 103) | def test_docker_dev_workspace_has_build_fields(): function test_cleanup_without_image_deletion (line 112) | def test_cleanup_without_image_deletion(mock_docker_workspace): function test_cleanup_with_image_deletion (line 125) | def test_cleanup_with_image_deletion(mock_docker_workspace): function test_docker_network (line 145) | def test_docker_network(mock_docker_workspace): function test_health_check_timeout_default (line 187) | def test_health_check_timeout_default(cls): function test_health_check_timeout_rejects_non_positive (line 193) | def test_health_check_timeout_rejects_non_positive(cls): function test_docker_workspace_startup_uses_health_check_timeout (line 209) | def test_docker_workspace_startup_uses_health_check_timeout(): function test_docker_workspace_resume_uses_health_check_timeout (line 229) | def test_docker_workspace_resume_uses_health_check_timeout(): function test_apptainer_workspace_startup_uses_health_check_timeout (line 249) | def test_apptainer_workspace_startup_uses_health_check_timeout(): FILE: tests/workspace/test_workspace_pause_resume.py function mock_docker_workspace (line 14) | def mock_docker_workspace(): function mock_api_workspace (line 33) | def mock_api_workspace(): function mock_cloud_workspace (line 53) | def mock_cloud_workspace(): function test_local_workspace_pause_is_noop (line 75) | def test_local_workspace_pause_is_noop(): function test_local_workspace_resume_is_noop (line 84) | def test_local_workspace_resume_is_noop(): function test_docker_workspace_pause_calls_docker_pause (line 98) | def test_docker_workspace_pause_calls_docker_pause(mock_docker_workspace): function test_docker_workspace_resume_calls_docker_unpause (line 111) | def test_docker_workspace_resume_calls_docker_unpause(mock_docker_worksp... function test_docker_workspace_pause_raises_if_no_container (line 127) | def test_docker_workspace_pause_raises_if_no_container(): function test_docker_workspace_resume_raises_if_no_container (line 142) | def test_docker_workspace_resume_raises_if_no_container(): function test_api_workspace_pause_calls_api_endpoint (line 162) | def test_api_workspace_pause_calls_api_endpoint(mock_api_workspace): function test_api_workspace_resume_calls_api_endpoint (line 175) | def test_api_workspace_resume_calls_api_endpoint(mock_api_workspace): function test_api_workspace_pause_raises_if_no_runtime (line 185) | def test_api_workspace_pause_raises_if_no_runtime(): function test_api_workspace_resume_raises_if_no_runtime (line 202) | def test_api_workspace_resume_raises_if_no_runtime(): function test_cloud_workspace_pause_raises_not_implemented (line 224) | def test_cloud_workspace_pause_raises_not_implemented(mock_cloud_workspa... function test_cloud_workspace_resume_calls_resume_sandbox (line 232) | def test_cloud_workspace_resume_calls_resume_sandbox(mock_cloud_workspace): function test_cloud_workspace_resume_raises_if_no_sandbox (line 242) | def test_cloud_workspace_resume_raises_if_no_sandbox():