Skip to content

fix(desktop): return source connections to the app - #8486

Merged
waleedlatif1 merged 2 commits into
stagingfrom
codex/desktop-source-oauth
Sep 30, 2026
Merged

waleedlatif1 merged 2 commits into
stagingfrom
codex/desktop-source-oauth

Conversation

@waleedlatif1

@waleedlatif1 waleedlatif1 commented Sep 30, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Keep desktop source setup in place while browser consent returns to the original screen and refreshes connected accounts.
  • Start session-bound OAuth in the browser using encrypted, expiring, single-use requests. Cover Slack, GitHub, member enrollment, and organization account connections, with native cancellation and branded completion pages.

Type of Change

  • Bug fix

Testing

  • Electron + separate Chromium E2E with provider fixtures: slow initiation, live refresh, denial, cancellation, stale callbacks, GitHub credential verification, and ordinary knowledge-base invitation enrollment. JSON report and screenshot are uploaded by desktop CI on failure. Confirmed the regression fails without the desktop handoff.
  • Real Redis integration checks for owner isolation, atomic consumption, encryption, expiration, and input limits; focused native and web regression suites.
  • Desktop and app type checks, lint, block-registry check, all repository audits, generated-artifact checks, and docs-manifest check.

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing (new tests pass the test-audit authoring gate)
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel

vercel Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

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

Project Deployment Actions Updated
docs Ready Ready Preview Sep 30, 2026 11:03pm UTC

Request Review

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot 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.

All reported issues were addressed across 44 files

Tip: instead of fixing issues one by one fix them all with cubic

Re-trigger cubic

Comment thread apps/sim/hooks/queries/personal-search-integrations.ts Outdated
Comment thread .github/workflows/desktop-e2e.yml
Comment thread apps/sim/lib/desktop/source-request.integration.ts Outdated
Comment thread apps/sim/app/api/knowledge/slack/oauth/callback/route.ts
Comment thread apps/sim/hooks/use-github-installation-setup.ts
Comment thread apps/sim/components/integrations/slack-search-setup-wizard.tsx Outdated
@greptile-apps

greptile-apps Bot commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

[High risk] Adds desktop source connection flow with new API routes and IPC handlers.

The PR is not ready to merge until the outstanding explicit-ref-type requirement is satisfied.

Findings

  1. P2 Ref type is implicit ▶

Summary

The PR keeps desktop source setup in place while authorization runs in a separate browser session and returns a correlated completion to the app.

  • Adds encrypted, expiring, single-use source requests and native cancellation.
  • Connects Slack, GitHub, enrollment, and organization-account flows to completion and account refresh.
  • Adds desktop end-to-end and Redis integration coverage.
Diagram
sequenceDiagram
  participant D as Desktop app
  participant R as Source request API
  participant B as System browser
  participant P as Provider
  D->>R: Store encrypted source request
  D->>B: Open correlated connect URL
  B->>R: Consume request once
  B->>P: Start authorization
  P-->>B: Return to completion page
  B-->>D: Send correlated loopback result
  D->>D: Refresh authorized account state
Loading

Reviews (2) · Last reviewed commit: "fix(desktop): preserve enrollment mode a..."

Comment thread apps/sim/app/credential-groups/complete/completion-handoff.tsx
Comment thread apps/sim/app/api/knowledge/slack/oauth/callback/route.ts
@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot 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.

No issues found across 45 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Re-trigger cubic

@waleedlatif1
waleedlatif1 merged commit e72626d into staging Sep 30, 2026
27 checks passed
@waleedlatif1
waleedlatif1 deleted the codex/desktop-source-oauth branch September 30, 2026 23:07

This branch was successfully deployed

1 active deployment
Preview — bd0579f0 Deployed Sep 30, 2026 by vercel[bot]
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.

1 participant