Skip to content

fix(everything): give gzip-file-as-resource's resource the resource icons - #5436

Merged
cliffhall merged 1 commit into
v2/mainfrom
v2/fix/5434-everything-generated-resource-icons
Nov 4, 2026
Merged

cliffhall merged 1 commit into
v2/mainfrom
v2/fix/5434-everything-generated-resource-icons

Conversation

@cliffhall

Copy link
Copy Markdown
Member

Closes #5434

Description

#3131 gave every everything primitive a light/dark icon pair. The docs (docs/features.md, README) say every resources/list entry carries one. Copilot, reviewing the v2.3.0 merge PR #5430, found that the resource gzip-file-as-resource creates had none, in either era:

  • 2025-era: the session resource the tool registers. Its resources/list entry and the returned resource_link had no icons.
  • 2026-07-28: the minted resource_link had no icons.

Both now carry RESOURCE_ICONS. In tools/gzip-file-as-resource.ts the session resource object gets them, and registerSessionResource already passes icons through. In resources/minted.ts the minted link gets them, so any minted resource has them.

Server Details

  • Server: everything
  • Changes to: the resource gzip-file-as-resource creates (tools/gzip-file-as-resource.ts, resources/minted.ts); tests; patch changeset

Motivation and Context

#5434. This is part of #3131, which ships in this release (v2.3.0, #5425), so it is fixed before the release.

How Has This Been Tested?

Inspector CLI 2.13.0, tools/call gzip-file-as-resource {"name":"i.gz","data":"data:text/plain;base64,…"}, both eras:

candidate cc602786 legacy  exit=0 resource_link demo://resource/session/i.gz          icons: []
candidate cc602786 modern  exit=0 resource_link demo://resource/minted/<uuid>/i.gz    icons: []
branch             legacy  exit=0 resource_link demo://resource/session/i.gz          icons: [light, dark]
branch             modern  exit=0 resource_link demo://resource/minted/<uuid>/i.gz    icons: [light, dark]

SDK client (@modelcontextprotocol/client, 2025-era, stdio). The CLI cannot list resources after a call in the same session, so this script calls the tool and then resources/list:

candidate: generated demo://resource/session/listed.gz icons [] · 9 listed · without icons: ["listed.gz"]
branch:    generated demo://resource/session/listed.gz icons [light, dark] · 9 listed · without icons: []

LLM client: Claude Code 2.1.318, headless, --strict-mcp-config naming this branch's build. Asked to call gzip-file-as-resource with llm.gz, it returned the minted link demo://resource/minted/1250165c-…/llm.gz, so it negotiated 2026-07-28. It reported no icons, because Claude Code passes the model only the link's name, URI and description. The icons on that same link are shown by the CLI row above.

Tests:

  • icons.test.ts checks the returned link in both eras, and the session resource's resources/list entry on the 2025 era. All three fail without the fix.
  • gzip-file-as-resource.test.ts's two exact-match expectations now include the icons.

everything: 461 passed, coverage 99.91 / 98.67 / 99.6 / 100. npm run local:gate: EXIT=0. The interface diff shows no change, since icons on a generated resource are not part of the listed interface.

Breaking Changes

None. One optional field is added to a generated resource.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature
  • Breaking change
  • Documentation update

Checklist

  • I have read the MCP Protocol Documentation (Icon on Resource and ResourceLink, SEP-973)
  • My changes follow MCP security best practices
  • I have updated the server's README accordingly (not applicable: it already says every resource carries icons; this makes that true)
  • I have added a changeset (npm run changeset) if this changes what a TypeScript server publishes
  • I have tested this with an LLM client
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling (not applicable: no new failure path)
  • I have documented all environment variables and configuration options (not applicable: none added)

🤖 Generated with Claude Code

…cons

#3131 put a light/dark icon pair on every primitive, and the docs say
every resources/list entry carries one, but the resource the gzip tool
creates had none: the 2025-era session resource (its list entry and
link) and the 2026-07-28 minted link. Both now carry RESOURCE_ICONS, and
the icon tests cover the generated resource in both eras.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: cliffhall <cliff@futurescale.com>
@cliffhall cliffhall added the v2 label Nov 4, 2026
@changeset-bot

changeset-bot Bot commented Nov 4, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: ee12fb1

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@modelcontextprotocol/server-everything Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

everything: MCP interface diff

Base: cc6027865fe1 (Merge pull request #5429 from modelcontextprotocol/v2/chore/5425-python-calver-2026.11.4)
Head: the build in this checkout, at 5c35c5380f48 (Merge ee12fb1 into cc60278)

✅ No interface changes detected.

Tools Prompts Resources Resource templates
Base 22 4 8 5
Head 22 4 8 5

Updated by this run for ee12fb1446585fe27407d4fe1a0205c3feffefa8.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues are reported for the generated-resource icon changes.

No open issues 🎉

What changed in this PR

Fixes #5434 by adding light/dark resource icons to resources generated by gzip-file-as-resource, bringing the Everything server into line with its documented icon support.

Changes:

  • Adds RESOURCE_ICONS to legacy session resources and modern minted resource links.
  • Adds regression checks for links in both protocol eras and legacy resource listings.
  • Includes a patch changeset for the Everything package.
File Description
src/​everything/​tools/​gzip-file-as-resource.ts Adds icons to generated session resources and their links.
src/​everything/​resources/​minted.ts Adds icons to minted resource links.
src/​everything/​__tests__/​icons.test.ts Checks generated resource icons across both protocol eras.
src/​everything/​__tests__/​gzip-file-as-resource.test.ts Updates expected resource metadata to include icons.
.changeset/​everything-5434-generated-resource-icons.md Records the fix for a patch release.

Review effort: Balanced

@cliffhall

Copy link
Copy Markdown
Member Author

Copilot round 1: clean (no findings, no suppressed comments). Review loop ends on the first clean round.

@cliffhall
cliffhall merged commit f4f9928 into v2/main Nov 4, 2026
45 checks passed
@cliffhall
cliffhall deleted the v2/fix/5434-everything-generated-resource-icons branch November 4, 2026 18:13
@github-actions github-actions Bot mentioned this pull request Nov 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

everything: gzip-file-as-resource's generated resource carries no icons in either era

2 participants