reflex-mcphost 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (111) hide show
  1. reflex_mcphost-0.1.0/.gitignore +227 -0
  2. reflex_mcphost-0.1.0/CHANGELOG.md +174 -0
  3. reflex_mcphost-0.1.0/LICENSE +21 -0
  4. reflex_mcphost-0.1.0/PKG-INFO +303 -0
  5. reflex_mcphost-0.1.0/README.md +262 -0
  6. reflex_mcphost-0.1.0/pyproject.toml +187 -0
  7. reflex_mcphost-0.1.0/src/reflex_mcphost/__init__.py +296 -0
  8. reflex_mcphost-0.1.0/src/reflex_mcphost/adapters/__init__.py +1 -0
  9. reflex_mcphost-0.1.0/src/reflex_mcphost/adapters/langgraph.py +77 -0
  10. reflex_mcphost-0.1.0/src/reflex_mcphost/adapters/pydantic_ai.py +90 -0
  11. reflex_mcphost-0.1.0/src/reflex_mcphost/app/__init__.py +1 -0
  12. reflex_mcphost-0.1.0/src/reflex_mcphost/app/cli.py +619 -0
  13. reflex_mcphost-0.1.0/src/reflex_mcphost/app/web/__init__.py +7 -0
  14. reflex_mcphost-0.1.0/src/reflex_mcphost/app/web/mcphost_app/__init__.py +1 -0
  15. reflex_mcphost-0.1.0/src/reflex_mcphost/app/web/mcphost_app/mcphost_app.py +170 -0
  16. reflex_mcphost-0.1.0/src/reflex_mcphost/app/web/rxconfig.py +35 -0
  17. reflex_mcphost-0.1.0/src/reflex_mcphost/app/workspace.py +215 -0
  18. reflex_mcphost-0.1.0/src/reflex_mcphost/core/__init__.py +4 -0
  19. reflex_mcphost-0.1.0/src/reflex_mcphost/core/apps/__init__.py +9 -0
  20. reflex_mcphost-0.1.0/src/reflex_mcphost/core/apps/bridge.py +612 -0
  21. reflex_mcphost-0.1.0/src/reflex_mcphost/core/apps/constants.py +86 -0
  22. reflex_mcphost-0.1.0/src/reflex_mcphost/core/apps/csp.py +177 -0
  23. reflex_mcphost-0.1.0/src/reflex_mcphost/core/apps/messages.py +163 -0
  24. reflex_mcphost-0.1.0/src/reflex_mcphost/core/apps/resource.py +102 -0
  25. reflex_mcphost-0.1.0/src/reflex_mcphost/core/audit.py +473 -0
  26. reflex_mcphost-0.1.0/src/reflex_mcphost/core/auth/__init__.py +1 -0
  27. reflex_mcphost-0.1.0/src/reflex_mcphost/core/auth/callback_server.py +277 -0
  28. reflex_mcphost-0.1.0/src/reflex_mcphost/core/auth/flow.py +84 -0
  29. reflex_mcphost-0.1.0/src/reflex_mcphost/core/auth/oauth.py +578 -0
  30. reflex_mcphost-0.1.0/src/reflex_mcphost/core/auth/token_store.py +323 -0
  31. reflex_mcphost-0.1.0/src/reflex_mcphost/core/catalog.py +852 -0
  32. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/__init__.py +1 -0
  33. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/claude.py +18 -0
  34. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/common.py +310 -0
  35. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/cursor.py +18 -0
  36. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/expand.py +69 -0
  37. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/mcp_json.py +33 -0
  38. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/models.py +292 -0
  39. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/own.py +497 -0
  40. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/paths.py +124 -0
  41. reflex_mcphost-0.1.0/src/reflex_mcphost/core/config/vscode.py +19 -0
  42. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/__init__.py +1 -0
  43. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/era_cache.py +183 -0
  44. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/inflight.py +89 -0
  45. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/lease.py +71 -0
  46. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/manager.py +458 -0
  47. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/state.py +87 -0
  48. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/stderr.py +164 -0
  49. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/supervisor.py +926 -0
  50. reflex_mcphost-0.1.0/src/reflex_mcphost/core/connection/transports.py +364 -0
  51. reflex_mcphost-0.1.0/src/reflex_mcphost/core/consent/__init__.py +5 -0
  52. reflex_mcphost-0.1.0/src/reflex_mcphost/core/consent/index.py +152 -0
  53. reflex_mcphost-0.1.0/src/reflex_mcphost/core/consent/models.py +243 -0
  54. reflex_mcphost-0.1.0/src/reflex_mcphost/core/consent/outcome.py +39 -0
  55. reflex_mcphost-0.1.0/src/reflex_mcphost/core/consent/policy.py +370 -0
  56. reflex_mcphost-0.1.0/src/reflex_mcphost/core/consent/preview.py +224 -0
  57. reflex_mcphost-0.1.0/src/reflex_mcphost/core/consent/store.py +328 -0
  58. reflex_mcphost-0.1.0/src/reflex_mcphost/core/db.py +121 -0
  59. reflex_mcphost-0.1.0/src/reflex_mcphost/core/db_models.py +84 -0
  60. reflex_mcphost-0.1.0/src/reflex_mcphost/core/errors.py +156 -0
  61. reflex_mcphost-0.1.0/src/reflex_mcphost/core/events.py +211 -0
  62. reflex_mcphost-0.1.0/src/reflex_mcphost/core/handlers/__init__.py +1 -0
  63. reflex_mcphost-0.1.0/src/reflex_mcphost/core/handlers/base.py +37 -0
  64. reflex_mcphost-0.1.0/src/reflex_mcphost/core/handlers/capabilities.py +89 -0
  65. reflex_mcphost-0.1.0/src/reflex_mcphost/core/handlers/elicitation.py +218 -0
  66. reflex_mcphost-0.1.0/src/reflex_mcphost/core/handlers/logging.py +48 -0
  67. reflex_mcphost-0.1.0/src/reflex_mcphost/core/handlers/roots.py +105 -0
  68. reflex_mcphost-0.1.0/src/reflex_mcphost/core/handlers/sampling.py +336 -0
  69. reflex_mcphost-0.1.0/src/reflex_mcphost/core/hmac_key.py +71 -0
  70. reflex_mcphost-0.1.0/src/reflex_mcphost/core/host.py +559 -0
  71. reflex_mcphost-0.1.0/src/reflex_mcphost/core/invoker.py +817 -0
  72. reflex_mcphost-0.1.0/src/reflex_mcphost/core/logging.py +162 -0
  73. reflex_mcphost-0.1.0/src/reflex_mcphost/core/migrations/0001_initial.py +144 -0
  74. reflex_mcphost-0.1.0/src/reflex_mcphost/core/migrations/__init__.py +5 -0
  75. reflex_mcphost-0.1.0/src/reflex_mcphost/core/migrations/runner.py +128 -0
  76. reflex_mcphost-0.1.0/src/reflex_mcphost/core/mrtr.py +504 -0
  77. reflex_mcphost-0.1.0/src/reflex_mcphost/core/outcomes.py +42 -0
  78. reflex_mcphost-0.1.0/src/reflex_mcphost/core/prompter.py +213 -0
  79. reflex_mcphost-0.1.0/src/reflex_mcphost/core/registry.py +387 -0
  80. reflex_mcphost-0.1.0/src/reflex_mcphost/core/schema.py +743 -0
  81. reflex_mcphost-0.1.0/src/reflex_mcphost/core/secret_store.py +150 -0
  82. reflex_mcphost-0.1.0/src/reflex_mcphost/core/secrets.py +64 -0
  83. reflex_mcphost-0.1.0/src/reflex_mcphost/core/toolset/__init__.py +11 -0
  84. reflex_mcphost-0.1.0/src/reflex_mcphost/core/toolset/aliases.py +74 -0
  85. reflex_mcphost-0.1.0/src/reflex_mcphost/core/toolset/filters.py +38 -0
  86. reflex_mcphost-0.1.0/src/reflex_mcphost/core/toolset/toolset.py +193 -0
  87. reflex_mcphost-0.1.0/src/reflex_mcphost/core/trust.py +269 -0
  88. reflex_mcphost-0.1.0/src/reflex_mcphost/core/types.py +101 -0
  89. reflex_mcphost-0.1.0/src/reflex_mcphost/py.typed +0 -0
  90. reflex_mcphost-0.1.0/src/reflex_mcphost/toolset/__init__.py +12 -0
  91. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/__init__.py +60 -0
  92. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/actions.py +340 -0
  93. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/apps_bridge.py +474 -0
  94. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/assets/__init__.py +38 -0
  95. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/assets/mcp_app_relay.js +93 -0
  96. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/__init__.py +23 -0
  97. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/audit_table.py +136 -0
  98. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/catalog_browser.py +361 -0
  99. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/consent_center.py +468 -0
  100. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/filters.py +9 -0
  101. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/mcp_app_frame.py +160 -0
  102. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/permissions_table.py +131 -0
  103. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/schema_form.py +148 -0
  104. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/components/servers_panel.py +250 -0
  105. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/install.py +440 -0
  106. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/models.py +1169 -0
  107. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/prompter.py +346 -0
  108. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/proxy/__init__.py +23 -0
  109. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/proxy/proxy.html +117 -0
  110. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/proxy/server.py +457 -0
  111. reflex_mcphost-0.1.0/src/reflex_mcphost/ui/state.py +1015 -0
