diff --git a/package.json b/package.json index ac4b15d..a0cc982 100644 --- a/package.json +++ b/package.json @@ -10,7 +10,7 @@ "@hono/mcp": "0.1.5", "@hono/node-server": "^2.1.6", "@modelcontextprotocol/sdk": "1.32.2", - "hono": "4.13.16", + "hono": "4.13.17", "tsx": "^4.23.15", "zod": "4.6.7" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 34dc630..ec8baa8 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -10,16 +10,16 @@ importers: devDependencies: '@hono/mcp': specifier: 0.1.5 - version: 0.1.5(@modelcontextprotocol/sdk@1.32.2(zod@4.6.7))(hono@4.13.16) + version: 0.1.5(@modelcontextprotocol/sdk@1.32.2(zod@4.6.7))(hono@4.13.17) '@hono/node-server': specifier: ^2.1.6 - version: 2.1.6(hono@4.13.16) + version: 2.1.6(hono@4.13.17) '@modelcontextprotocol/sdk': specifier: 1.32.2 version: 1.32.2(zod@4.6.7) hono: - specifier: 4.13.16 - version: 4.13.16 + specifier: 4.13.17 + version: 4.13.17 node: specifier: runtime:22.23.5 version: runtime:22.23.5 @@ -381,8 +381,8 @@ packages: resolution: {integrity: sha512-T2UbfbBEF32wiepXIsMlTW9+dDYC6wMh/t/vYA4tuOMKqWz/n3vr1NFSxQiyP+zk2mXsoMA/i/7qV6LKut1t1A==} engines: {node: '>= 0.4'} - hono@4.13.16: - resolution: {integrity: sha512-AOLOEhvrV+iH92xXCnFr/5+3KjPKcI3xP63XJtX5spAnkznPdHijlIsUTpi7/9EhWqrTCekw5c5zh1K+YsVw7A==} + hono@4.13.17: + resolution: {integrity: sha512-vZIcbkvjOR5hHRWERbGkr8fGfF0GGM1ooYkuH448iO3b2AdVEr3AXZSw4Z3Kn+1L5z0CVoVeyV29VGYmFh05kQ==} engines: {node: '>=16.9.0'} http-errors@2.0.1: @@ -790,18 +790,18 @@ snapshots: '@esbuild/win32-x64@0.28.2': optional: true - '@hono/mcp@0.1.5(@modelcontextprotocol/sdk@1.32.2(zod@4.6.7))(hono@4.13.16)': + '@hono/mcp@0.1.5(@modelcontextprotocol/sdk@1.32.2(zod@4.6.7))(hono@4.13.17)': dependencies: '@modelcontextprotocol/sdk': 1.32.2(zod@4.6.7) - hono: 4.13.16 + hono: 4.13.17 - '@hono/node-server@2.1.6(hono@4.13.16)': + '@hono/node-server@2.1.6(hono@4.13.17)': dependencies: - hono: 4.13.16 + hono: 4.13.17 '@modelcontextprotocol/sdk@1.32.2(zod@4.6.7)': dependencies: - '@hono/node-server': 2.1.6(hono@4.13.16) + '@hono/node-server': 2.1.6(hono@4.13.17) ajv: 8.20.0 ajv-formats: 3.0.1(ajv@8.20.0) content-type: 1.0.5 @@ -811,7 +811,7 @@ snapshots: eventsource-parser: 3.1.1 express: 5.3.0 express-rate-limit: 8.7.3(express@5.3.0) - hono: 4.13.16 + hono: 4.13.17 jose: 6.2.15 json-schema-typed: 8.0.2 pkce-challenge: 5.0.1 @@ -1038,7 +1038,7 @@ snapshots: dependencies: function-bind: 1.1.2 - hono@4.13.16: {} + hono@4.13.17: {} http-errors@2.0.1: dependencies: diff --git a/tests/test_end_user_id.py b/tests/test_end_user_id.py index a7b0a9c..0d9afed 100644 --- a/tests/test_end_user_id.py +++ b/tests/test_end_user_id.py @@ -728,9 +728,9 @@ def test_requests_refused_together_share_one_accounts_listing(self, monkeypatch) class Listing(concurrent.futures.Future): # type: ignore[type-arg] def result(self, timeout: float | None = None) -> Any: - # The owner waits only once its own GET /accounts is done, so a wait while it - # is still held is the other account's, joining it. - joined.set() + # Only a waiter on this accounts listing can release its HTTP response. + if self is toolset._fetching_accounts: + joined.set() return super().result(timeout) monkeypatch.setattr(concurrent.futures, "Future", Listing) @@ -747,7 +747,8 @@ def handle(_self: Any, request: httpx.Request) -> httpx.Response: monkeypatch.setattr(httpx.HTTPTransport, "handle_request", handle) mcp = _GuardedMcp(monkeypatch, {"a": "user-a", "b": "user-b"}) - tools = StackOneToolSet(api_key="k").fetch_tools(account_ids=["a", "b"]) + toolset = StackOneToolSet(api_key="k") + tools = toolset.fetch_tools(account_ids=["a", "b"]) assert sorted(t.name for t in tools) == ["tool_a", "tool_b"] assert len(calls) == 1 assert sorted((h["x-account-id"], h.get("x-end-user-id", "")) for h in mcp.listed) == [