Skip to content

fix(oauth): Refresh stale MCP client registrations - #783

Merged
dcramer merged 2 commits into
mainfrom
fix/oauth-auth-link-validation
Jul 7, 2026
Merged

dcramer merged 2 commits into
mainfrom
fix/oauth-auth-link-validation

Conversation

@dcramer

@dcramer dcramer commented Jul 7, 2026 •

Copy link
Copy Markdown
Member

Summary

  • ignore cached MCP dynamic client registrations when their registered redirect URIs do not include the current Junior callback URL, so the MCP SDK can register a fresh client before building the provider authorization link
  • centralize Slack explicit-link escaping and use it for both MCP and generic OAuth auth messages
  • keep MCP auth orchestration out of Slack-owned formatting modules to satisfy chat dependency boundaries

Validation

  • pnpm --filter @sentry/junior lint
  • CI=true pnpm --filter @sentry/junior build

Refs GH-782

Avoid reusing cached MCP OAuth dynamic client information when its registered redirect URIs do not include the current Junior callback URL. This lets the MCP SDK register a fresh client before building provider auth links.

Also centralize Slack explicit-link escaping for OAuth auth messages so provider URLs with query strings render safely in Slack.

Refs GH-782

Co-Authored-By: GPT-5 Codex <[email protected]>
@vercel

vercel Bot commented Jul 7, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
junior-docs Ready Ready Preview, Comment Jul 7, 2026 5:32pm

Request Review

Move OAuth authorization prompt formatting behind a chat-level helper so MCP auth orchestration no longer imports Slack formatting directly. Remove the unit-test additions from this PR and keep the change focused on runtime behavior and the CI boundary rule.

Refs GH-782

Co-Authored-By: GPT-5 Codex <[email protected]>
@dcramer
dcramer marked this pull request as ready for review July 7, 2026 17:31
@github-actions github-actions Bot added the risk: high PR risk score: high label Jul 7, 2026
@dcramer
dcramer merged commit 67081f4 into main Jul 7, 2026
20 checks passed
@dcramer
dcramer deleted the fix/oauth-auth-link-validation branch July 7, 2026 17:42

This branch was successfully deployed

1 active deployment
Preview – junior-docs — e9823024 Deployed Jul 7, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk: high PR risk score: high

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant