Repository navigation
mcp: add ServerSession.NotifyResourceUpdated - #1524
Merged
Merged
Conversation
jmrplens
added a commit
to jmrplens/gitlab-mcp-server
that referenced
this pull request
Nov 16, 2026
…1846) ## Summary The State column of `docs/development/upstream-bugs.md` was checked against where each item stands upstream today. Of the register's 158 rows, the 39 already released in a named version were left out, since that can no longer change; the other 119, including the ten merged for 19.6, were looked up again (merge requests, issues, pull requests and the release tags of each project). Six rows had moved, and only their State cell changes here. The Upstream and Workaround cells are untouched, and the rest of the diff is the table padding that `cmd/format_md_tables` recomputes. ## Rows changed, by project GitLab, three rows: - The admin token route takes no granular scopes: the GitLab half is merged but still unreleased (no 19.6 tag exists), and the client-go half was released in v3.50.0 by another contributor, merged on 14 November. - GraphQL types and mutations this server reaches declare no fine-grained permission: `UserAchievement` (merged on 3 November) and the MCP note, diff and wiki types (merged on 10 November) join the merged, unreleased part, both for 19.6. - A declared mutation whose payload type declares nothing commits the write and answers null: our merge request was merged on 3 November, milestone 19.6. GitLab client (client-go), one row: - No token struct carries the granular fields: `granular_scopes` on the personal access token and impersonation token structs was released by another contributor in v3.50.0; `granular`, `last_used_ips` and the resource token fields are still missing, so the rest stays closed unmerged. This server pins v3.49.0, so the captured response is still needed until the bump. MCP Go SDK, two rows: - A resource update cannot be delivered to one session: another contributor opened modelcontextprotocol/go-sdk#1524 on 13 November for modelcontextprotocol/go-sdk#1265. - Two listens on one URI leave a session receiving neither: the second case was merged on 3 November (modelcontextprotocol/go-sdk#1490), so both are merged; no release follows v1.8.0 yet. ## Checks `go run ./cmd/format_md_tables/ --check`, `npx markdownlint-cli2` on the file, `go run ./cmd/audit_doc_links/`, `make check-em-dash` and `make check-dco`. --------- Signed-off-by: José M. Requena Plens <mail@jmrp.io>
nahapetyan-serob
force-pushed
the
serob/add-NotifyResourceUpdated
branch
from
November 16, 2026 10:15
e732d17 to
ca22350
Compare
guglielmo-san
approved these changes
Nov 16, 2026
Tangerg
added a commit
to Tangerg/go-sdk
that referenced
this pull request
Dec 2, 2026
Brings the fork up to upstream main at 723d70e, which is v1.9.0 plus fourteen later commits. Upstream changes: modelcontextprotocol#1238, modelcontextprotocol#1511, modelcontextprotocol#1515, modelcontextprotocol#1517, modelcontextprotocol#1521, modelcontextprotocol#1523, modelcontextprotocol#1524, modelcontextprotocol#1527, modelcontextprotocol#1533, modelcontextprotocol#1537, modelcontextprotocol#1539, modelcontextprotocol#1540, modelcontextprotocol#1544, modelcontextprotocol#1547, modelcontextprotocol#1549, modelcontextprotocol#1550, modelcontextprotocol#1553, modelcontextprotocol#1554, modelcontextprotocol#1558, modelcontextprotocol#1560, modelcontextprotocol#1561, modelcontextprotocol#1562. Fork-side adaptations: - internal/jsonrpc2: the -32600 reply to a duplicate in-flight ID (modelcontextprotocol#1550) is written off the read loop and holds its admission slot until written, like every other reply under MaxIncomingRequests. - mcp: ClientSession.initialize takes the session state lock that upstream added, and still projects the negotiated version to the connection. - mcp: the fork's copies of hintomitempty, nowrapinvalidparams and nomethodnotfoundcodeinerror go away with upstream's removal (modelcontextprotocol#1533). - extensions/skills: reads the protocol version from the fork's json.RawMessage Meta. - Tests: the duplicate-ID admission test drains the new reply, and the client cancellation test runs on 2025-11-25 only, because 2026-07-28 clients reject every standalone server request (modelcontextprotocol#1537, modelcontextprotocol#1540, modelcontextprotocol#1554).
jmrplens
added a commit
to jmrplens/gitlab-mcp-server
that referenced
this pull request
Dec 4, 2026
Moves `github.com/modelcontextprotocol/go-sdk` from v1.8.0 to v1.9.0 (released 2026-11-30, no new protocol revision) and takes in everything the release changes for this server: the pins that fail on it, the workarounds it makes unnecessary, and the pages that describe the old behaviour. The dependency sweep in #1985 held go-sdk at v1.8.0 for this change. ## What v1.9.0 changes, and what changed here | go-sdk change | Here | | --- | --- | | A handler or middleware error with no JSON-RPC code goes out as `-32603` with its text, no longer as code 0 ([#1407](modelcontextprotocol/go-sdk#1407)) | Correct per JSON-RPC, adopted. The carried-channel tests in `internal/tenancy` expect `-32603` (plain error and load shedding at 2025-11-25); the Refusal channels section of the tenant policy spec, `Validate`'s "no code" reason, the `CodedError` comment and the subscriptions page (EN and ES) say so | | `-32022` (unsupported protocol version) is answered with HTTP 400 in both eras | Correct per the transport spec, adopted. `sdkStatus` maps it in both eras; the spec says which statuses an in-band error takes. No register row emits `-32022` | | A typed nil result from a middleware is answered `null` at 2026-07-28 instead of ending the process | The test is renamed `TestTypedNilResult_FromAMiddleware_IsAnsweredNullInBothEras` and still runs each era in a child process; the spec keeps "a refusal is always an error" with the new reason | | Results a middleware returns are labeled with `resultType` like the dispatcher's ([#1226](modelcontextprotocol/go-sdk#1226), for [#1225](modelcontextprotocol/go-sdk#1225)) | Workaround retired: `internal/toolutil/result_type.go` and its tests are deleted, and the rate limiter, `heldRequestsRefusal` (its `req` parameter dropped) and both toolvisibility middlewares return their refusals as built. RTC-001, AUT-007, AUT-008 and the F-20 paragraph say the SDK labels them. `test/e2e/http/result_type_test.go` and the fine-grained e2e case still hold the label on the wire, and pass | | The client's `Ping` fails locally on a 2026-07-28 session, which removed ping ([#1378](modelcontextprotocol/go-sdk#1378)) | Test-only: `pingWithin` in `cmd/server` asks `server/discover` on such a session. The server's keepalive stays off; nothing in production changes | | The client passes the input requests of a multi round-trip result through its own receiving middleware as `elicitation/create` ([#1479](modelcontextprotocol/go-sdk#1479)) | Test-only: `callAs` in `language_test.go` counts the `elicitation/create` requests the server sends at the transport | | The multi round-trip interaction is chosen by the negotiated version, and input requests answered on a session negotiated below 2026-07-28 are fulfilled by the SDK with `elicitation/create` ([#1266](modelcontextprotocol/go-sdk#1266), for [#1258](modelcontextprotocol/go-sdk#1258)) | `internal/elicitation.FlowFromRequest` keeps reading the version the request states (the SDK exposes no negotiated one per request, and reconciles the two), with its comment rewritten. `test/e2e/stdio/elicitation_declared_version_test.go` is no longer a pin of an SDK defect: it asserts the legacy flow, a first question sent as `elicitation/create`, and a result with no `resultType` or `inputRequests`, and a second case accepts the title and the description and checks that the third question asks for the labels, so the SDK's fulfillment carries every answer and the signed state. The elicitation page (EN and ES) says the negotiated version decides | | Streamed POST responses are kept alive by the SDK, committing the headers after an interval of silence ([#1477](modelcontextprotocol/go-sdk#1477), for [#1262](modelcontextprotocol/go-sdk#1262)) | `streamableHTTPOptions` passes `StreamKeepAlive: sseKeepAliveInterval` (25 s), and `sseAwareWriter` no longer heartbeats a POST response, so a stream never carries two; it still clears the write deadline and keeps the standalone GET alive. A silent tool call now gets bytes on the wire before its result. The unit and e2e keep-alive tests assert that; the HTTP server, remote deployment and troubleshooting pages (EN and ES) drop the "a silent tool call gets no keep-alive" advice, and the spec notes that a keep-alive committed POST takes a protocol error as an event at 200 | | `MCPGODEBUG` switches removed, among them `customresnotfounderrcode` and `noprotocolerrorbody` | `subscriptions.isResourceNotFound` compares against `jsonrpc.CodeInvalidParams` (no deprecated variable, no `nolint`, and `internal/subscriptions` no longer imports `mcp`); the dead `noprotocolerrorbody` skip in `session_not_found_test.go` is gone | | `mcp.HasParams` ([#1269](modelcontextprotocol/go-sdk#1269), for [#1261](modelcontextprotocol/go-sdk#1261)) | Adopted: `mcpotel.paramsOf` and the e2e harness drop their reflect checks | | Notifications go to each session on a goroutine of their own ([#1228](modelcontextprotocol/go-sdk#1228)) and `_meta` is cloned per session ([#1490](modelcontextprotocol/go-sdk#1490)) | Already allowed for by `sessionOwners.sendingMiddleware`; its comments, ADR-0020 (whose "what in the go-sdk this rests on" section is re-verified against v1.9.0) and the resource hot spots page say it is released | | A second listen on a URI no longer clobbers the first ([#1360](modelcontextprotocol/go-sdk#1360), for [#1359](modelcontextprotocol/go-sdk#1359)); `Subscribe` awaits the listen in the background and clears its entry when it ends ([#1283](modelcontextprotocol/go-sdk#1283), for [#1169](modelcontextprotocol/go-sdk#1169)) | The resubscribe caveat in the e2e harness (on `TrySubscribe`, `Subscription.Close` and the subscription's cleanup) is retired; the subscriptions and troubleshooting pages (EN and ES) describe the v1.9.0 client. A resubscribe during the earlier listen's teardown is now something a client does, and it exposed a race in `sessionBridge`: the unsubscribe released the last hold and stopped the watch with nothing held between the two, so a resubscribe joining in that gap was acknowledged on a stopped watch. The subscribes and unsubscribes of one watch now run under a lock per session and URI (a waiting subscribe gives up with its request), pinned by `TestSessionBridge_ResubscribeDuringTeardown_KeepsTheWatch`, which fails without it | | The cancellation reason reaches the handler as the context's cause ([#1255](modelcontextprotocol/go-sdk#1255), for [#1254](modelcontextprotocol/go-sdk#1254)) | Not logged: it is text the client writes. The `wasCancelled` comment says so instead of saying it cannot be read | Version mentions move to v1.9.0 in CLAUDE.md, the Copilot and agent instructions, the architecture, HTTP server, subscriptions and troubleshooting pages (EN and ES), the tenancy package, ADR-0020 and ADR-0027. `docs/development/upstream-bugs.md` records every go-sdk row that shipped in v1.9.0 and what it retired; the rows still open upstream (malformed messages, `notifications/cancelled` for a listen, the client after a 404) keep their pins, which pass. CLAUDE.md and `test/e2e/README.md` now name two go-sdk pins, `listen_end_test.go` and `session_not_found_test.go`. ## Upstream changes this release ships Ours: [#1266](modelcontextprotocol/go-sdk#1266), [#1267](modelcontextprotocol/go-sdk#1267) (stdio at 2026-07-28; HTTP still answers a cancelled call), [#1255](modelcontextprotocol/go-sdk#1255), [#1268](modelcontextprotocol/go-sdk#1268), [#1269](modelcontextprotocol/go-sdk#1269), [#1360](modelcontextprotocol/go-sdk#1360), [#1490](modelcontextprotocol/go-sdk#1490), [#1273](modelcontextprotocol/go-sdk#1273), [#1274](modelcontextprotocol/go-sdk#1274). Others' that this server tracked: [#1477](modelcontextprotocol/go-sdk#1477), [#1242](modelcontextprotocol/go-sdk#1242), [#1464](modelcontextprotocol/go-sdk#1464), [#1524](modelcontextprotocol/go-sdk#1524), [#1226](modelcontextprotocol/go-sdk#1226), [#1283](modelcontextprotocol/go-sdk#1283). ## Left for a decision - **Request id on spans** ([#1464](modelcontextprotocol/go-sdk#1464)): `Request.GetID` makes `jsonrpc.request.id` recordable, but the id is the client's own value and the telemetry page and the collector privacy suite promise no client-controlled value on a span. Not adopted. - **Per-session resource updates** ([#1524](modelcontextprotocol/go-sdk#1524)): `ServerSession.NotifyResourceUpdated` could deliver to an owner's 2026-07-28 sessions directly; legacy `resources/subscribe` sessions still need the sending middleware, so this is an optimisation, not a retirement. - **`OnRequestSummary`** and the opt-in `MCPGODEBUG=demotesessionlifecyclelog=1` are not used. ## Verification Run on the branch, through the remote runner unless noted: - `go build ./...`, `go vet -tags e2e,stdioe2e,httpe2e ./...` - `go test ./internal/... ./cmd/... -count=1`: green except `cmd/orbit_fixtures`, which reads git and fails only because the remote copy is not a repository (it passes in CI) - stdio and HTTP transport e2e modules against a binary built from the branch: both green - `golangci-lint`, `govulncheck`, `check-tenancy`, `check-supply-chain`, the 1:1 audit scopes (`sdk`, `paths`, `grants`, `required`, `params`, `routes`, `enums`), `check-audit-1to1-baseline`, `check-testing-docs`, `check-md-tables`, `check-doc-links`, `check-doc-tool-names`, `check-e2e-static` and the test-shape, i18n, escaping, action-id, godoc and surface-quality gates - locally: `check-file-headers`, `check-em-dash`, `check-dco`, `check-pr-description`, the site's `i18n:check`, `build` and `lint`, markdownlint on the changed Markdown - The branch is rebased on main after #1985 landed, with client-go v3.60.0 and the rest of that sweep, and again after #1987 (R-ROUTE wave 4, 38 new actions) landed. Wave 4 uses none of the helpers this bump retires, and only the testing reference needed regenerating. On the tree rebased onto #1987: `go build`, `go vet` with every e2e tag, the unit suite (with the request inventory recorded from it, which comes out unchanged), both transport e2e modules, `golangci-lint`, `govulncheck`, the seven 1:1 scopes, the baseline, `check-supply-chain`, `check-tenancy`, the generated-artifact gates CI runs, the local gates and the site gates. All pass - `go test -race` over `cmd/server` and `internal/subscriptions` - The release rehearsal (`release.yml` dispatched on dc520bb, before the rebase onto #1987) passed every job. That includes the Docker GitLab e2e gate, which drives the real binary through the go-sdk `ClientSession` this bump changes, the race gates, the reproducible build and every publisher's dry run. Dispatched again on the rebased head 6f9fcfd, it passed all 20 jobs. --------- Signed-off-by: José M. Requena Plens <mail@jmrp.io>
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.
closes #1265