Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): Cursor status says when the account's plan is rejected #15569

Closedpedrozimmermannsoares(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromrefs/pull/15569/headopened View on GitHub

Problem

When Cursor rejects a free-plan account, the Cursor provider shows Unavailable with "Cursor SDK catalog request failed. Check server logs for details." The reason is only in server.trace.ndjson: the SDK's /v1/me and /v1/models return 403 with code plan_required. Reported in #15075.

Change

checkCursorProviderStatus already special-cases authentication failures. It now also checks the catalog failure's cause. A CursorSdkError with code plan_required gets "Cursor's SDK is not available on the free plan. Upgrade the Cursor account to Pro." The wording follows Cursor's own message for that code: "Cloud Agent is not available for free users. Please upgrade to Pro."

Status stays error and auth stays unknown, as before. Other failures keep the generic message.

Scope and approval

Fixes #15075. It isn't triaged yet. I'm submitting it as a very small, focused fix for an obvious bug: the provider status hides a known, non-retryable reason that the SDK already reports with a stable code. It changes one message in one server function, plus a test. No contract, client, or default changes.

It doesn't change whether free accounts can use Cursor. The report's workaround of staying on a pre-SDK build is a separate question for maintainers.

Verification

  • New test says when Cursor rejects the account's plan in CursorProvider.test.ts. It uses a CursorSdkError with code: "plan_required" and status: 403, the same shape as the report's log. On main it fails: the generic "catalog request failed" message is returned. With the fix it passes.
  • vp test run apps/server/src/provider/Layers/CursorProvider.test.ts apps/server/src/provider/Layers/CursorSdkCatalog.test.ts: 10 passed.
  • vp lint on both files: no findings. vp run --filter t3 typecheck: exit 0.
  • Real SDK check, not committed. I pointed the real @cursor/sdk 1.0.31 at a local HTTP server through CURSOR_BACKEND_URL. That server answered every request with 403 {"error":{"code":"plan_required","message":"Cloud Agent is not available for free users. Please upgrade to Pro."}}. I then ran checkCursorProviderStatus with the real CursorSdkCatalogLive. The SDK requested GET /v1/me.
mainthis PR
status / auth.statuserror / unknownerror / unknown
message"Cursor SDK catalog request failed. Check server logs for details.""Cursor's SDK is not available on the free plan. Upgrade the Cursor account to Pro."

Not checked: a real free-plan Cursor account against Cursor's API. I don't have one.

    1. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched

    2. Approvability

      Verdict: Approved at 908bc80

      Macroscope's review found this PR approvable — This is a small, self-contained provider-status bug fix that maps an existing plan_required SDK error to a clear upgrade message without changing successful requests, authentication handling, or provider behavior. A focused regression test covers the new path.

      You can add or adjust custom eligibility rules. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    3. Review in Change Stack →

      Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

      🧰 Additional context used
      📚 Code guidelines (1)
      docs/internals/effect-services.md — auto-discovered

      No actionable comments were generated in the recent review. 🎉

      ℹ️ Recent review info
      ⚙️ Run configuration
      • Configuration used: Repository: pingdotgg/t3code/.coderabbit.yaml
      • Review profile: CHILL
      • Plan: Advanced
      • Run ID: 7515bf70-28a5-4e87-aaa7-36a0de825bbb
      📥 Commits

      Reviewing files that changed from the base of the PR and between eac52f0087d9ba5dee5542f24788d1482affae43 and 908bc8077dd0ea4a6820d366e92be085c6b5711b.

      📒 Files selected for processing (2)
      • apps/server/src/provider/Layers/CursorProvider.test.ts
      • apps/server/src/provider/Layers/CursorProvider.ts

      Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.


      📝 Walkthrough

      Walkthrough

      The Cursor provider now identifies SDK catalog failures with code plan_required and reports that the SDK requires a Pro plan. A test verifies the error status and message for a 403 failure.

      Changes

      Cursor plan status

      Layer / File(s)Summary
      Detect and report plan-required failures
      apps/server/src/provider/Layers/CursorProvider.ts, apps/server/src/provider/Layers/CursorProvider.test.ts
      The provider detects CursorSdkError failures with code plan_required and reports a Pro-plan message. The test checks the error status and message for a 403 failure.

      Priority: ➖ Normal

      Estimated code review effort: 2 (Simple) | ~10 minutes

      Change: Bug fix · Severity of issue fixed: Medium

      Suggested reviewers: maria-rcks

      Merge Risk: ⚪ Minimal · up to 908bc

      Cursor status will now say when a free plan is rejected. Other failures keep their current messages. No merge-blocking risk is apparent.

      🚥 Pre-merge checks | ✅ 5
      ✅ Passed checks (5 passed)
      Check nameStatusExplanation
      Title check✅ PassedThe title clearly identifies the fix: Cursor status now explains when the account's plan is rejected.
      Description check✅ PassedThe description covers the problem, change, scope and approval rationale, and verification. It reports specific test and lint results, a real-SDK check, and the limitation that a real free-plan accoun…
      Linked Issues check✅ PassedIssue #15075 requires provider status to explain a Cursor plan_required account rejection instead of showing the generic catalog error. checkCursorProviderStatus now recognizes a CursorSdkError …
      Out of Scope Changes check✅ PassedThe diff changes only checkCursorProviderStatus and adds a focused test for issue #15075. Both changes directly support the requested status message. No unrelated changes appear in the diff.
      Docstring Coverage✅ PassedNo functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2…
      ✨ Finishing Touches
      🧪 Generate unit tests (beta)
      • Create a new PR
      • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

      Comment `@coderabbitai help` to get the list of available commands.
    4. Note

      Written by claude-opus-5-5 on behalf of Maria

      Hi! We are cleaning up open PRs, and this one does not say which model or harness was used to create it. If this change is really important, we recommend rebuilding the PR with a newer model and noting the model and harness in the PR description.

    5. maria-rcks closed this

Sign in to join this conversation.