@yawlabs/mcp 1.0.2 → 1.0.3
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.
- package/CHANGELOG.md +18 -4
- package/README.md +1 -1
- package/dist/{auto-upgrade-A3WTRVGV.js → auto-upgrade-S4MOIA6T.js} +1 -1
- package/dist/{chunk-PAUBVL2N.js → chunk-7AUZKQTT.js} +200 -89
- package/dist/index.js +384 -447
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,7 +2,21 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to `@yawlabs/mcp` (formerly `@yawlabs/mcph`) are documented here. This project uses [semantic versioning](https://semver.org) and a script-gated release flow: `./release.sh <version>` runs lint + typecheck + tests + build, bumps, tags, publishes to npm, and publishes `server.json` to the MCP registry.
|
|
4
4
|
|
|
5
|
-
## Unreleased --
|
|
5
|
+
## Unreleased -- a fresh Yaw Mode pane names the local-scope entry it will lose
|
|
6
|
+
|
|
7
|
+
**Fixed -- a fresh Yaw Mode pane warns about a local-scope Claude Code entry, and the augment Keeping line stops promising the entry goes home**
|
|
8
|
+
|
|
9
|
+
In a fresh Yaw Mode pane, `install claude-code --scope local` wrote the entry into the overlay's `.claude.json` -- `projects[<dir>]` lives in `<CLAUDE_CONFIG_DIR>/.claude.json`, and a fresh pane keeps nothing of its overlay -- and said nothing about it. It now prints: ``Note: a fresh Yaw Mode pane does not keep its config dir, so the Claude Code entry in <overlay>/.claude.json goes when this pane closes. Run `yaw-mcp install claude-code --scope local --project-dir <dir>` from a normal shell to keep it.``
|
|
10
|
+
|
|
11
|
+
In an augment pane, the line `uninstall` prints when it keeps the `~/.claude/settings.json` grant for a Claude Code entry in the pane's own `.claude.json` said Yaw carries that entry home when the pane closes. It now says Yaw may: ``Keeping mcp__mcp__* in ~/.claude/settings.json: Claude Code (user) still launches yaw-mcp from <overlay>/.claude.json, which Yaw may carry home when the pane closes.`` Yaw skips that copy when its `yawModeSyncClaudeJson` setting is off, and when `~/.claude.json` changed while the pane was open it merges instead, which brings no overlay `mcpServers` entry into a home file that already has `mcpServers`. The grant is still kept, for the case where the entry does arrive.
|
|
12
|
+
|
|
13
|
+
**Fixed -- on Windows, an audit stops failing on the lock the audit before it was releasing**
|
|
14
|
+
|
|
15
|
+
A release run died in its test gate: `grades-cache.test.ts`'s concurrent-writes case threw `EPERM: operation not permitted, open '...\.yaw-mcp\grades.json.lock'`. It was not the test. On Windows, creating a file with `O_EXCL` while another thread or process is deleting the same path fails `EPERM` instead of succeeding or answering "already exists" -- 225 times in 2000 races on the machine that failed (Windows 11, Node 22.22.2). The grade cache's lock take treated every errno other than "already exists" as fatal, so a `yaw-mcp audit` whose wait happened to land inside the previous holder's release failed with exit 3, grade computed but not cached. The Yaw Terminal MCP panel grading two servers at once is exactly that shape. The take now retries `EPERM`, `EBUSY` and `EACCES` on Windows -- the codes `atomicWriteFile` already retries its rename on -- for up to a second, then reports the real errno rather than a lock-timeout message. POSIX is unchanged.
|
|
16
|
+
|
|
17
|
+
The same take backs the `bundles.json` write lock, the sidecars install lock and the self-upgrade lock, and there the misread was quieter: a lock it could not create was treated as "no lock possible here, proceed", so the same `EPERM` ran the write or the install unlocked beside whichever process took the lock next. It now retries those codes three times, 26 ms in all, before falling back to that best-effort answer.
|
|
18
|
+
|
|
19
|
+
## 1.0.2 -- `install --force` stops keeping the env it promised to overwrite, editing a client config stops rewriting the entry next to ours, and the install surfaces stop stating things that are not so
|
|
6
20
|
|
|
7
21
|
An audit of the install surface. Nothing in the install blocks changes how yaw-mcp brokers servers at runtime -- they are `yaw-mcp install` and the commands that share its config-writing code -- and the blocks after the `doctor` block are unrelated changes, each saying what it touches. The `--force` block is first, deliberately: it is the first of this section's script-visible changes, and the one whose difference is a credential that used to survive and no longer does. It is not the only one -- `install --all` now exits 2 where it exited 1 on a refusal-only run, `--force --repair` together now exits 2 instead of writing, and `install --list`'s STATUS column can now read `installed (other drive case)` for a Claude Code project whose entry an older version left under the other drive-letter spelling -- and each such change is called out in the block it belongs to.
|
|
8
22
|
|
|
@@ -80,14 +94,14 @@ An older typed CLI ignores `~/.config/typed/mcp.json` without a word, so `instal
|
|
|
80
94
|
|
|
81
95
|
**Fixed -- in a Yaw Mode pane, the `mcp__mcp__*` grant outlives the pane**
|
|
82
96
|
|
|
83
|
-
A Yaw Mode pane sets `YAW_MODE` to `augment` or `fresh` and points `CLAUDE_CONFIG_DIR` at a per-pane overlay, and `install claude-code` and `install typed` at user scope wrote the grant only to that overlay's `settings.json`. Yaw discards that copy with the pane: an augment pane starts it as a hardlink to `~/.claude/settings.json`, but Yaw unlinks it to write its own per-pane allow-list, install's atomic write replaces it either way, and
|
|
97
|
+
A Yaw Mode pane sets `YAW_MODE` to `augment` or `fresh` and points `CLAUDE_CONFIG_DIR` at a per-pane overlay, and `install claude-code` and `install typed` at user scope wrote the grant only to that overlay's `settings.json`. Yaw discards that copy with the pane: an augment pane starts it as a hardlink to `~/.claude/settings.json`, but Yaw unlinks it to write its own per-pane allow-list, install's atomic write replaces it either way, and `settings.json` is not among the files Yaw carries home when the pane closes. So every session after the pane went back to asking about yaw-mcp's tools.
|
|
84
98
|
|
|
85
99
|
With `YAW_MODE` set to one of those two values and `CLAUDE_CONFIG_DIR` naming a Yaw overlay -- a directory whose name starts with `yaw-mode-`, the name every overlay Yaw builds carries and the test Yaw itself applies -- a user-scope install or uninstall of either client now:
|
|
86
100
|
|
|
87
|
-
- **augment** -- writes the grant to `~/.claude/settings.json` as well as the overlay's, and the
|
|
101
|
+
- **augment** -- writes the grant to `~/.claude/settings.json` as well as the overlay's, and the `Wrote` line for `~/.claude/settings.json` ends ` -- a Yaw Mode pane's own settings.json does not outlive the pane`. `uninstall` removes it from both, and keeps each file's grant while another client that reads that file still has its entry. For `~/.claude/settings.json` that includes a Claude Code entry in the pane's own `.claude.json`, which Yaw normally carries home, and the line kept for it says so: ``Keeping mcp__mcp__* in ~/.claude/settings.json: Claude Code (user) still launches yaw-mcp from <overlay>/.claude.json, which Yaw carries home when the pane closes.`` That line overstates it -- Yaw does not always copy the entry home; the Unreleased section above corrects it. An entry in any other file under the overlay -- typed's `<overlay>/.mcp.json`, say -- keeps only the overlay's grant, since that file goes with the pane.
|
|
88
102
|
- **fresh** -- writes the overlay only, since a fresh pane reads nothing from home, and prints one note naming what goes when the pane closes, because a fresh pane keeps nothing of its overlay. For `install typed`, whose entry is outside the overlay, that is the grant: ``Note: a fresh Yaw Mode pane does not keep its settings.json, so the mcp__mcp__* grant in <overlay>/settings.json goes when this pane closes. Run `yaw-mcp install typed` from a normal shell to keep it.`` For `install claude-code`, whose entry lands in the overlay's `.claude.json`, it is both: ``Note: a fresh Yaw Mode pane does not keep its config dir, so the Claude Code entry in <overlay>/.claude.json and the mcp__mcp__* grant in <overlay>/settings.json go when this pane closes. Run `yaw-mcp install claude-code` from a normal shell to keep them.`` -- printed whenever install writes either file there. `uninstall` removes from the overlay only, without a note.
|
|
89
103
|
|
|
90
|
-
Project and local scope are
|
|
104
|
+
Project scope is unchanged; the grant files of project and local scope are project-relative, so neither scope gets a second patch or a grant in the overlay. Claude Code's local-scope entry is the exception: it lives in `<CLAUDE_CONFIG_DIR>/.claude.json` under `projects[<dir>]`, so it is in the overlay too, and in a fresh pane it goes when the pane closes -- in this release without a note; the Unreleased section above adds one. Every run outside a Yaw Mode pane is unchanged as well. That includes a `CLAUDE_CONFIG_DIR` of your own set at a pane's prompt: Yaw exports `YAW_MODE` to the pane's shell too, but a directory not named `yaw-mode-*` is not an overlay, and install treats it exactly as it would outside Yaw. In a pane, the lines above replace the `install typed` note about a grant scoped to `CLAUDE_CONFIG_DIR`. `YAW_MODE` joins the `--help` Environment block.
|
|
91
105
|
|
|
92
106
|
**Added -- `install` reaches Zed, Cline, Continue and Codex CLI, and takes `mcp` as another name for Claude Code's project scope**
|
|
93
107
|
|
package/README.md
CHANGED
|
@@ -61,7 +61,7 @@ npx -y @yawlabs/mcp@latest install <claude-code|claude-desktop|cursor|vscode|win
|
|
|
61
61
|
|
|
62
62
|
This edits the chosen client's config (correct path + JSON shape for your OS) to launch yaw-mcp. On Windows it wraps `npx` in `cmd /c` (without which MCP clients hit `ENOENT` on the `npx.cmd` shim), except for Continue, Codex CLI and typed, which resolve that shim themselves and get a bare `npx`. Run it once per client. `mcp` is accepted too, as another name for Claude Code's project scope (`<project>/.mcp.json`).
|
|
63
63
|
|
|
64
|
-
`install typed` writes typed's own `~/.config/typed/mcp.json` (the same path on every OS, whatever `CLAUDE_CONFIG_DIR` says), which typed ranks above the user-scope files it shares with Claude Code -- so it wins over an `mcp` entry Yaw Terminal manages in `~/.claude.json`, while a project's `.mcp.json` still wins over it. On a Yaw Terminal machine that is a trade when install writes an `npx` entry (no oam, or no global install to point it at): the entry replaces Yaw Terminal's local launch for typed, and npx resolves `@latest` on every typed start, which is slow and can exceed typed's MCP connect timeout. Install says so when it happens; `npm i -g @yawlabs/mcp` with oam installed, then a re-run, writes a fast absolute-path entry instead, or raise `MCP_TIMEOUT`. **It needs a typed CLI newer than 1.5.0** -- typed 1.5.0 and older do not read `~/.config/typed/mcp.json` at all; with one of those, use `install claude-code`, whose files typed also reads. `install typed` checks the typed CLI bundle on this machine (`~/.config/typed/typed-cli/cli.mjs`, or `$TYPED_CLI_BUNDLE`) and warns when it cannot read the file yet, naming `typed update`, which installs the newest typed release. Like `install claude-code`, it adds `mcp__mcp__*` to `permissions.allow` in Claude Code's user `settings.json`, which typed reads for permissions too -- `$CLAUDE_CONFIG_DIR/settings.json` when that is set, so the grant is scoped to that config dir while typed's `mcp.json` is not, and install says so. The two clients share that one grant, so `uninstall` of either keeps it while the other still has its entry (or typed still loads an `mcp` entry from another file it reads), and says so. In a Yaw Mode pane, where `CLAUDE_CONFIG_DIR` is a per-pane overlay (a `yaw-mode-*` directory) whose `settings.json` is discarded with the pane, install and uninstall of either client add and remove the grant in `~/.claude/settings.json` too (augment). In a fresh pane, which keeps nothing of its overlay, install says what goes with the pane -- the grant, and for `install claude-code` its entry in the overlay's `.claude.json` as well -- and to install from a normal shell to keep it.
|
|
64
|
+
`install typed` writes typed's own `~/.config/typed/mcp.json` (the same path on every OS, whatever `CLAUDE_CONFIG_DIR` says), which typed ranks above the user-scope files it shares with Claude Code -- so it wins over an `mcp` entry Yaw Terminal manages in `~/.claude.json`, while a project's `.mcp.json` still wins over it. On a Yaw Terminal machine that is a trade when install writes an `npx` entry (no oam, or no global install to point it at): the entry replaces Yaw Terminal's local launch for typed, and npx resolves `@latest` on every typed start, which is slow and can exceed typed's MCP connect timeout. Install says so when it happens; `npm i -g @yawlabs/mcp` with oam installed, then a re-run, writes a fast absolute-path entry instead, or raise `MCP_TIMEOUT`. **It needs a typed CLI newer than 1.5.0** -- typed 1.5.0 and older do not read `~/.config/typed/mcp.json` at all; with one of those, use `install claude-code`, whose files typed also reads. `install typed` checks the typed CLI bundle on this machine (`~/.config/typed/typed-cli/cli.mjs`, or `$TYPED_CLI_BUNDLE`) and warns when it cannot read the file yet, naming `typed update`, which installs the newest typed release. Like `install claude-code`, it adds `mcp__mcp__*` to `permissions.allow` in Claude Code's user `settings.json`, which typed reads for permissions too -- `$CLAUDE_CONFIG_DIR/settings.json` when that is set, so outside a Yaw Mode pane the grant is scoped to that config dir while typed's `mcp.json` is not, and install says so. The two clients share that one grant, so `uninstall` of either keeps it while the other still has its entry (or typed still loads an `mcp` entry from another file it reads), and says so. In a Yaw Mode pane, where `CLAUDE_CONFIG_DIR` is a per-pane overlay (a `yaw-mode-*` directory) whose `settings.json` is discarded with the pane, install and uninstall of either client at user scope add and remove the grant in `~/.claude/settings.json` too (augment). In a fresh pane, which keeps nothing of its overlay, install says what goes with the pane -- the grant at user scope, and for `install claude-code` its entry in the overlay's `.claude.json` as well (at local scope, that entry alone) -- and to install from a normal shell to keep it.
|
|
65
65
|
|
|
66
66
|
Claude Desktop on Linux is not supported yet. Anthropic ships a Linux beta but has not documented where it reads `claude_desktop_config.json`, so `install claude-desktop` refuses on Linux rather than write a guessed path, and `--all` skips it. Add the entry by hand, or use another client.
|
|
67
67
|
|