Skip to content

mcp: fix setProgressToken when Meta is nil#846

Closed
StevenRChen wants to merge 1 commit intomodelcontextprotocol:mainfrom
StevenRChen:main
Closed

mcp: fix setProgressToken when Meta is nil#846
StevenRChen wants to merge 1 commit intomodelcontextprotocol:mainfrom
StevenRChen:main

Conversation

@StevenRChen
Copy link

When SetProgressToken is called on a Params struct with a nil Meta
field, the newly created map is never assigned back to the struct via
SetMeta, causing the progress token to be silently lost.

Call p.SetMeta(m) after creating the new map so the struct retains the
reference.

Fixes #845

@StevenRChen
Copy link
Author

Duplicating with existing PR
#838

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SetProgressToken silently fails when Meta is nil

1 participant