test(mcp): smoke the okf 1.1 server through the run's own MCP path -- works by full path, not by bare name
A new test builds a small invented collection with `okf build` and connects through
load_mcp_config -> build_mcp_tools -> async with. No model call, no network. It measures:
- the four tools are offered, and a narrower allowed_tools narrows them;
- okf_list names the collection;
- okf_ask returns the excerpt.
That holds only when the config gives the full path to okf 1.1. With the README's bare `okf`,
a run under `uv run` or an activated venv finds this project's own dependency
llm-ingestion-okf 0.8.5 first. That version has no `mcp` subcommand, and the server fails at
startup ("invalid choice: 'mcp'"). This is pinned as xfail(strict=True, raises=ToolException)
and not repaired, per the order.
The tests skip when no okf >= 1.1.0 is found on PATH outside the venv. The version is measured
from the server's own initialize answer. README limits now state what was measured. The
published-surface pin moves from 518 to 519 for the new file.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
parent
fe429912c6
commit
daccdbefe6
3 changed files with 179 additions and 4 deletions
10
README.md
10
README.md
|
|
@ -390,9 +390,13 @@ With it, the server and each allowed tool are named in the announcement before t
|
|||
|
||||
**Limits, stated plainly.**
|
||||
|
||||
- The link between this framework and the `okf` server has **not been tried in a real run**. Only
|
||||
the config file is validated (`tests/test_okf_server_example.py`, against the same loader a run
|
||||
uses).
|
||||
- **Measured without a model** (`tests/test_okf_server_smoke.py`, against a small invented
|
||||
collection): through the same loader and tool builder a run uses, `okf` 1.1 offers exactly the
|
||||
four tools, `allowed_tools` narrows what is offered, `okf_list` names the collection and one
|
||||
`okf_ask` returns the excerpt. **This works only when `command` is the full path to the `okf`
|
||||
1.1 executable.** With the bare `okf` shown above, a run started with `uv run` or from an
|
||||
activated environment finds this framework's own `okf` dependency (0.8.5) first. That version
|
||||
has no `mcp` command, and the server fails at startup (`invalid choice: 'mcp'`).
|
||||
- It is **not measured** whether the agents follow the way of working the server describes.
|
||||
- `--prepass-payload` does not accept the v1.1 format (`okf-consumption/2`). That is a known gap.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue