fix(mcp): ruff format remote-mode files; make migration head test revision-agnostic

CI follow-up to the local/remote MCP work:

- Apply ruff format to provider/tools/loaders/mcp.py and the 0006
  normalize-remote-mode migration (Lint job failed on formatting).
- test_migrations.py hardcoded the head revision as 0005_*, which broke
  once 0006 landed. Resolve the actual head from the Alembic
  ScriptDirectory so future migrations don't require editing the test.
This commit is contained in:
RockChinQ
2026-06-21 12:04:37 -04:00
parent 812b1fff4c
commit c689b10c0d
3 changed files with 21 additions and 11 deletions
@@ -191,9 +191,7 @@ class RuntimeMCPSession:
try:
await self.exit_stack.aclose()
except Exception as cleanup_err:
self.ap.logger.debug(
f'MCP server {self.server_name}: error cleaning up before SSE fallback: {cleanup_err}'
)
self.ap.logger.debug(f'MCP server {self.server_name}: error cleaning up before SSE fallback: {cleanup_err}')
self.exit_stack = AsyncExitStack()
self.session = None