Automate browser based workflows with AI
Python aiapiautomationbrowserbrowser-automationcomputergptllmplaywrightpowerautomatepuppeteerpythonrpaseleniumvisionworkflow
Reserve 500m CPU per secure CodeBlock runner pod and run 37 replicas on the same node (SKY-17700) (#8784)
Shuchang Zheng4ef05fab3432
diff --git a/tests/unit/test_copilot_model_telemetry.py b/tests/unit/test_copilot_model_telemetry.pyindex 4c6b9b2e3..053542107 100644--- a/tests/unit/test_copilot_model_telemetry.py+++ b/tests/unit/test_copilot_model_telemetry.py@@ -9,7 +9,6 @@ from types import SimpleNamespacefrom typing import Any, Self, castfrom unittest.mock import AsyncMock, MagicMock-import litellmimport pytestfrom agents import ItemHelpers, ModelSettings, RunContextWrapper, function_toolfrom agents.extensions.models.litellm_model import LitellmModel@@ -17,7 +16,6 @@ from agents.items import TResponseInputItemfrom agents.mcp import MCPServer, MCPUtilfrom agents.models.interface import ModelTracingfrom litellm.integrations.anthropic_cache_control_hook import AnthropicCacheControlHook-from litellm.llms.anthropic.chat.transformation import AnthropicConfigfrom litellm.llms.vertex_ai.gemini.transformation import _gemini_convert_messages_with_historyfrom litellm.types.llms.openai import ResponsesAPIResponsefrom litellm.types.utils import Delta@@ -670,33 +668,6 @@ def test_model_call_cost_uses_runtime_litellm_pricing(monkeypatch: pytest.Monkey}-def test_anthropic_cache_writes_and_reads_are_priced_at_their_own_rates() -> None:- usage = AnthropicConfig().calculate_usage(- usage_object={- "input_tokens": 1200,- "cache_creation_input_tokens": 3000,- "cache_read_input_tokens": 20000,- "output_tokens": 400,- },- reasoning_content=None,- )- telemetry = model_telemetry_module.CopilotModelCallTelemetry(model_call_index=1)- telemetry.capture(usage)- rates = litellm.model_cost["claude-sonnet-5-5"]-- assert (rates["cache_creation_input_token_cost"], rates["cache_read_input_token_cost"]) == (- pytest.approx(1.25 * rates["input_cost_per_token"]),- pytest.approx(0.1 * rates["input_cost_per_token"]),- )- assert (telemetry.cache_read_tokens, telemetry.cache_write_tokens) == (20000, 3000)- assert model_telemetry_module._model_call_cost(telemetry, "claude-sonnet-5-5") == pytest.approx(- 1200 * rates["input_cost_per_token"]- + 3000 * rates["cache_creation_input_token_cost"]- + 20000 * rates["cache_read_input_token_cost"]- + 400 * rates["output_cost_per_token"]- )--def test_model_call_cost_normalizes_dated_gpt56_response_model(monkeypatch: pytest.MonkeyPatch) -> None:priced_models: list[str] = []