@@ -0,0 +1,227 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[codz]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # PyInstaller
30
+ # Usually these files are written by a python script from a template
31
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
32
+ *.manifest
33
+ *.spec
34
+
35
+ # Installer logs
36
+ pip-log.txt
37
+ pip-delete-this-directory.txt
38
+
39
+ # Unit test / coverage reports
40
+ htmlcov/
41
+ .tox/
42
+ .nox/
43
+ .coverage
44
+ .coverage.*
45
+ .cache
46
+ nosetests.xml
47
+ coverage.xml
48
+ *.cover
49
+ *.py.cover
50
+ *.lcov
51
+ .hypothesis/
52
+ .pytest_cache/
53
+ cover/
54
+
55
+ # Translations
56
+ *.mo
57
+ *.pot
58
+
59
+ # Django stuff:
60
+ *.log
61
+ local_settings.py
62
+ db.sqlite3
63
+ db.sqlite3-journal
64
+
65
+ # Flask stuff:
66
+ instance/
67
+ .webassets-cache
68
+
69
+ # Scrapy stuff:
70
+ .scrapy
71
+
72
+ # Sphinx documentation
73
+ docs/_build/
74
+
75
+ # PyBuilder
76
+ .pybuilder/
77
+ target/
78
+
79
+ # Jupyter Notebook
80
+ .ipynb_checkpoints
81
+
82
+ # IPython
83
+ profile_default/
84
+ ipython_config.py
85
+
86
+ # pyenv
87
+ # For a library or package, you might want to ignore these files since the code is
88
+ # intended to run in multiple environments; otherwise, check them in:
89
+ # .python-version
90
+
91
+ # pipenv
92
+ # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
93
+ # However, in case of collaboration, if having platform-specific dependencies or dependencies
94
+ # having no cross-platform support, pipenv may install dependencies that don't work, or not
95
+ # install all needed dependencies.
96
+ # Pipfile.lock
97
+
98
+ # uv
99
+ # Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
100
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
101
+ # commonly ignored for libraries.
102
+ # uv.lock
103
+
104
+ # poetry
105
+ # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
106
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
107
+ # commonly ignored for libraries.
108
+ # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
109
+ # poetry.lock
110
+ # poetry.toml
111
+
112
+ # pdm
113
+ # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
114
+ # pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
115
+ # https://pdm-project.org/en/latest/usage/project/#working-with-version-control
116
+ # pdm.lock
117
+ # pdm.toml
118
+ .pdm-python
119
+ .pdm-build/
120
+
121
+ # pixi
122
+ # Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
123
+ # pixi.lock
124
+ # Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
125
+ # in the .venv directory. It is recommended not to include this directory in version control.
126
+ .pixi/*
127
+ !.pixi/config.toml
128
+
129
+ # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
130
+ __pypackages__/
131
+
132
+ # Celery stuff
133
+ celerybeat-schedule*
134
+ celerybeat.pid
135
+
136
+ # Redis
137
+ *.rdb
138
+ *.aof
139
+ *.pid
140
+
141
+ # RabbitMQ
142
+ mnesia/
143
+ rabbitmq/
144
+ rabbitmq-data/
145
+
146
+ # ActiveMQ
147
+ activemq-data/
148
+
149
+ # SageMath parsed files
150
+ *.sage.py
151
+
152
+ # Environments
153
+ .env
154
+ .envrc
155
+ .venv
156
+ env/
157
+ venv/
158
+ ENV/
159
+ env.bak/
160
+ venv.bak/
161
+
162
+ # Spyder project settings
163
+ .spyderproject
164
+ .spyproject
165
+
166
+ # Rope project settings
167
+ .ropeproject
168
+
169
+ # mkdocs/Zensical documentation
170
+ /site
171
+
172
+ # mypy
173
+ .mypy_cache/
174
+ .dmypy.json
175
+ dmypy.json
176
+
177
+ # Pyre type checker
178
+ .pyre/
179
+
180
+ # pytype static type analyzer
181
+ .pytype/
182
+
183
+ # Cython debug symbols
184
+ cython_debug/
185
+
186
+ # PyCharm
187
+ # JetBrains specific template is maintained in a separate JetBrains.gitignore that can
188
+ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
189
+ # and can be added to the global gitignore or merged into this file. For a more nuclear
190
+ # option (not recommended) you can uncomment the following to ignore the entire idea folder.
191
+ # .idea/
192
+
193
+ # Abstra
194
+ # Abstra is an AI-powered process automation framework.
195
+ # Ignore directories containing user credentials, local state, and settings.
196
+ # Learn more at https://abstra.io/docs
197
+ .abstra/
198
+
199
+ # Visual Studio Code
200
+ # Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore that
201
+ # can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
202
+ # and can be added to the global gitignore or merged into this file. However, if you prefer, you
203
+ # could uncomment the following to ignore the entire vscode folder
204
+ # .vscode/
205
+ # Temporary file for partial code execution
206
+ tempCodeRunnerFile.py
207
+
208
+ # Ruff stuff:
209
+ .ruff_cache/
210
+
211
+ # PyPI configuration file
212
+ .pypirc
213
+
214
+ # Marimo
215
+ marimo/_static/
216
+ marimo/_lsp/
217
+ __marimo__/
218
+
219
+ # Streamlit
220
+ .streamlit/secrets.toml
221
+
222
+ # reflex-mcphost
223
+ /spikes/
224
+ .web/
225
+ coverage.json
226
+ .idea/
227
+ .claude/worktrees/
@@ -0,0 +1,174 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project are documented in this file.
4
+ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the
5
+ project adheres to [Semantic Versioning](https://semver.org/) (Constitution Art. 9).
6
+
7
+ ## [Unreleased]
8
+
9
+ ## [0.1.0] - 2026-11-01
10
+
11
+ First release (date set in the release PR, F8-07b); no `0.1.0a1` / `0.1.0b1`
12
+ pre-releases were published (owner decision 2026-11-01). Highlights: an MCP **host** on both
13
+ protocol eras (`2026-07-28`, `2025-11-25`) over stdio and Streamable HTTP, a fail-closed
14
+ consent layer with a local audit log, OAuth 2.1 for remote Servers, an agent bridge
15
+ (`Toolset`, PydanticAI, LangGraph), an embeddable Reflex UI with the `reflex-mcphost`
16
+ reference app and CLI, and MCP Apps (`2026-01-26`) in sandboxed Views.
17
+
18
+ ### Added
19
+ - Project scaffold: `pyproject.toml` (hatchling, src layout, extras `pydantic-ai`,
20
+ `langgraph`, `all`; dependency groups `dev`, `test`, `docs`), package skeleton.
21
+ - Agent bridge (Phase 5): `Host.toolset(consumer, include=, exclude=)` and
22
+ `reflex_mcphost.toolset` (`Toolset`, `ToolSpec`, `ToolCallOutcome`) — live listing of
23
+ model-visible tools of ready Servers, deterministic collision-free aliases
24
+ (`^[A-Za-z0-9_-]{1,64}$`), FQN / server-id glob filters, calls only through the
25
+ consent-checked `Invoker`, every outcome (including denial) returned as agent text.
26
+ - `reflex_mcphost.adapters.pydantic_ai.as_pydantic_ai_toolset` (extra `pydantic-ai`): a
27
+ PydanticAI `AbstractToolset`, re-listed every run step; errors as `ToolFailed`.
28
+ - `reflex_mcphost.adapters.langgraph.as_langchain_tools` (extra `langgraph`): async-only
29
+ LangChain `BaseTool`s with the Server's JSON schema; errors as
30
+ `ToolMessage(status="error")`, so a LangGraph `ToolNode` never fails the graph.
31
+ - `AuthorizationFlow` and `SamplingProvider` are exported from `reflex_mcphost`.
32
+ - `docs/library.md`: using the Host from PydanticAI and LangGraph agents.
33
+ - Reflex UI (Phase 6, `reflex_mcphost.ui`): `install(app, host_factory)` (one Host per
34
+ backend as a lifespan task, `ReflexPrompter` bound, Host/Origin loopback guard from the
35
+ Reflex `deploy_url`), the components `servers_panel`, `catalog_browser`,
36
+ `consent_center`, `permissions_table` and `audit_table`, `HostState` and `HostRuntime`;
37
+ embeddable in any Reflex app.
38
+ - CLI `reflex-mcphost` (API §6): `run` (also the bare command; `--host`, `--port`,
39
+ `--no-browser`, `--config`, `--unsafe-allow-remote`, `--log-json`; UI and backend on one
40
+ loopback port, exit codes 0/2/3), `servers [--json] [--strict] [--config]` and
41
+ `--version`. The packaged reference app (Servers, Catalog, Permissions, Audit) runs from
42
+ a per-user workspace, never from site-packages.
43
+ - E2E tests (marker `e2e`, CI job `e2e`): headless smoke of the built wheel and Playwright
44
+ flows; `playwright` joins the `test` dependency group.
45
+ - MCP Apps (Phase 7, MCP Apps `2026-01-26`): an allowed invocation started from the Host
46
+ UI of a tool with `_meta.ui.resourceUri` renders the Server's App as a View after it
47
+ ends (`mcp_app_frame()`, shown by `catalog_browser`; one View per tab). Views run in a
48
+ sandbox proxy on `http://localhost:<proxy_port>` (an origin distinct from the UI's
49
+ `http://127.0.0.1:<port>`, served by a minimal `h11` listener on `127.0.0.1` and `::1`)
50
+ inside an opaque-origin `srcdoc` frame (`sandbox="allow-scripts"`, no device
51
+ permissions) with a CSP built only from the resource's validated `_meta.ui.csp` entries
52
+ (invalid entries are left out, logged and listed in a notice; no `'unsafe-eval'`).
53
+ - App bridge: `ui/initialize`, `tool-input` / `tool-result` / `tool-cancelled`,
54
+ `ui/resource-teardown` (`replaced`, `closed`, `server_removed`, `host_closing`; ≤ 2 s),
55
+ `tools/call` through the `Invoker` as the Consumer `app:<server_id>` (consent card and
56
+ audit record per call; only the View's own Server and App-visible tools), `resources/read`,
57
+ `ui/open-link` (`http`/`https` only, after a confirmation showing the full URL),
58
+ `notifications/message` and `size-changed`; every View RPC is logged as
59
+ `method → outcome` in the Server's log stream, never with its content. The relay on the
60
+ UI origin is data-only and accepts messages only from the proxy window it created.
61
+ - The Client declares the `io.modelcontextprotocol/ui` extension (both eras) only while
62
+ Views can render (`Host.set_mcp_apps`).
63
+ - Resource limits (API §7): no View for a resource without content for its URI, of another
64
+ MIME type, not valid UTF-8 or larger than 5 MiB — a notice names the reason; a 1 MiB
65
+ message limit on the relay.
66
+ - `scripts/check_wheel.py` requires the MCP Apps assets
67
+ (`reflex_mcphost/ui/proxy/proxy.html`, `reflex_mcphost/ui/assets/mcp_app_relay.js`) in
68
+ the wheel.
69
+ - E2E: MCP Apps on Chromium, Firefox and WebKit (the S-3 isolation and forgery contract);
70
+ the CI `e2e` job installs the three engines.
71
+
72
+ - Hardening (Phase 8):
73
+ - Server-provided regular expressions (`pattern`, `patternProperties`, `format: regex`
74
+ checks) run only through the `regex` engine with a 50 ms per-match and 250 ms
75
+ per-validation bound; a catastrophic pattern ends the request instead of blocking the
76
+ event loop. New runtime dependency `regex>=2026.9`.
77
+ - The `Invoker` re-resolves a tool after consent (step 4a): a definition that changed
78
+ while the prompt was open denies the call (`definition_changed`, one audit record, no
79
+ second prompt).
80
+ - Every stdio transport close signals the Server's whole process group (POSIX) / Job
81
+ Object (Windows), so grandchildren of a Server do not outlive it.
82
+ - `UnknownToolError` (also a `KeyError`) for an alias not in the current `Toolset`
83
+ listing; `SecretStoreError` when a sign-out cannot delete the stored credentials.
84
+ - Event `consent.rules_changed` (`ConsentRulesChanged`, exported from `reflex_mcphost`
85
+ like every other event; rule ids and change kind, never argument values); the
86
+ Permissions view refreshes in every tab.
87
+ - Client ID Metadata Document URL (the default `oauth_client_metadata_url`, frozen from
88
+ this release on): `https://blog.seraph.to/reflex-mcphost/oauth/client.json` (GitHub
89
+ Pages under the owner's custom domain; the `github.io` address redirects, which a CIMD
90
+ `client_id` must not).
91
+ - `AuthorizationError` reason `secret_store_unavailable`: an authorization whose stored
92
+ credentials cannot be read (e.g. a locked keyring) says so instead of
93
+ `discovery_failed` (no backend text).
94
+ - The UI guard adds `Referrer-Policy: no-referrer` to every response; `install()` refuses
95
+ to start with a state manager other than MEMORY.
96
+ - The sandbox proxy caps concurrent connections at 32 (`503`, `Retry-After: 1`); a View
97
+ that navigates its own frame away is closed.
98
+ - The CLI prunes workspaces of other versions unused for 7 days (and interrupted build
99
+ leftovers after 1 day); only directories it created and marked.
100
+ - `docs/user-guide.md` (the reference app) and the embedder rules in `docs/library.md`;
101
+ README and docs examples are executed by the test suite.
102
+ - `release.yml` job `verify`: after `publish`, installs the release from PyPI on Linux,
103
+ macOS and Windows and runs `--version`, `servers --json` and (Linux) `run --no-browser`
104
+ until `/ping` answers; it holds no `id-token`.
105
+
106
+ ### Changed
107
+ - Development status classifier: `4 - Beta`.
108
+ - The `mcp` SDK's own tool-result validation is turned off per session; the Invoker's
109
+ bounded output-schema check is the only one (the SDK's would run Server patterns
110
+ unbounded). A failing result is `protocol_error` with code `output_schema_mismatch` or
111
+ `missing_structured_content`, and its content is dropped.
112
+ - The adapters convert only `UnknownToolError` into "Tool is no longer available"; any
113
+ other exception propagates.
114
+ - CI: the REQ-coverage gate is strict for every requirement family; a `ResourceWarning`
115
+ fails the test run.
116
+
117
+ ### Fixed
118
+ - Catalog view: the list now re-renders when the catalog changes (explicit dependencies of
119
+ `HostState.catalog_shown` / `catalog_more`).
120
+ - Consent center: elicitation, sampling-edit and review-edit forms submit again (the card id
121
+ travels in a hidden field; the browser raised `card_rx_state_ is not defined`).
122
+ - Sandbox proxy: Views render in Firefox (Firefox reports the proxy frame's
123
+ `location.ancestorOrigins` as `"null"` for the relay's `referrerpolicy="no-referrer"`
124
+ iframe, which the proxy took for a foreign embedder).
125
+ - Sign-out forgets the in-memory tokens before deleting the stored ones: a secret store
126
+ that fails during sign-out can no longer leave the Server signed in.
127
+ - A refused authorization URL cancels the OAuth flow at once (the Server is back in
128
+ `auth_required` and Authorize works again) instead of waiting for the flow's deadline.
129
+ - Links opened from an MCP App View no longer send the Host UI's address as referrer.
130
+
131
+ ### Known limitations
132
+ - JSON Schema `format` is not enforced (annotation only) for tool arguments and results.
133
+ - Token expiry is unknown after a restart: tokens reloaded from the secret store carry no
134
+ expiry, so the first `401` triggers the one refresh instead of a proactive one.
135
+ - A Server that re-prompts an elicitation (invalid content) gets a new consent card with
136
+ the same id; the previous form is not kept open.
137
+ - Server media in results: only `data:` images of type PNG, JPEG, GIF or WebP up to
138
+ 8 MiB are shown; SVG and other types are a placeholder naming the type.
139
+ - `ui/notifications/host-context-changed` is never sent to Views (fixed light theme, no
140
+ container size reports).
141
+ - The E2E suite (headless smoke, Playwright, MCP Apps) runs on Linux only; macOS and Windows
142
+ run every other test.
143
+ - HTTP+SSE transport fallback (REQ-CON-013) is deferred to v0.2; VS Code `type: "sse"`
144
+ entries do not connect.
145
+ - MCP App Views render only for invocations started from the Host UI, and only after the
146
+ invocation has ended (no streaming of partial input, no View for agent or App
147
+ invocations).
148
+ - A View that navigates its own frame away is detected and closed, but the navigation
149
+ itself may already have carried what the Host sent the View (tool input and result); CSP
150
+ has no directive that prevents it. Residual risk, Technical Design §6.1.
151
+ - Real Safari is not verified: the MCP Apps E2E runs on WebKit through Playwright's WPE
152
+ build (alongside Chromium and Firefox); no manual pass on Apple Safari was made (owner
153
+ decision; Plan R-8, accepted residual risk).
154
+ - Client ID Metadata Documents are not verified against a real authorization server
155
+ (spike S-4, closed with plan B): the CIMD URL is offered first, and the DCR and
156
+ configured-`client_id` fallbacks are tested against the fixture authorization server. If
157
+ an authorization server rejects the document, set `[servers.<id>.oauth] client_id`.
158
+ - MCP Apps are disabled in remote mode (`--unsafe-allow-remote`) and whenever the sandbox
159
+ proxy cannot run or `localhost` does not resolve to loopback only.
160
+ - Tool results are checked against `outputSchema` only by the Host's bounded validator; the
161
+ `mcp` SDK's own result validation is bypassed by design (see Changed).
162
+ - Process-group cleanup (POSIX) signals the group by the leader's id after the leader has
163
+ exited; in the short window before the signal the id could in theory be reused.
164
+ - If the keyring fails while tokens are saved, the tokens stay in memory for the Host's
165
+ lifetime only (nothing is persisted; sign in again after a restart). A keyring that fails
166
+ while tokens are read fails the authorization with reason `secret_store_unavailable`.
167
+ - A Host data directory that already exists keeps its mode (the files inside are `0600`);
168
+ one the Host creates is `0700`.
169
+ - Workspace pruning removes another version's workspace unused for 7 days even if a
170
+ long-running session of that version still uses it.
171
+ - `reflex_mcphost.ui.models` reaches `starlette` through the `mcp` SDK, so its import
172
+ contract forbids only `reflex`.
173
+ - Embedding apps must set `state_manager_mode="memory"` and run one backend worker (the UI
174
+ refuses to start otherwise; see `docs/library.md`).
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Ernesto Crespo
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.