GitHub Integration Issue: "Something went wrong" after successful OAuth callback (302 Found)

Hi, I am experiencing a persistent issue when trying to connect my GitHub account to Google AI Studio. Despite a seemingly successful authorization on the GitHub side, the process fails during the callback to Google AI Studio.

Technical Details:

  • Symptoms: After authorizing the “Google AI Studio” GitHub App, I am redirected back to aistudio.google.com, but the interface displays the error message: “Something went wrong, please try logging in again.”

  • Network Analysis: Using DevTools, I confirmed that GitHub sends a valid code and state parameter in the URL.

  • Response Headers: The callback request to https://aistudio.google.com/auth/github/callback returns a 302 Found status, but the session does not seem to initialize correctly on the application side.

  • Integration Type: The URL indicates a GitHub App installation flow (/apps/google-ai-studio/installations/new/) rather than the legacy OAuth flow.

  • Steps Taken:

    1. Cleared all cookies and site data for both GitHub and Google AI Studio.

    2. Revoked/Uninstalled the “Google AI Studio” app from GitHub settings.

    3. Attempted the process in Incognito/Private mode.

    4. Verified that no third-party cookies are being blocked.

It seems like there is a state mismatch or a failure in processing the GitHub App installation token upon return to AI Studio.

Environment:

  • Browser: Chrome / Edge (tested on both)

  • Location: Poland

Could you please investigate if there is an issue with the GitHub App callback handler?