Skip to content

chore: release v0.1.20#271

Merged
memtomem merged 1 commit intomainfrom
chore/release-v0.1.20
Apr 27, 2026
Merged

chore: release v0.1.20#271
memtomem merged 1 commit intomainfrom
chore/release-v0.1.20

Conversation

@memtomem
Copy link
Copy Markdown
Owner

Summary

Release v0.1.20. Two new config-load validators harden upstream prefix handling, plus a CLI dispatch parity fix, the 64-char tool name overflow guard, and a test-suite flake fix accumulated since v0.1.19.

Headline

  • Duplicate upstream prefix → ValidationError at config load (proxy/config: fail-fast on duplicate upstream prefixes #265). Two upstreams sharing a prefix used to silently drop the second-loaded duplicate at ProxyManager.start() with only a logger.warning. The new @model_validator(mode="after") on ProxyConfig raises with every collision group named in one error so both the upstream dict keys (what the user edited) and the prefix value (what collides) surface together. Hot-reload (ProxyConfigLoader.get) keeps the previous good config on validation failure.
  • Empty / whitespace-only upstream prefix → ValidationError at config load (proxy/config: reject empty upstream prefix #266). prefix="" used to validate fine and produce composed names like __list_items that surfaced as broken entries in tools/list, also skewing the 64-char overflow guard. Sibling validator placed before the uniqueness check so a prefix=""/prefix="" pair surfaces the more actionable empty error rather than the duplicate one.
  • Tool name overflow check against the 64-char MCP limit (mms add: validate composed proxied tool name against 64-char MCP regex #261). Three layers: mms add rejects prefixes that guarantee overflow; ProxyManager._connect_server per-tool checks the composed length at boot and skips offending tools (better one missing tool than the whole upstream); mms health --names re-runs the check on demand. MMS_CLIENT_SERVER_NAME env var lets users who registered STM under a shorter alias get accurate budget arithmetic.
  • All three console scripts now boot the MCP stdio server when invoked bare with a piped stdin (mms / memtomem-stm-proxy bare invocation: dispatch parity with memtomem-stm as MCP stdio server #260). Previously only memtomem-stm worked as an MCP-server registration target; memtomem-stm-proxy and mms resolved to the Click group whose bare invocation printed help and exited 2. Now all three [project.scripts] entry points dispatch identically based on sys.stdin.isatty().

Internal

  • TestAutoIndexStartupWarning no longer flakes under full-suite event-loop pressure (test: TestAutoIndexStartupWarning leaks asyncio.CancelledError past except-Exception #264). The MCP SDK's stdio reader can surface echo-upstream handshake failure as asyncio.CancelledError (BaseException); try/except Exception didn't catch it. Catch widened to (Exception, asyncio.CancelledError) with a comment naming the SDK cancellation path. No production code touched.
  • Docs sync (docs: surface mms health --names and upstream prefix invariants #270). mms health --names flag and the new prefix invariants are now documented in docs/cli.md and docs/configuration.md respectively. The pre-existing hot-reload paragraph was promoted to its own subheading so the new prefix invariants subsection has a structural peer.

Behavior change

  • Configs that used to load with silent partial drops (proxy/config: fail-fast on duplicate upstream prefixes #265) or visually broken composed names from prefix="" (proxy/config: reject empty upstream prefix #266) now fail at startup with ValidationError. Hot-reload retains the last-good config on validation failure, so a running proxy keeps serving its last known-good upstreams instead of going dark.
  • Upstreams whose composed name exceeds 64 chars are now skipped at boot with a WARNING log naming the tool and the suggested fix; previously the tool just disappeared from the client's catalogue.
  • mms and memtomem-stm-proxy registered as an MCP client's command now boot the stdio server identically to memtomem-stm instead of failing with : calling "initialize": EOF.
  • No SQLite migration. No env-var rename. No new MCP tool.

Test plan

  • uv run pytest -m "not ollama" -q — 1751/1751 pass on this branch
  • uv run ruff check src && uv run ruff format --check src — clean
  • uv lock resolves cleanly, memtomem-stm package version bumped to 0.1.20

Post-merge release steps

  1. Tag v0.1.20 and push — trusted-publisher OIDC publishes to PyPI (PyPI environment approval gate required, see reference_pypi_publish.md).
  2. gh release create v0.1.20 (Release is not auto-created from the tag — reference_github_release.md).

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@memtomem memtomem merged commit 05d0b85 into main Apr 27, 2026
6 checks passed
@memtomem memtomem deleted the chore/release-v0.1.20 branch April 27, 2026 14:16
@github-actions github-actions Bot locked and limited conversation to collaborators Apr 27, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants