Merged
Conversation
Clarify that permission decisions are delegated to MCP clients by default, which use tool annotations to determine when to prompt users. Add section explaining tool annotations (readOnlyHint, destructiveHint, idempotentHint, openWorldHint) and document how to enable optional Emacs-side prompting. - Change default of mcp-server-security-prompt-for-permissions to nil - Update permission logic to allow all operations when prompting disabled - Add tool annotations to eval-elisp and get-diagnostics tools - Document JSON boolean convention (:false not :json-false)
Update version number in both header comment and runtime constant. Remove trailing whitespace throughout the codebase.
Closed
There was a problem hiding this comment.
Pull request overview
This PR implements version 0.5.0 of the MCP server, introducing MCP-compliant tool annotations and shifting the default permission model from Emacs-side prompting to client-side delegation based on tool behavior hints.
Changes:
- Added tool annotations (readOnlyHint, destructiveHint, idempotentHint, openWorldHint) to both tools per MCP specification
- Changed default permission handling from Emacs prompting to client-side delegation via
mcp-server-security-prompt-for-permissions(now defaults tonil) - Documented JSON boolean conventions (
:falsefor output, never:json-false) and version bumping procedures in CLAUDE.md
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| tools/mcp-server-emacs-tools-eval-elisp.el | Added annotations marking eval-elisp as destructive, non-idempotent, and open-world |
| tools/mcp-server-emacs-tools-diagnostics.el | Added annotations marking get-diagnostics as read-only, idempotent, and closed-world |
| mcp-server-security.el | Changed default permission prompt to nil with updated documentation explaining client-side delegation; updated permission logic to allow all operations when prompting is disabled |
| mcp-server.el | Version bump to 0.5.0 in both header and constant; whitespace cleanup |
| mcp-server-transport.el | Whitespace cleanup for consistency |
| CLAUDE.md | Added comprehensive JSON boolean convention documentation, version bumping instructions, and expanded security model section with tool annotations table |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…ions By default, dangerous operations are now blocked silently without prompting. Previously, all operations were allowed by default (relying on client-side permission handling). The blocklist is now always enforced. Setting `mcp-server-security-prompt-for-permissions` to t enables minibuffer prompts to approve dangerous operations case-by-case instead of blocking them. Error messages now provide clearer guidance on how to allow blocked operations.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Version: 0.4.0 → 0.5.0
Major Features
Tool Annotations (MCP Specification)
annotationsfield to tools (readOnlyHint,destructiveHint,idempotentHint,openWorldHint)eval-elisp: marked as destructive, non-idempotent, open-worldget-diagnostics: marked as read-only, idempotent, closed-worldClient-Side Permission Model
mcp-server-security-prompt-for-permissionsfromttonilModular Tool System
tools/directoryget-diagnosticstool for flycheck/flymake error reportingmcp-server-emacs-tools-enabledmcp-server-tools-filterDocumentation
:json-falseis banned, always use:falseBug Fixes
:falsefor booleanfalsevalues