Skip to content

Conversation

@alexinthesky
Copy link
Collaborator

@alexinthesky alexinthesky commented Jan 23, 2026

Note

Introduces secure per-user OAuth for MCP and streamlines tooling.

  • Adds OAuth 2.1 flow (PKCE) for MCP: OAuthFlowManager, token storage/refresh, and Bearer injection via customRoundTripper; client calls now accept userID and refresh on 401
  • Preserves org headers; updates Client methods (connectMCPWithOrgContext, OpenAPI/MCP/standard calls) to use OAuth-aware HTTP clients
  • Dev environment: Dockerfile installs Go/delve/mage in dev; supervisord adds delve/build watchers; docker-compose exposes 2345, enables embedding, and adds Redis service/volume
  • Build/config: migrates ESLint to flat config; extracts Webpack externals; improves banner/replacements; adds Storybook preview; updates .env defaults
  • CI: bumps Go to 1.24; switches plugin validation to @grafana/plugin-validator; cleans packaging steps; adds provenance in release
  • Go/tooling: upgrades to Go 1.25 toolchain, refreshes numerous deps (incl. Redis), simplifies Magefile to SDK build
  • Docs & housekeeping: updates README/AGENTS/CHANGELOG/SECURITY; adds ignore entries; revises package.json scripts (validate/build)

Written by Cursor Bugbot for commit 5ea8a86. This will update automatically on new commits. Configure here.

- Updated `useChat` hook to accept an optional `initialSession` parameter for initializing chat history.
- Modified `ChatComponent` to handle read-only mode and pass the initial session to the chat hook.
- Enhanced `useSessionManager` to skip loading the current session if chat history is already populated.
- Added session sharing capabilities in the `SessionSidebar`, including loading and managing session shares.
- Introduced new API endpoints for creating, retrieving, and deleting session shares in the backend.

This update improves user experience by allowing session persistence and sharing, enhancing the overall chat functionality.
- Introduced Redis configuration and client creation in the plugin.
- Implemented fallback logic for in-memory storage if Redis is unavailable.
- Updated health check to include Redis connection status.
- Added Redis service to docker-compose for local development.
- Updated ShareDialog to handle expiration options for shares, including "Never" and specific durations in hours and days.
- Modified sessionShareService to accept both hours and days for expiration, improving flexibility.
- Adjusted tests to validate new expiration logic and ensure correct behavior for share creation.
- Refactored session management to support immediate saving of chat history and session states.
- Cleaned up unused import and export functionalities in the session sidebar component.
- Fixed issues with session sharing expiration options not being applied correctly.
- Ensured that both "Never" and specific duration settings are functioning as intended.
- Updated related tests to cover edge cases for expiration logic.
…r handling

- Enhanced the test for revoking session shares by ensuring the "Create Another Share" button is visible after a share is created.
- Added checks for the visibility of the "Existing Shares" label before locating the revoke button.
- Updated error handling test to avoid strict mode violations by using the first() method for the error message element.
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 3 potential issues.

ARG development=false
ARG TARGETARCH

ARG GO_VERSION=1.21.6
Copy link

Choose a reason for hiding this comment

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

Go version mismatch between go.mod and Dockerfile

High Severity

The Dockerfile uses GO_VERSION=1.21.6 while go.mod requires go 1.25.5. This version mismatch will cause Go compilation failures when building the backend in Docker, as Go 1.21.6 cannot compile code requiring Go 1.25.5 language features and standard library changes.

Additional Locations (1)

Fix in Cursor Fix in Web

"version": "0.1.1",
"scripts": {
"build": "npm run build:frontend && npm run build:backend",
"build": "webpack -c ./.config/webpack/webpack.config.ts --env production",
Copy link

Choose a reason for hiding this comment

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

Webpack config path inconsistency in build script

Medium Severity

The build script references ./.config/webpack/webpack.config.ts but other scripts use ./webpack.config.ts. This inconsistent path will cause the build command to fail if webpack.config.ts is not in the .config/webpack/ directory.

Fix in Cursor Fix in Web

"build:frontend:coverage": "COVERAGE=true webpack -c ./webpack.config.ts --env development --env coverage",
"build:frontend:coverage:prod": "COVERAGE=true webpack -c ./webpack.config.ts --env production --env coverage",
"build:backend": "go run github.com/magefile/mage@latest build",
"build:backend": "go run github.com/magefile/mage@latest build:backend",
Copy link

Choose a reason for hiding this comment

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

Magefile build target mismatch with npm scripts

High Severity

The npm script calls mage build:backend but the new Magefile imports build targets as build.BuildAll, using the standard SDK pattern. The build:backend target doesn't exist, causing backend builds to fail.

Additional Locations (1)

Fix in Cursor Fix in Web

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.

2 participants